AAR Lessons Ingestion Pipeline
Deliverable AGT-010. Structure per cc02-standards/SYSTEM-STANDARD.md. Every component traces to a design basis (NEED/REQ) and to an acceptance criterion.
1. Purpose and Design Basis
1.1 Scope and Objective
What the pipeline is and the boundary it does not cross.
The AAR Lessons Ingestion Pipeline is a prescriptive batch-automation component that closes the lessons-learned loop between D-02 protective-operations execution and the D-02 doctrine cell library. It ingests each finalized After-Action Report (EP-017, ART-after-action-report), extracts observation/discussion/recommendation triplets from the Corrective Action Register and Doctrine Feedback Loop sections, classifies each finding against the affected D-02 cell DID, detects findings that recur across multiple AARs, and emits two outputs: a lessons register entry (structured record, not a cell) and a proposed doctrine-diff dispatch addressed to the accountable owner of the affected cell.
In scope: parsing finalized AARs, triplet extraction, cell-DID classification, cross-AAR repeat-finding detection, lessons register write, dispatch generation. Out of scope, by design: writing to any cell file, deciding whether a proposed diff is adopted, and any real-time or alerting function. The pipeline proposes; it does not dispose.
1.2 Design Basis
The principle the build rests on, and the doctrine it is bound by.
D-05 architecture (domains/d05-agentic-operations/architecture.md) logs “no lessons-learned ingestion” as an open gap: EP-017 AARs accumulate corrective-action rows and doctrine-feedback rules per engagement, but nothing aggregates them across engagements into a cell-level change proposal, so a systemic issue can recur silently across several details before anyone notices the pattern. This pipeline closes that gap as a proposal generator, not a doctrine author.
Two doctrine constraints from cc03-methodology/METHODOLOGY.md bound the design directly:
- Reliability doctrine, hot-path exclusion. The methodology’s reliability doctrine for alerting/operational systems states that no LLM, ML, or external decision API may gate an alert, and that LLM enrichment runs strictly off the hot path. This pipeline is triggered only by AAR finalization, an inherently after-the-fact, non-time-critical event; it shares no code path, queue, or trigger with AGT-001 (daily brief) or SYS-008 (threat-alert stream) and cannot delay or gate any alert or dissemination.
- Cell promotion gate. The methodology’s cell-lifecycle promotion gate (stub → drafted → needs-revision → drafted → approved, entered only by a reviewer/owner independent of the authoring change, per the V1/V2/V3 table) governs every change to a cell’s content. An automated pipeline cannot satisfy V2 (named-operator cold-start validation) or V3 (accountable-owner sign-off) on its own behalf. The pipeline therefore never writes to a cell; every proposed diff re-enters the normal authoring flow (
uv run mbsecell edit, independent review, V1/V2/V3) as if a human had drafted it from scratch, with the dispatch serving only as the human author’s starting input.
1.3 Needs
- NEED-AGT-010-01: Operations Manager (RF) needs AAR corrective-action and doctrine-feedback findings converted into structured, doctrine-mapped lessons instead of remaining locked inside per-engagement report text.
- Source: RF (Operations Manager), planning-cycle review.
- Context: EP-017 Section 6 (Doctrine Feedback Loop) states trigger rules that update parent post orders, PACE, and PIRs per AAR, but nothing executes those rules across AARs; findings are read once at AAR review and then archived.
- NEED-AGT-010-02: The Systems Engineer (CS) requires that no automated process ever write to a doctrine cell directly, so that every doctrine change stays inside the authoring, review, and promotion discipline the model depends on.
- Source: CS (Systems Engineer), cc03-methodology/METHODOLOGY.md cell promotion gate.
- Context: A cell edit made outside
uv run mbseand the V1/V2/V3 gate would bypass independent verification, cold-start validation, and owner sign-off, breaking the traceability the whole model relies on.
- NEED-AGT-010-03: The Operations Manager (RF) needs findings that recur across multiple engagements surfaced and prioritized, rather than re-discovered independently at each AAR review.
- Source: RF (Operations Manager), doctrine feedback loop review.
- Context: EP-017’s doctrine feedback loop fires per AAR with no memory of prior AARs; a systemic gap (for example, a recurring advance-accuracy discrepancy) can appear in several AARs before anyone connects the pattern to a single root cause.
- NEED-AGT-010-04: The Systems Engineer (CS) requires the pipeline’s execution and any supplementary lookups to be contained, so that an ingestion run cannot touch the host filesystem outside its own working directory or exfiltrate data through an uncontrolled network path.
- Source: CS (Systems Engineer), security architecture plan (consistent with AGT-007 Agent Sandboxing Environment).
- Context: The pipeline reads AARs that may contain client-sensitive operational detail; an unconstrained agent process handling that content is a filesystem- and network-exposure risk.
1.4 Requirements
- REQ-AGT-010-01 (Traceability: NEED-AGT-010-01): Upon finalization of an AAR (EP-017 status transition to a finalized state), the pipeline shall ingest the report and extract one observation/discussion/recommendation triplet record for every Corrective Action Register row and every Doctrine Feedback Loop rule present in the source document within [N] hours [VR-AGT-010-01].
- Verification Method: Test (T)
- REQ-AGT-010-02 (Traceability: NEED-AGT-010-01): For every extracted finding, the pipeline shall classify it against exactly one affected D-02 cell DID (for example EP-020 advance planning cycle gates, EP-025 crisis actions playbook drills, EP-029 training and readiness task lists) and shall flag any finding it cannot classify with a confidence above [THRESHOLD] as unclassified for manual triage rather than assigning it to a default DID [VR-AGT-010-02].
- Verification Method: Demonstration (D)
- REQ-AGT-010-03 (Traceability: NEED-AGT-010-01, NEED-AGT-010-03): The pipeline shall write, for every extracted lesson, a lessons register entry that cites the source AAR report reference (EP-017 Document Control field) and the target cell DID it was classified against, such that every register entry is traceable to exactly one AAR and one cell [VR-AGT-010-03].
- Verification Method: Inspection (I)
- REQ-AGT-010-04 (Traceability: NEED-AGT-010-03): When a newly extracted finding matches an existing lessons register entry classified against the same target cell DID in [N] or more prior AARs (matching by [SIMILARITY METHOD]), the pipeline shall mark the entry as a repeat finding and raise its dispatch priority above that of a first-occurrence finding [VR-AGT-010-04].
- Verification Method: Demonstration (D)
- REQ-AGT-010-05 (Traceability: NEED-AGT-010-02): The pipeline shall never create, modify, or delete a cell file under
domains/; every proposed doctrine diff shall be emitted only as a review dispatch addressed to the accountable owner of the target cell DID, and any resulting cell edit shall be made by a human author through the standard authoring flow (uv run mbse) and the cc03 V1/V2/V3 promotion gate [VR-AGT-010-05].- Verification Method: Test (T)
- REQ-AGT-010-06 (Traceability: NEED-AGT-010-04): During execution, the pipeline shall be confined to the AGT-007 sandboxed runtime and shall not write to any filesystem path outside its designated throwaway working directory [VR-AGT-010-06].
- Verification Method: Test (T)
- REQ-AGT-010-07 (Traceability: NEED-AGT-010-04): Where the pipeline performs supplementary enrichment lookups against external sources, it shall restrict itself to web-only read tools with no shell or filesystem tool access, per the cc03 chat-exposed LLM analyst sandboxing rule [VR-AGT-010-07].
- Verification Method: Inspection (I)
2. Architecture As Built
Stage-by-stage build; every arrow is an artifact handoff, never a live call into a cell.
The AAR Lessons Ingestion Pipeline is an event-triggered batch service that runs once per finalized AAR, inside the AGT-007 sandboxed runtime. It does not run continuously and holds no state outside its own register store between runs.
Data flow:
- An AAR status watcher observes the D-02 report cells and detects when an EP-017 instance transitions to a finalized state.
- The section parser loads the finalized AAR and isolates the Corrective Action Register and Doctrine Feedback Loop sections (and the Metrics Block and Chronological Timeline Reconstruction as supporting context).
- The extraction and classification stage produces one observation/discussion/recommendation triplet per register row and feedback rule, and classifies each triplet against a single affected D-02 cell DID drawn from the cell-DID taxonomy; low-confidence classifications are marked unclassified rather than defaulted.
- The repeat-finding matcher compares each new triplet against prior lessons register entries classified against the same target cell DID; a match count at or above [N] escalates the entry’s dispatch priority.
- The register writer appends one lessons register entry per triplet (source AAR reference, target cell DID, finding text, classification confidence, repeat-finding flag) to the append-only lessons register store. The register writer has write access to the register store only, never to
domains/. - The dispatch generator compiles one review dispatch per affected cell DID (grouping same-DID findings from a single AAR run) and routes it to the accountable owner of that cell DID for disposition. The dispatch is a proposal document, not a cell edit.
- Any supplementary enrichment lookup (for example, confirming a public regulatory reference cited in a recommendation) uses web-only read tools inside the same sandboxed run; no shell or filesystem tool is exposed to that step.
+---------------------------------------------------------------------------------+
| AGT-010 AAR Lessons Ingestion Pipeline (sandboxed per AGT-007, event-triggered) |
| |
| [ART-after-action-report] --> [Section Parser] --> [Extraction & Classification]|
| | |
| v |
| [Repeat-Finding Matcher] <--+ |
| | | |
| v | history |
| [Lessons Register Writer] -+ |
| | |
| v |
| [Dispatch Generator] |
| | |
+--------------------------------------------------------------|-------------------+
v
[Review Dispatch --> Accountable Owner]
(human disposition; cell edit, if any, via
uv run mbse + cc03 V1/V2/V3 gate)
3. Components and Bill of Materials
| Component | Spec | Vendor / Link | Price | Tier | Status | Traceability |
|---|---|---|---|---|---|---|
| AAR Status Watcher | Script polling D-02 report cell status fields for finalization transitions | Internal | $0.00 | - | SELECTED | REQ-AGT-010-01 |
| Section Parser | Markdown/YAML section parser for the EP-017 spine (Corrective Action Register, Doctrine Feedback Loop, Metrics Block) | Internal | $0.00 | - | SELECTED | REQ-AGT-010-01 |
| Extraction and Classification Engine | LLM-based text-extraction and DID-classification service, run off the hot path | [LLM API PROVIDER] | [USAGE_COST] | - | GAP | REQ-AGT-010-02, REQ-AGT-010-03 |
| Lessons Register Store | Append-only structured record store (one entry per extracted finding) | Internal | $0.00 | - | SELECTED | REQ-AGT-010-03 |
| Repeat-Finding Matcher | Match logic comparing new findings against register history by target cell DID | Internal | $0.00 | - | SELECTED | REQ-AGT-010-04 |
| Dispatch Generator | Compiles and routes review dispatches to the accountable owner of each affected cell DID | Internal | $0.00 | - | SELECTED | REQ-AGT-010-05 |
| Sandboxed Runtime | Throwaway working-directory container execution, consumed from AGT-007 | Internal (consumes AGT-007) | $0.00 | - | SELECTED | REQ-AGT-010-06, REQ-AGT-010-07 |
Note: Extraction and Classification Engine is a GAP row; the specific LLM API provider and per-run usage cost are ungrounded pending a firm procurement decision and are marked as a GAP.
4. Build and Deployment
4.1 Environment Configuration
- Provision the pipeline inside the AGT-007 sandboxed runtime; do not run any stage of this pipeline outside that containment.
- Configure the AAR status watcher with read-only access to the
domains/d02-protective-operations/deliverables/reports/tree, scoped to EP-017 instances only. - Configure the lessons register store path and the dispatch output path, both inside the pipeline’s designated working directory; neither path may resolve into
domains/.
4.2 Trigger and Integration Setup
- Register the AAR status watcher against the EP-017 finalization event (status transition), not against a fixed schedule; a finalized AAR with no matching event is a delivery-integrity defect, not a silent skip.
- Configure the target-cell-DID taxonomy the classification stage matches against (the D-02 capability nodes and cell DIDs referenced in EP-017 Section 6, extended as new AAR-citable cells are added).
- Configure the accountable-owner routing table used by the dispatch generator (one owner per D-02 capability node or cell DID).
- Run an end-to-end dry run against a sample finalized AAR and confirm a lessons register entry and a routed dispatch are produced with no write outside the working directory.
- Execute the pipeline via:
uv run aar-lessons-pipeline --aar <finalized EP-017 path> --register <register path> --dispatch-out <dispatch path>.
5. Hardening Baseline
- No-Direct-Write Invariant: Mount
domains/read-only for every pipeline stage; the register writer and dispatch generator hold write access only to the register store and dispatch output paths, both outsidedomains/[REQ-AGT-010-05]. - Sandboxed Execution: Run every stage inside the AGT-007 containerized runtime with a memory-backed, throwaway working directory; discard the working directory on run completion [REQ-AGT-010-06].
- Enrichment Egress Control: Where supplementary enrichment lookups run, restrict the toolset to web-only read tools with no shell or filesystem access, matching the cc03 chat-exposed LLM analyst sandboxing rule [REQ-AGT-010-07].
- Dispatch Routing Integrity: Validate the accountable-owner routing table before each run; a dispatch with no resolvable owner is held for manual routing rather than dropped or misrouted.
- Register Integrity: Enforce append-only semantics on the lessons register store; no run may edit or delete a prior entry, preserving the audit trail for repeat-finding detection [REQ-AGT-010-04].
6. Integration Points
| Interface | Type | Direction | Contract |
|---|---|---|---|
| ART-after-action-report | File (Markdown, EP-017 finalized instance) | Consumed | Finalized AAR providing Corrective Action Register and Doctrine Feedback Loop sections as extraction source |
| Lessons Register | File / record store ([LESSONS_REGISTER_PATH]) | Produced | Append-only entry per extracted finding: source AAR reference, target cell DID, finding text, classification confidence, repeat-finding flag |
| Review Dispatch | File / message ([DISPATCH_OUTPUT_PATH]) | Produced | Proposed doctrine diff addressed to the accountable owner of the target cell DID; a review input, never a cell edit |
Downstream disposition is a human action, not a pipeline output: an accountable owner who accepts a dispatch against EP-029 (Training and Readiness Program) authors a task-list emphasis update, and an owner who accepts a dispatch against EP-019 (PIR Management) authors a PIR adjustment, in each case through the normal authoring flow and the cc03 V1/V2/V3 promotion gate. Neither EP-029 nor EP-019 is a seam this pipeline writes to; there is no provides/produces_for edge from AGT-010 to either cell, consistent with the frontmatter above.
7. Acceptance Tests
| Criterion | Method | Expected Result | Reference |
|---|---|---|---|
| REQ-AGT-010-01 | Test | Ingest a sample finalized AAR and verify one triplet record is produced for every Corrective Action Register row and Doctrine Feedback Loop rule, within [N] hours of finalization. | VR-AGT-010-01 |
| REQ-AGT-010-02 | Demonstration | Run classification against a set of findings with known target cell DIDs and verify each is classified correctly or flagged unclassified, with no default-DID assignment. | VR-AGT-010-02 |
| REQ-AGT-010-03 | Inspection | Inspect a sample of register entries and confirm each cites exactly one AAR report reference and one target cell DID. | VR-AGT-010-03 |
| REQ-AGT-010-04 | Demonstration | Ingest [N]+1 AARs containing the same finding classified against the same cell DID and verify the [N]-th and later entries are marked repeat findings with escalated dispatch priority. | VR-AGT-010-04 |
| REQ-AGT-010-05 | Test | Run the pipeline end to end and verify no file under domains/ is created, modified, or deleted; confirm the only outputs are a register entry and a dispatch. | VR-AGT-010-05 |
| REQ-AGT-010-06 | Test | Attempt a write outside the designated working directory during a pipeline run inside the AGT-007 sandbox and verify access denial. | VR-AGT-010-06 |
| REQ-AGT-010-07 | Inspection | Audit the toolset available to any enrichment-lookup step and confirm only web-only read tools are exposed, with no shell or filesystem tool present. | VR-AGT-010-07 |
8. Run and Maintenance Handover
- Execution Command:
uv run aar-lessons-pipeline --aar <finalized EP-017 path> --register <register path> --dispatch-out <dispatch path>, triggered by the AAR status watcher on EP-017 finalization. - Review Cadence: Accountable owners triage open dispatches on a [WEEKLY/BIWEEKLY] cadence; the repeat-finding threshold [N] is reviewed quarterly by the Systems Engineer (CS).
- Ownership: Systems Engineer (CS) owns pipeline operation and the register/dispatch infrastructure; the accountable owner of each affected cell DID owns disposition of dispatches routed against that DID.
- Implementation Status: Specification-first, consistent with the rest of D-05 (domains/d05-agentic-operations/architecture.md: “the remaining cells are specification-first; implementation follows demand”). No code exists yet; this cell closes the “no lessons-learned ingestion” gap logged in that architecture note. Implementation is gated on the LLM API provider selection (Section 3, GAP row) and on the accountable-owner routing table (Section 4.2) being populated per current firm assignments.
END OF SYSTEM
Model wiring
Generated from cell frontmatter at publish time.
- Requires:
ART-after-action-report(from EP-017)