Autonomous orchestration framework for Claude Code with MemPalace-inspired memory (4-layer stack, 818-token wake-up), parallel-first Agent Teams (6 teammates), Aristotle First Principles methodology, and 4-stage quality gates. 925+ tests, 22 active hooks, automatic learning pipeline.
# Add to your Claude Code skills
git clone https://github.com/alfredolopez80/multi-agent-ralph-loopGuides for using ai agents skills like multi-agent-ralph-loop.
Last scanned: 5/30/2026
{
"issues": [],
"status": "PASSED",
"scannedAt": "2026-05-30T16:16:31.602Z",
"npmAuditRan": true,
"pipAuditRan": true
}See how multi-agent-ralph-loop compares with popular alternatives.
multi-agent-ralph-loop is an open-source ai agents skill for AI coding assistants such as Claude Code, Codex CLI, and ChatGPT, built by alfredolopez80. Autonomous orchestration framework for Claude Code with MemPalace-inspired memory (4-layer stack, 818-token wake-up), parallel-first Agent Teams (6 teammates), Aristotle First Principles methodology, and 4-stage quality gates. 925+ tests, 22 active hooks, automatic learning pipeline. It has 146 GitHub stars.
Yes. multi-agent-ralph-loop passed SkillsLLM's automated security scan — a dependency vulnerability audit plus prompt-injection heuristics — with no high-severity issues. You can read the full report in the Security Report section on this page.
Clone the repository with "git clone https://github.com/alfredolopez80/multi-agent-ralph-loop" and add it to your Claude Code skills directory (see the Installation section above).
multi-agent-ralph-loop is primarily written in Shell. It is open-source under alfredolopez80 on GitHub, so you can review or fork the full source.
Yes. SkillsLLM lists many other AI Agents skills you can browse and compare side by side. Open the AI Agents category from the badge at the top of this page, or use the Related Skills and comparison links further down to weigh multi-agent-ralph-loop against similar tools.
No comments yet. Be the first to share your thoughts!
⚠️ Third-Party Software Notice
This skill is third-party open-source software developed and hosted independently on GitHub. SkillsLLM is an informational directory and does not control or maintain the underlying repository.
Any security checks, ratings, or warnings displayed by SkillsLLM are automated and limited in scope. They do not constitute a security certification or guarantee that the software is safe, error-free, or free from malicious code, vulnerabilities, compromised dependencies, or prompt-injection risks.
Review the source code, permissions, dependencies, and configuration before installing or running any third-party skill. Use is at your own risk. To the maximum extent permitted by applicable law, SkillsLLM is not liable for losses arising from third-party software.
See comparison
Autonomous orchestration framework for Claude Code with MemPalace-inspired memory, Agent Teams, and quality gates.
Ralph extends Claude Code into a multi-agent development framework with a structured memory system inspired by the Memory Palace technique. Every task is analyzed from first principles, decomposed into focused subtasks, assigned to specialized teammates, and validated through quality gates before completion.
| Capability | Description |
|---|---|
| MemPalace Memory | 4-layer memory stack (L0-L3) with Obsidian vault knowledge graph and learned rules taxonomy |
| 6 Teammates | ralph-coder, ralph-reviewer, ralph-tester, ralph-researcher, ralph-frontend, ralph-security |
| Hook System | Lifecycle hooks for validation, quality gates, security guards, and automatic learning |
| Aristotle (opt-in skill) | 5-phase deconstruction via /aristotle for ambiguous/high-impact work — retired from the default chain by #69 Phase 3 |
| Quality Gates | 4-stage blocking validation: correctness, quality, security, consistency |
| Comprehensive Tests | Full test suite covering layers, hooks, security, skills, and pipeline |
Inspired by the MemPalace repository (Memory Palace technique for LLM agents), Ralph implements a layered memory architecture with key differences based on our implementation findings.
| Layer | File | Purpose |
|---|---|---|
| L0 | ~/.ralph/layers/L0_identity.md |
Agent identity + principles |
| L1 | ~/.ralph/layers/L1_essential.md |
Actionable rules (filtered from corpus) |
| L2 | .claude/learned-src/learned/*.md |
Graduated project rules, one flat file per domain (on-demand) |
| L3 | Obsidian vault grep | Full knowledge base queries (on-demand) |
These findings emerged during our MemPalace implementation and may be relevant to others building LLM memory systems:
| Finding | Detail |
|---|---|
| Encoding doesn't reduce tokens | Unicode PUA encoding increased BPE tokens. Word count metrics falsely reported reduction. |
| Selection beats encoding | Choosing fewer rules achieved the target; compressing the same rules did not. |
| Taxonomy needs noise filtering | 46% of auto-learned rules were noise (cross-domain repeats, vague bundles). Filtering is essential. |
Full analysis: AAAK_LIMITATIONS_ADR
SESSION (any repo)
|
+-- Stop --> (automatic learning removed by #69 Slice D; writes are explicit)
+-- PostToolUse --> semantic extractors --> vault facts & decisions
+-- SessionStart --> (automatic graduation removed by #69 Slice D)
+-- SessionEnd --> (automatic indexing removed by #69 Slice D)
All learning flows project -> global -> vault. Only universal patterns graduate to global scope.
git clone https://github.com/alfredolopez80/multi-agent-ralph-loop.git
cd multi-agent-ralph-loop
# Validate global infrastructure
bash scripts/validate-global-infrastructure.sh
# Run tests
python3 -m pytest tests/ -q
# Use
/orchestrator "Create a REST API endpoint"
/iterate "Fix all lint errors"
/security src/
6 specialized teammates for parallel execution:
| Teammate | Role | Tools |
|---|---|---|
ralph-coder |
Implementation | Read, Edit, Write, Bash |
ralph-reviewer |
Code review (OWASP) | Read, Grep, Glob |
ralph-tester |
Testing | Read, Edit, Write, Bash(test) |
ralph-researcher |
Research (web search) | Read, Grep, Glob, WebSearch |
ralph-frontend |
Frontend (WCAG 2.1 AA) | LSP, Read, Edit, Write, Bash |
ralph-security |
Security (6 pillars) | LSP, Read, Grep, Glob, Bash |
Agent Teams is enabled via CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS=1 in settings.json. Teammates can be spawned by the orchestrator, iterate, parallel, security, and task-batch skills when a task benefits from it.
| Skill | Purpose |
|---|---|
/orchestrator |
Full 10-step workflow: evaluate, clarify, classify, plan, execute, validate, retrospect |
/iterate |
Iterative execution until VERIFIED_DONE |
/parallel |
Run multiple independent tasks concurrently |
/task-batch |
Autonomous batch execution from PRD files |
/gates |
Multi-language quality gate validation |
/security |
Multi-agent security audit (OWASP, semgrep, gitleaks) |
/autoresearch |
Autonomous experimentation loop with Smart Setup |
/adversarial |
Spec refinement with multi-model cross-validation |
/bugs |
Systematic bug hunting |
/ship |
Pre-launch checklist (gates + security + review) |
/spec |
Verifiable technical specification before coding |
/orchestrator runs steps 0 through 8. Step 0 classifies the task on three dimensions and
routes it; step 6 is a nested loop that runs once per plan step.
0. EVALUATE -> Aristotle first principles + 3-dimension classification
1. CLARIFY -> AskUserQuestion (MUST_HAVE blocking, NICE_TO_HAVE optional)
2. CLASSIFY -> task-classifier (complexity 1-10)
3. PLAN -> Detailed design
4. PLAN MODE -> EnterPlanMode, user approves
5. DELEGATE -> Assign to teammates (isolation and parallelism, never model routing)
6. EXECUTE-WITH-SYNC, per plan step:
6a. LSA-VERIFY -> architecture pre-check
6b. IMPLEMENT -> run the step
6c. PLAN-SYNC -> detect drift from the plan
6d. MICRO-GATE -> per-step quality (3-fix rule)
7. VALIDATE -> quality-auditor, /gates, adversarial spec and plan cross-validation
8. RETROSPECT -> self-improvement
Step 0 classifies before it plans, and the three values together choose the route:
| Dimension | Values | Purpose |
|---|---|---|
| Complexity | 1-10 | Scope, risk, ambiguity |
| Information Density | CONSTANT / LINEAR / QUADRATIC | How the answer scales |
| Context Requirement | FITS / CHUNKED / RECURSIVE | Decomposition needs |
CONSTANT + FITS + complexity 1-3 takes a 3-step fast path; QUADRATIC recursively decomposes; LINEAR + CHUNKED runs as parallel chunks.
/iterate repeats execute -> validate -> iterate until the quality gates pass
(VERIFIED_DONE) or the bounded iteration budget is exhausted (max_iterations,
15 by default). An unbounded loop has no failure signal, so every loop sets one.
# Orchestration
/orchestrator "Implement OAuth2 with Google"
ralph orch "task" # Full orchestration
ralph loop "fix the lint errors" # Loop until VERIFIED_DONE
/clarify # Intensive requirement clarification
# Quality
/gates # Quality gates
/adversarial # Spec refinement
# Memory
ralph memory-search "query" # Parallel memory search
ralph fork-suggest "task" # Suggest fork sessions
# Security
ralph security src/ # Security audit
ralph security-loop src/ # Iterative audit until clean
# Git worktree
ralph worktree "feature" # Create an isolated worktree
ralph worktree-pr <branch> # PR with review
# Context
ralph ledger save # Save session state
ralph handoff create # Create a handoff
Observability with no external dependencies, backed by local files:
ralph plan status # Current plan state (reads .claude/plan-state.json)
ralph trace show # Recent events
ralph trace search # Search events
ralph trace timeline # Visual timeline
ralph trace export # Export to JSON/CSV
| Source | Purpose |
|---|---|
.claude/plan-state.json |
Current orchestration state |
~/.ralph/events/event-log.jsonl |
Event bus history |
~/.ralph/checkpoints/ |
Checkpoint snapshots |
~/.ralph/agent-memory/ |
Per-agent memory buffers |
4-stage validation, all blocking except consistency:
Hook enforcement on the TaskCompleted event ensures no agent completes without passing gates.
The repo has 84 hooks in .claude/hooks/. After the M2 retirement (T106),
they fall into four categories by default registration, not by file
existence: always-on security, active canonical #47, retired-to-opt-in
hooks, and cold-path session/scheduler hooks.
Source of truth: results/T107-inventario.md. Every row in the inventory traces to a real file in the repo; if a source link breaks, delete the row.
| Category | Default registration | Shape | Why it survives (or gets retired) |
|---|---|---|---|
| SECURITY (always on) | 6 hooks on PreToolUse + 1 sourced lib |
permission-pipeline, git-safety, repo-boundary, k8s-context, skill-security, worktree-utils | Survives M2 unconditionally. The failure open / fail-closed contract is verified end-to-end in tests/security/SECURITY_BASELINE.json and reproduced by the regression fixtures. |
| CANÓNICO #47 (active) | Plan-state writer + readers, recall on-demand, task-state, T101 guards, subagent state writers | The answer to "what useful verified thing did we learn, where is it, and how do I get it without paying the cost on every prompt". Bounded retrieval, atomic writes, exact chain walk for depth. | Survives act |