Composable Pipeline Architecture

The Composable Pipeline Architecture is how Maudel assembles instructions for every pipeline stage. Instead of hardcoded prompts, each stage is defined by markdown files that are composed into a layered system prompt at runtime.

File-Driven Stage Definitions

Each pipeline stage lives in its own directory under .maudel/pipeline_stages/ with markdown-based definitions:

  • ACTION.md — the primary directive for the stage
  • INPUTS-OUTPUTS.md — declared inputs and expected outputs
  • COLLABORATIVE-AUTONOMOUS-MODE.md — behavior configuration for human interaction level

This makes every stage inspectable, editable, and version-controlled — no black-box prompting.

9-Layer System Prompt Assembly

At runtime, Maudel assembles a system prompt from nine layers organized into three cognitive zones:

Primacy Zone (Strongest Recall)

  1. Agent Identity & Scope — who the agent is and what it can do
  2. Pipeline Instructions — global pipeline rules and constraints

Reference Zone

  1. Stage Instructions — specific directives for this stage
  2. Reference Skills — available capabilities and domain knowledge
  3. Mode Instructions — collaborative vs. autonomous behavior
  4. Special Instructions — project-specific overrides

Recency Zone (Second Strongest Recall)

  1. Story-Specific Instructions — context for the current task
  2. Expected Outputs — what the agent must produce
  3. Upstream Context — relevant outputs from prior stages

This architecture leverages cognitive science principles — critical instructions land in primacy and recency positions where LLM attention is strongest.

Template Variables

Stage definitions support template variables that are resolved at runtime:

  • {{workspacePath}} — the current project directory
  • {{storyDocument}} — the active story being implemented
  • {{testFrameworkGuidance}} — framework-specific testing instructions

Input Hydration

Each stage declares its required inputs. At runtime, the orchestrator matches declared inputs to actual runtime values and injects them into the prompt. This ensures agents always have the context they need — and never more than they should.

Extensibility

Adding a new pipeline stage requires only:

  1. Create a new directory with markdown files
  2. Declare inputs and outputs
  3. Write the stage directive

No code changes. No redeployment. The composable architecture makes the pipeline a living, evolving system.

Ready to transform your AI engineering?

Governed AI engineering, from idea to deployment.