← Back to Skills Marketplace
brasco05

Coding Pipeline

by brasco05 · GitHub ↗ · v1.0.0 · MIT-0
cross-platform ✓ Security Clean
98
Downloads
0
Stars
0
Active Installs
1
Versions
Install in OpenClaw
/install coding-pipeline
Description
Enforces a disciplined 4-phase pipeline for non-trivial coding tasks: Plan (hypothesis) → Code (one fix) → Validate (root cause) → Debug (max 3 tries, escala...
README (SKILL.md)

Coding Pipeline

A disciplined 4-phase workflow for any non-trivial coding task. Each phase has a clear purpose, explicit exit criteria, and a loop-back rule when things go wrong. The phases exist because AI agents' default failure mode is blind iteration: edit → build → edit → build → give up. This skill forces hypothesis-driven work, one-fix-at-a-time discipline, root-cause verification, and bounded debugging.

This is a rigid skill — follow the phases exactly. Do not skip, merge, or reorder.

Core Rule

Every non-trivial task — bug fix, feature, refactor — goes through all 4 phases in order:

┌─────────────┐    ┌──────────┐    ┌───────────────┐    ┌─────────────┐
│  1 PLANNER  │───▶│ 2 CODER  │───▶│  3 VALIDATOR  │───▶│  4 DEBUGGER │
│ hypothesis  │    │ one fix  │    │ build + root  │    │ max 3 tries │
└─────────────┘    └────┬─────┘    └───────┬───────┘    └──────┬──────┘
       ▲                │                  │                   │
       │                │ unclear cause    │ fails             │ new hypothesis
       └────────────────┴──────────────────┴───────────────────┘
                        loop back to PLANNER

Skipping a phase or jumping straight to Phase 2 is the failure mode this skill prevents.

Quick Reference

Situation Active Phase Exit When
New task arrives Phase 1 Planner Hypothesis written, scope defined, success criteria explicit
Hypothesis validated Phase 2 Coder One focused change applied, no unrelated edits
Change applied Phase 3 Validator Build passes AND root cause verified
Validator fails Phase 4 Debugger Either fix found (→ Phase 2) or 3 attempts exhausted (→ escalate)
Unclear cause mid-fix Back to Phase 1 New hypothesis written
Fix introduces new error Back to Phase 1 Hypothesis was wrong

Phase 1 — Planner

Goal: Understand the task and formulate an explicit hypothesis before any code change.

Required outputs:

  1. Task breakdown — what is actually being asked? Break into the smallest independent units.
  2. Hypothesis — one sentence in the form: "I believe [symptom] is caused by [cause], because [evidence]."
  3. Scope — which files/modules are in-bounds, which are explicitly out-of-bounds
  4. Success criteria — how Phase 3 will verify this is fixed (not just the symptom gone)

Forbidden in Phase 1:

  • Editing any code
  • Running build or test commands to "see what happens"
  • Multiple parallel hypotheses — pick one, commit to it
  • Vague hypotheses ("something with the auth flow") — sharpen until specific

Exit criteria: Hypothesis is concrete, testable, and you can point to why this is the cause — not just what looks broken.

Loop-back trigger: If during Phase 2 or 3 the hypothesis turns out wrong, return here. Do not patch on top of a broken hypothesis.

See references/phase-1-planner.md for hypothesis patterns and scope breakdown templates.

Phase 2 — Coder

Goal: Apply exactly one focused change that tests the hypothesis from Phase 1.

Rules:

  1. One fix at a time — one change, one purpose, one file or one tightly-scoped set of files
  2. Full files, not snippets — deliver complete file contents when showing work
  3. No speculative refactoring — resist "while I'm in here…"; surgical scope only
  4. If the hypothesis is unclear mid-change → STOP, return to Phase 1

Definition of "one fix": A single logical change that either proves or disproves the hypothesis. Three unrelated improvements = three separate Planner → Coder → Validator cycles.

Exit criteria: Change is applied, diff contains only the intended work, nothing unrelated.

See references/phase-2-coder.md for scope discipline and loop-back triggers.

Phase 3 — Validator

Goal: Verify the change fixed the root cause, not just the symptom.

Checklist (adapt to stack):

  1. Build check — compile/transpile succeeds, no new errors
  2. Type check — no new type errors; any @ts-ignore / type: ignore needs an explicit written justification comment
  3. Focused test — run the specific test that proves the hypothesis, not the full suite
  4. Root-cause verification — the fix addresses the Phase 1 hypothesis, not a side effect
  5. Scope verification — diff matches what Phase 1 planned; no accidental changes
  6. Regression check — nothing adjacent broke

The symptom-vs-cause test:

If I rolled back this change, would the symptom return because of the same cause, or because of something else?

If you can't answer confidently, the fix is symptomatic. Go back to Phase 1.

Exit criteria: All checks pass, root cause verified, no regressions.

Failure → Phase 4 Debugger.

See references/phase-3-validator.md for stack-agnostic validation patterns.

Phase 4 — Debugger

Goal: Bounded debugging with documentation. Escalation over thrashing.

Hard rules:

  1. Max 3 attempts — after 3 failed fixes, STOP and escalate to the user
  2. Document every attempt — what was tried, what happened, why it failed
  3. Never repeat a fix — if attempt 1 failed, attempt 2 must be substantively different
  4. Never "just try again" — every attempt must be backed by a new hypothesis

Attempt log template (write to .pipeline-state/attempts-\x3Ctask>.md or inline in chat):

### Attempt N
- **Hypothesis**: What I now believe is wrong
- **Change**: What I modified (specific files/lines)
- **Result**: What happened (error output, unchanged behavior, new symptom)
- **Why it failed**: The actual root cause of this failure
- **Next direction**: What to try next OR escalate

After 3 failed attempts: STOP. Surface to the user with the full attempt log. Do not continue with a 4th attempt unless the user explicitly authorizes it.

Recovery trigger: If during Phase 4 a fundamentally new hypothesis emerges, return to Phase 1 — not Phase 2. A new hypothesis means a new cycle, not continued debugging.

See references/phase-4-debugger.md for escalation patterns and worked examples.

Phase Transition Gates

No phase transition is automatic. Each requires explicit criteria:

From To Required
1 → 2 Planner → Coder Hypothesis written + scope defined + success criteria
2 → 3 Coder → Validator One focused change applied, no unrelated edits
3 → Done Validator passes Build ✓ + types ✓ + root cause verified + no regressions
3 → 4 Validator → Debugger Any validation check failed
4 → 2 Debugger → Coder New hypothesis + change substantively different from previous attempts
4 → 1 Debugger → Planner Fundamentally new hypothesis (not incremental)
4 → STOP Debugger → Escalate 3 attempts exhausted
ANY → 1 Back to Planner Hypothesis proven wrong mid-cycle

Detection Triggers

Activate this pipeline automatically when the task is:

  • A bug report — user says something is broken
  • A feature request — non-trivial new functionality
  • A refactor — touching existing code for non-cosmetic reasons
  • An error investigation — digging into unexpected behavior
  • A test failure — a test that was passing now fails
  • A deployment issue — something that worked in dev fails in prod

Skip the pipeline only for:

  • Trivial edits (typo, formatting, one-line config)
  • Pure documentation changes
  • Explicitly exploratory work ("just experiment, don't commit")

Anti-Patterns

What this pipeline prevents:

  1. Symptom patching — fixing what looks wrong without understanding why
  2. Multi-fix chaos — changing three things at once, unable to tell which one worked
  3. Retry loops — trying the same fix with minor variations hoping it sticks
  4. Premature coding — jumping to Phase 2 before Phase 1 is done
  5. Validation skipping — "it compiles, ship it" without root-cause check
  6. Unbounded debugging — 8 attempts, no log, no escalation
  7. Speculative refactoring — "while I'm here, let me also clean up this other file"
  8. Hypothesis drift — quietly changing the hypothesis mid-fix to match what you just did
  9. Type-ignore laziness@ts-ignore without a written justification comment
  10. Scope creep — task was "fix login redirect", PR touches 14 unrelated files

See references/anti-patterns.md for concrete before/after examples of each.

Integration with Other Skills

This pipeline works well with — but does not replace — the following:

  • systematic-debugging — when Phase 4 escalates, hand off to systematic-debugging for the full investigation protocol
  • self-improving-agent — after every failed attempt in Phase 4, log to .learnings/ERRORS.md so the next task starts with that knowledge
  • root-cause-analysis — when Phase 3 root-cause verification is ambiguous, escalate to RCA
  • test-driven-development — Phase 1's "success criteria" naturally aligns with TDD's "write the failing test first"

See references/integration.md for detailed pairing patterns.

Platform Integration

Platform-specific activation and hook configuration lives in references/:

  • references/openclaw-integration.md — OpenClaw workspace setup, inter-session coordination
  • references/hooks-setup.md — Claude Code / Codex hook configuration (UserPromptSubmit)
  • references/multi-agent.md — Claude Code, Codex CLI, GitHub Copilot activation patterns

Best Practices

  1. Always start at Phase 1 — no shortcuts, no exceptions for "obvious" fixes
  2. One hypothesis, one fix — resist bundling
  3. Phase 3 verifies cause, not symptom — this is the hard check
  4. Phase 4 is bounded — 3 attempts, then escalate
  5. Document every failed attempt — pattern recognition matters
  6. Full files, no snippets — for reviewability
  7. Loop back to Planner on uncertainty — cheaper than debugging a wrong hypothesis
  8. Escalate fast — 3 failed attempts is a signal, not a suggestion

Source

This pipeline is based on a production coding standard used in NestJS/Next.js/PHP production systems. It emerged from repeated observation that AI agents, left to their defaults, retry-loop into incoherence on non-trivial work. The 4-phase structure + max-3-attempts rule + mandatory hypothesis is the minimum structure needed to keep agents disciplined.

Usage Guidance
This skill appears coherent and aligned with its stated goal. Before installing: 1) Review the included scripts (scripts/activator.sh and scripts/phase-check.sh) if you want to ensure no automated execution in your environment; they are local helpers that create/modify .pipeline-state/. 2) If you do not want the pipeline text injected into every OpenClaw session, avoid installing into a shared workspace (install per‑project instead). 3) The skill recommends creating .pipeline-state/ and adding it to .gitignore — consider doing so to avoid committing local state. 4) Note the skill suggests handoffs to other skills (systematic-debugging, self-improving-agent) but does not automatically invoke remote services or require credentials. Overall this looks like a productivity discipline pack rather than a security risk.
Capability Analysis
Type: OpenClaw Skill Name: coding-pipeline Version: 1.0.0 The 'coding-pipeline' skill bundle is a productivity framework designed to enforce a disciplined 4-phase workflow (Plan, Code, Validate, Debug) for AI coding agents to prevent 'retry loops' and 'symptom patching.' The included bash scripts (activator.sh and phase-check.sh) are simple, transparent utilities for state tracking and reminders within the local workspace. The skill instructions (SKILL.md) actually enhance safety by requiring the agent to document its logic and explicitly escalate to the user after three failed attempts, rather than continuing autonomously. No malicious code, data exfiltration, or prompt-injection attacks were found.
Capability Assessment
Purpose & Capability
The name/description (enforce a 4‑phase coding pipeline) match the included materials: SKILL.md, templates, checklists, examples, and small helper scripts. Nothing in the repo requests unrelated capabilities (no cloud creds, no network download/install steps).
Instruction Scope
The SKILL.md instructs agents to write hypotheses, run builds/tests, and record Phase 4 attempt logs in a local .pipeline-state/ directory. Those actions are appropriate to a pipeline skill, but they do involve writing local state to the workspace and running developer build/test commands — expected for this purpose. There are no instructions to read secrets, call external endpoints, or exfiltrate data.
Install Mechanism
There is no remote install/download; the skill is instruction-first with optional local installation into an OpenClaw workspace. Package.json has no dependencies, and the included shell scripts are small and local-only. No high-risk download/extract steps are present.
Credentials
The skill declares no required environment variables, no credentials, and no config paths beyond creating a local .pipeline-state/ directory. That level of access is proportionate to the stated functionality.
Persistence & Privilege
OpenClaw integration recommends workspace injection so SKILL.md is loaded at session start; that makes the pipeline guidance present across sessions (intentional for this skill). The scripts create/write .pipeline-state/ in the workspace — a benign persistent artifact but one you should be aware of. The skill does not set always: true, does not require elevated privileges, and does not modify other skills' configs.
How to Use
  1. Make sure OpenClaw is installed (local or Docker)
  2. Run the install command in chat: /install coding-pipeline
  3. After installation, invoke the skill by name or use /coding-pipeline
  4. Provide required inputs per the skill's parameter spec and get structured output
