AgentStack
MCP verified MIT Self-run

Loopcode

mcp-mgj10086-loopcode · by mgj10086

The open-source standard for autonomous AI agent loops. Compose. Verify. Deploy.

No reviews yet
0 installs
0 views
view→install

Install

$ agentstack add mcp-mgj10086-loopcode

✓ scanned · ✓ verified — works with Claude Code, Cursor, and more.

Security review

✓ Passed

No 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.

Are you the author of Loopcode? Claim this listing to set pricing, connect Stripe payouts, and keep 70% of every sale.
Sign up to claim

About

LoopCode 🔄

> The Open-Source Standard for Autonomous AI Agent Loops > Compose. Verify. Deploy.

[](LICENSE) [](runtime/) [](src/)


Why LoopCode?

Every team building AI agents is reinventing the same wheel — designing loops, wiring up Maker/Checker verification, managing state across sessions, handling failure recovery. There is no standard.

LoopCode is that standard. Inspired by what React did for UI components and what Docker did for containers, LoopCode gives you:

  • Six composable primitives — Trigger, Pipeline, Skill, Connector, SubAgent, Memory
  • Built-in Maker/Checker — Verification is in the architecture, not an afterthought
  • Loop Readiness Score (LRS) — Know if your loop is production-ready before you run it
  • Dual runtime — TypeScript CLI + Python execution engine

Demo

Try it yourself:

# Install Python runtime
cd runtime && pip install -e .

# Run a code review loop (dry run — no LLM cost)
loopcode-runtime --dry-run run pr-review
============================================================
  Running Loop: pr-review
============================================================
Config: loops\pr-review.yaml
Pipeline: 1 step(s)
Verification: Maker=['Bug Review', 'Security Review',
              'Quality Review', 'Performance Review']
              | Checker=Adversarial Verifier

── Pipeline Execution ────────────────────────────────
  Running 4 agents in parallel...
  -> Agent: Bug Review...
  -> Agent: Security Review...
  -> Agent: Quality Review...
  -> Agent: Performance Review...
    + Completed (424ms, 0 up/0 down tokens, $0.0000)

── Maker/Checker Verification ────────────────────────
  Round 1: [ok] PASS (score: 0.95)

── Results ───────────────────────────────────────────
[ok] Loop 'pr-review' completed successfully
  Duration: 424ms
  Steps: 4
  Est. Cost: $0.0000

Quick Start

# 1. Install
npm install -g loopcode

# 2. Initialize a project
loopcode init

# 3. Validate
loopcode validate

# 4. Run a loop (requires ANTHROPIC_API_KEY or OPENAI_API_KEY)
loopcode-runtime run pr-review

Example: PR Review Loop

# loops/pr-review.yaml
name: pr-review
trigger:
  type: webhook
  event: pull_request

pipeline:
  - parallel:
      - prompt: "Review for correctness bugs"
        label: Bug Review
      - prompt: "Review for security vulnerabilities"
        label: Security Review
      - prompt: "Review for code quality"
        label: Quality Review

verify:
  maker: [Bug Review, Security Review, Quality Review]
  checker: Adversarial Verifier
  maxRounds: 3
  autoRetry: true

budget:
  maxTokens: 500000
  maxDurationMinutes: 30

memory:
  store: filesystem
  path: .loopcode/state

Architecture

┌── User ──────────────────────────────────┐
│  loopcode.yaml        loops/              │  ← Declarative YAML
└────────┬──────────────────────┬───────────┘
         │                      │
    ┌────▼──────────────┐ ┌────▼──────────┐
    │  TypeScript CLI   │ │ Python Runtime │   ← Dual runtime
    │  (init/validate   │ │ (execution     │
    │   /run/status)    │ │  engine)       │
    └───────────────────┘ └────┬───────────┘
                               │
                    ┌──────────▼──────────┐
                    │   Loop Engine       │
                    │                     │
                    │  ┌───────────────┐  │
                    │  │ Pipeline      │  │
                    │  │ ┌───┐ ┌───┐   │  │
                    │  │ │ A │ │ B │…  │  │  ← Parallel agents
                    │  │ └─┬─┘ └─┬─┘   │  │
                    │  └───┼─────┼─────┘  │
                    │      │     │        │
                    │  ┌───▼─────▼─────┐  │
                    │  │  Verifier     │  │  ← Maker/Checker
                    │  │  (Checker)    │  │
                    │  └───────┬───────┘  │
                    └──────────┼──────────┘
                               │
                    ┌──────────▼──────────┐
                    │    State Store      │  ← Filesystem persistence
                    │  .loopcode/state/    │
                    └─────────────────────┘

The Six Primitives

| Component | Role | Examples | |-----------|------|---------| | Trigger | What starts the loop | cron, webhook, manual, event | | Pipeline | The execution flow | parallel, sequential, conditional | | Skill | Reusable domain knowledge | SKILL.md, npm packages | | Connector | External system bridge | MCP servers, APIs, databases | | SubAgent | Maker/Checker separation | planner, executor, verifier | | Memory | Cross-session persistence | filesystem, database, memory |

Loop Readiness Score (LRS)

Each loop receives a 0-100 score across 7 dimensions:

loopcode validate
  
  pr-review    — LRS: 85/100 (Grade B)
    [ok] Maker/Checker separation enforced
    [ok] Budget controls configured (3 dimensions)
    [!] State persistence recommended

  daily-triage — LRS: 72/100 (Grade C)
    [ok] Max iterations set
    [!] Add budget controls for production
    [!] Verification missing

Roadmap

  • Phase 1 (current): Schema + CLI + LRS + Python Runtime
  • Phase 2 (W3-4): Loop Registry, GitHub Action, MCP integration
  • Phase 3 (W5-8): Team collaboration, observability dashboard, audit logs
  • Phase 4 (Q3): Enterprise SSO, compliance reporting, on-premise deployment

Why This Matters

> "I stopped manually prompting Claude. I run a bunch of Loops to prompt it > and let it decide what to do next. My job has become writing Loops." > — Boris Cherny, Claude Code lead, Anthropic

Loop Engineering is the fourth paradigm shift in AI engineering:

| Era | Focus | |-----|-------| | Prompt Engineering (2022) | Write better prompts | | Context Engineering (2023) | Give better context | | Tool Engineering (2024) | Build better tools | | Loop Engineering (2025+) | Design better loops |

License

MIT — see [LICENSE](LICENSE)

Source & license

This open-source MCP server is cataloged on AgentStack and links to its original source — we do not rehost the code.

Install and usage instructions live in the source repository linked above.

Reviews

No reviews yet — be the first.

Versions

  • v0.1.0 Imported from the upstream source.