Install
$ agentstack add skill-diversioteam-agent-skills-marketplace-backend-ralph-plan ✓ scanned · ✓ verified, works with Claude Code, Cursor, and more.
Security review
✓ PassedNo issues found. Passed automated security review. · v0.1.0 How review works →
- ✓ Prompt-injection patterns
- ✓ Secret / credential exfiltration
- ✓ Dangerous shell & filesystem operations
- ✓ Untrusted network calls
- ✓ Known-malicious package signatures
What it can access
- ✓ Network access No
- ✓ Filesystem access No
- ✓ Shell / process execution No
- ✓ Environment & secrets No
- ✓ Dynamic code execution No
From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.
Verified badge
Passed review? Show it. Paste this badge into your README, it links to the public security report.
Reliability & compatibility
Declared compatibility
Compatibility is declared by the source manifest. End-to-end runtime verification is coming, see below.
We're building live execution health for every listing: tool-call success rate, median latency, uptime, and last-checked timestamps, measured, not self-reported. It isn't live yet, so we don't show numbers we can't stand behind.
How agent discovery & health will work →About
Backend RALPH Plan Skill
Purpose
This skill creates two deliverables:
- PLAN.md - Structured task index with quality tracking
- RALPH-PROMPT.md - The prompt fed to
/ralph-wiggum:ralph-loop
The key insight: Ralph works by feeding the same prompt repeatedly. Claude sees its previous work in files/git and iterates. RALPH-PROMPT.md becomes that prompt, instructing Claude to work through tasks with strict quality gates.
When to Use
- Backend Django features requiring rigorous quality control
- Multi-task implementations needing iterative, autonomous execution
- When you want continuous regression testing between tasks
- Projects where you'll walk away and let Ralph complete the work
When NOT to Use
- Quick prototypes or exploratory code
- Frontend projects (create
frontend-ralph-planif needed) - Simple tasks that don't need iteration
- Plans where human judgment is needed at each step
The Two-Step Process
Step 1: This skill creates the plan
docs/plans//
├── PLAN.md # Task index with tracking
├── RALPH-PROMPT.md # Prompt for ralph-loop
├── 001-.md # Task files
└── ...
Step 2: Run the plan
/plan-directory:run
That's it. This command:
- Reads RALPH-PROMPT.md
- Extracts the completion promise
- Invokes
/ralph-wiggum:ralph-loopautomatically
Optional: /plan-directory:run --max-iterations 50
Required Inputs
| Input | Required | Description | |-------|----------|-------------| | Plan title | Yes | Human-readable name | | Plan slug | Yes | Directory name, kebab-case | | Task list | Yes | Tasks with names and scopes | | Django app path | Yes | e.g., optimo_surveys/ | | Module path | Yes | e.g., digest/ | | Test filter | Yes | Pytest -k filter |
Tooling Configuration
| Input | Default | Description | |-------|---------|-------------| | Lint command | ruff check | Prefix with .bin/ if needed | | Format command | ruff format | | | Type gate | Auto-detect (ty → pyright → mypy) | ty is mandatory if configured | | Test command | pytest | | | Test config | ` | e.g., --dc=TestLocalApp | | Django command | django | | | Coverage target | 90 | Minimum percentage | | Max iterations | 100` | Ralph loop limit |
Type policy for generated plans:
- Detect type checker in this order unless repo docs/CI specify otherwise:
ty, then pyright, then mypy.
- If
tyis configured ([tool.ty],ty.toml,.bin/ty, CI/pre-commit), it
is mandatory and blocking.
- Generated tasks should not use "baseline acceptable" language for touched
files.
Task Granularity Guidelines
Right-sized tasks for Ralph:
| Task Size | Checklist Items | Good For | |-----------|-----------------|----------| | Too small | 1-2 | Overhead exceeds value | | Ideal | 4-8 | Clear scope, achievable in one iteration | | Too large | 10+ | Gets stuck, split it |
Signs a task is too large:
- Requires multiple commits to feel "done"
- Has more than 8 checklist items
- Spans multiple unrelated concerns
- Would take a human more than 2-4 hours
Split large tasks by:
- Separating model/service/API layers
- Breaking by feature subset
- Isolating integration points
Completion Promise Format
The promise must be plan-specific, not generic:
ALL {{TASK_COUNT}} {{PLAN_SLUG_UPPER}} TASKS COMPLETE
Examples:
ALL 4 USER-PREFERENCES TASKS COMPLETEALL 11 MANAGER-DIGEST TASKS COMPLETEALL 6 NOTIFICATION-SERVICE TASKS COMPLETE
This prevents Claude from lying with a generic "done" when tasks remain.
RALPH-PROMPT.md: The Key File
The prompt is iteration-aware. It tells Claude to:
- Orient first - Check git log, read PLAN.md for current status
- Don't repeat work - Skip what's already committed
- Verify rigorously - Run all gates after each task
- Commit progress - Git commit after each task completion
- Handle blockers - Document, try alternatives, don't lie to exit
See references/ralph-prompt-template.md for the full template. See examples/user-preferences/ for a complete working example.
Git Integration
Each task completion includes a commit:
git commit -m "Complete 001 - Preferences Model
- Added JSONField to User model
- Created Pydantic schemas for validation
- 5 tests added, 94% coverage
Plan: user-preferences"
This is critical for Ralph because:
- Progress persists across iterations
- Claude can see what it did via
git log - Partial progress is never lost
Handling Complex Codebases
For large/unfamiliar codebases, add a warm-up task:
# 000 - Codebase Orientation
## Goal
Understand existing patterns before implementing.
## Checklist
- [ ] Read existing models in `{{APP_PATH}}`
- [ ] Identify service layer patterns
- [ ] Note testing conventions
- [ ] Document relevant existing code in Notes section
## Completion Criteria
- [ ] Notes section filled with findings
- [ ] No implementation (orientation only)
This prevents Claude from fighting existing patterns.
Escape Hatches
If Claude is genuinely stuck:
- Blockers section in task file:
```markdown ## Blockers
- Blocked by: External API not available
- Attempted: Mock implementation, local stub
- Needs: API credentials or decision to defer
```
- Skip to independent task if dependencies allow
- Max iterations as ultimate safety net
The loop continues until genuine completion or max iterations. Claude should never lie to exit.
Workflow
1. Gather Inputs
Ask for all required inputs. Clarify:
- Exact paths (trailing slashes matter)
- Test filter that isolates this feature
- Non-standard tooling (
.bin/wrappers)
2. Analyze Dependencies
Before creating files:
- Identify foundation tasks (no dependencies)
- Map task dependencies
- Determine critical path
- Order to minimize blocking
3. Create Files
- Create
docs/plans//directory - Write
PLAN.mdwith task index and tracking tables - Write each task file with standard sections
- Write
RALPH-PROMPT.mdwith all placeholders replaced
4. Replace Placeholders
In RALPH-PROMPT.md, replace:
{{PLAN_TITLE}}→ e.g., "User Preferences API"{{TASK_COUNT}}→ e.g., "4"{{PLAN_SLUG}}→ e.g., "user-preferences"{{PLAN_SLUG_UPPER}}→ e.g., "USER-PREFERENCES"{{LINT_CMD}}→ e.g., ".bin/ruff check"{{APP_PATH}}→ e.g., "accounts/"{{MODULE_PATH}}→ e.g., "preferences/"- All other command/path placeholders
5. Verify Deliverables
Before delivering:
- [ ] PLAN.md has task index and tracking tables
- [ ] All task files have Goal, Scope, Checklist, Tests, Completion Criteria
- [ ] Task checklist items are 4-8 each (not too small, not too large)
- [ ] RALPH-PROMPT.md has NO remaining
{{placeholders}} - [ ] Execution order matches actual dependencies
- [ ] Completion promise includes task count and slug
- [ ] Fresh-eyes pass completed: task order, blockers, test gates, and prompt
instructions were re-read and obvious problems were fixed
Example
See examples/user-preferences/ for a complete working example:
PLAN.md- 4-task plan with trackingRALPH-PROMPT.md- Iteration-aware prompt001-preferences-model.md- Foundation task (model layer)002-preferences-service.md- Service layer003-api-endpoints.md- API layer004-caching-layer.md- Performance optimization
Reference Files
references/ralph-prompt-template.md- Full prompt templatereferences/plan-template.md- PLAN.md structurereferences/quality-gates.md- Verification commandsexamples/user-preferences/- Working example
Compatibility Notes
This Skill is designed to work with both Claude Code and OpenAI Codex.
- Claude Code: install the corresponding plugin and use its slash commands (see
plugins/plan-directory/commands/). - Codex: install the Skill directory and invoke
name: backend-ralph-plan.
For installation, see this repo's README.md.
Source & license
This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.
- Author: DiversioTeam
- Source: DiversioTeam/agent-skills-marketplace
- License: MIT
- Homepage: https://engineering.diversio.com
Install and usage instructions live in the source repository linked above.
Reviews
No reviews yet, be the first.
Write a review
Versions
- v0.1.0 Imported from the upstream source.