How Pipeline Agents and File Agents collaborate to produce the entire content tree
Content generation follows a two-tier architecture. At the upper level, Pipeline Agents manage the full depth path for an audience. At the lower level, File Agents produce individual HTML files per level.
Hierarchical Architecture
Why two levels? A single agent creating all files for all audiences would exceed the context window. The two-tier architecture keeps context focused per agent: the Pipeline Agent thinks in structure, the File Agent thinks in content.
A Pipeline Agent receives a structured prompt containing everything it needs — but nothing more. Here is the prompt template structure in detail.
## PIPELINE AGENT PROMPT TEMPLATE ## Generated by the orchestrator per audience AUDIENCE: id: "dev" label_de: "Entwickler" label_en: "Developer" icon: "🔧" suffix: "_dev" CURRICULUM: L0: "index_dev_{lang}.html" # 1 file L1: [ "pipelines", "design-system", # 5 files "templates", "output-logic", "quality" ] L2: [ { parent: "pipelines", # 5 files each children: ["subagent-arch", ...] }, ... ] L3: [ { parent: "subagent-arch", # only HS ≥ 8 children: ["pipeline-prompts"] }, ... ] FOUNDATION_REF: "Use the CSS/JS foundation from the L0 file. All variables, classes, patterns are defined there." NAMING_CONVENTION: "{topic}_{suffix}_{lang}.html" # Example: subagent-architecture_dev_en.html EXECUTION_ORDER: 1. Generate L0 (DE + EN) 2. Generate all L1 (DE + EN per topic) 3. Generate all L2 (DE + EN per topic) 4. Generate L3 only for topics with HS ≥ 8
What the Pipeline Agent receives:
Audience Profile — ID, labels (DE/EN), emoji icon, and filename suffix. This tells the agent who it writes for and how files are named.
Curriculum — The complete topic structure across all four levels. Per level, the list of topics with parent-child relationships.
Foundation Reference — Points to the CSS/JS foundation from its own L0 file. No foreign pipelines.
Naming Convention — The pattern for filenames: topic_suffix_language.html
Execution Order — L0 first, then L1, L2, L3. Depth is only generated when HS score ≥ 8.
Important: The Pipeline Agent receives the foundation reference only for its own pipeline. It knows neither the CSS variables of other audiences nor their curriculum structure. Each pipeline is an isolated unit.
The File Agent receives a precise assignment from the Pipeline Agent for exactly one file. Everything it needs is in the prompt — it makes no assumptions.
## FILE AGENT PROMPT TEMPLATE ## Generated by the Pipeline Agent per file FILE: filename: "subagent-architecture_dev_en.html" audience: "dev" # Developer language: "en" level: 2 theme: "Subagent Architecture" hs_score: 9 # Has L3 deep dive CONTENT_DESCRIPTION: "4 sections: Two-Level Model, Pipeline Agent Prompt, File Agent Prompt, Practical Recommendations. Hierarchy diagram in section 1. Code toggles in sections 2 and 3." LINK_TARGETS: breadcrumb_l0: "../index_en.html" breadcrumb_l1: "../l1/pipelines_dev_en.html" lang_switch: "subagent-architektur_dev_de.html" deep_dive_l3: "../l3/pipeline-agent-prompts_dev_en.html" siblings: [ "topic-01", "topic-02", "topic-03 (CURRENT)", "topic-04", "topic-05" ] CONSTRAINTS: - WCAG AA contrast on all elements - No white on light backgrounds - No level labels in titles - CSS/JS foundation inline (no external imports) - min-height: 100dvh per module - Alternating backgrounds
What the File Agent receives:
File Metadata — Filename, audience, language, level, theme, and HS score. The HS score determines whether a deep-dive link to L3 is included (≥ 8).
Content Description — Summary of sections, visualization types, special patterns (code toggles, diagrams, tables).
Link Targets — All relative paths: breadcrumb targets, language switch, deep-dive target, sibling navigation. The File Agent doesn't need to compute paths.
Constraints — Non-negotiable rules: WCAG AA, no forbidden color combinations, module pattern compliance.
| Field | Type | Source |
|---|---|---|
| filename | String | Naming convention + curriculum |
| audience | Enum | Audience profile |
| language | "de" | "en" | Always paired: DE + EN |
| level | 0–3 | Position in curriculum |
| theme | String | Curriculum entry |
| hs_score | 1–10 | Curriculum (computed) |
| link_targets | Object | Pipeline Agent computes |
| constraints | Array | Global rules (fixed) |
The architecture describes the ideal model. In practice there are constraints — especially around parallelization. Here are the proven strategies.
Recommended flow for a pipeline
DE+EN pairs parallel, level transitions sequential
Why not full parallelization? Three practical reasons: (1) Each File Agent needs context capacity, which is limited. (2) With more than 2 parallel agents, the error rate increases significantly. (3) L2 files must reference L1 files — those need to exist first. The architecture describes what is possible. Practice determines how it is executed.
What does a Pipeline Agent NOT receive?