Version History
v1.0.0
Initial release introducing a structured 4-phase workflow for disciplined coding tasks. - Enforces a pipeline: Plan (hypothesis) → Code (one fix) → Validate (root cause) → Debug (max 3 tries, escalate) - Strictly prevents blind patching, retry loops, and symptom-only fixes. - Details explicit rules, exit criteria, and loop-back triggers for each phase. - Activates for bugs, features, refactoring, and any non-trivial coding change. - Includes anti-patterns and quick-reference tables for phase transitions and detection triggers.
Metadata
Slug coding-pipeline
Version 1.0.0
License MIT-0
All-time Installs 0
Active Installs 0
Total Versions 1
Frequently Asked Questions

What is Coding Pipeline?

Enforces a disciplined 4-phase pipeline for non-trivial coding tasks: Plan (hypothesis) → Code (one fix) → Validate (root cause) → Debug (max 3 tries, escala... It is an AI Agent Skill for Claude Code / OpenClaw, with 98 downloads so far.

How do I install Coding Pipeline?

Run "/install coding-pipeline" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.

Is Coding Pipeline free?

Yes, Coding Pipeline is completely free, licensed under MIT-0. You can download, install and use it at no cost.

Which platforms does Coding Pipeline support?

Coding Pipeline is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).

Who created Coding Pipeline?

It is built and maintained by brasco05 (@brasco05); the current version is v1.0.0.

💬 Comments