Compare commits

...

18 Commits

Author SHA1 Message Date
Jon Chery 4fe1a1508e docs(P00): grill — v1.27 adversarial review (6 challenges, PROCEED 0.88)
Nova Slides Render / render (push) Failing after 26s
6 challenges; 0 escalations; 1 binding revision (G-Q2, already in
PLAN): archive list refined to 7 platform + 1 consumer = 8 files
(the 4 pre-execution files stay active through v1.27 holding the P0
content; v1.26-era content in git history).

Challenges:
- G-Q1: archiving AUTONOMY_THESIS + COST is lossless (folded into
  NORTH_STAR; COST predates v1.26 pilot)
- G-Q2: archive-list ambiguity resolved (the refinement above)
- G-Q3: STATE.md backfill accuracy ensured by P1 W1 verification step
- G-Q4: NFR purity holds (STATE.md is docs, not feat)
- G-Q5: PROJECT.md bug fix in P2 is intentional phasing (D-225)
- G-Q6: milestone scope is appropriately small + high-leverage

---ci---
project: acdl
phase: 0
milestone: v1.27
status: grill
---ci---
2026-08-19 19:12:37 +00:00
Jon Chery a6b908c035 docs(P00): personas + plan — v1.27 (lead-developer only, 3 phases)
PERSONAS: lead-developer active (docs/chore milestone); 5 others
inactive. Territory: .ciagent/, docs/.

PLAN: 3 phases (P1 author-archive, P2 fix-stale-wire, P3 final-review-ship).
Tags on v1.26.x; v1.26.3 = milestone release.

Archive-list correction (D-219 refinement): the 4 pre-execution files
(CLARIFY/GRILL/IDEATE/RESEARCH) were rewritten in P0 with v1.27
content — the v1.26-era content lives in git history. The v1.27 P0
versions stay active through v1.27 (current pre-execution record);
they archive at v1.28 P1 if v1.28 happens. Final archive list: 7
platform files (CAPABILITY_INVENTORY, REVIEW-AUDIT-P05, VERIFY-P03,
VERIFY-P04, P4-PILOT-RUN-EVIDENCE, AUTONOMY_THESIS, COST) + 1
consumer file (nova-blockchain-exchange/ROADMAP) = 8 files.

---ci---
project: acdl
phase: 0
milestone: v1.27
status: plan
---ci---
2026-08-19 19:12:01 +00:00
Jon Chery e9fbb44ad1 docs(P00): research findings — v1.27 staleness inventory + backfill sources
NFR milestone, no new domain. Research is a codebase-grounded inventory:
- 11 files to archive (4 pre-execution v1.26 artifacts + 3 phase
  verifications/review + 1 evidence snapshot + 3 durable refs superseded
  by STATE.md/NORTH_STAR/archive + 1 consumer ROADMAP).
- 12 files kept active (no-edit: live code paths, durable refs).
- 3 files kept active (fix-only: PROJECT.md, ROADMAP.md, archive/README.md).
- STATE.md backfill sources: regression_verify.py, registry.json,
  REQUIREMENTS traceability, CHECKPOINT, git log, PROJECT decisions.
- Persona roster: lead-developer only (docs/chore milestone).
- 4 risks, all Low-Medium with documented mitigations.

---ci---
project: acdl
phase: 0
milestone: v1.27
status: research
---ci---
2026-08-19 19:09:32 +00:00
Jon Chery 155963d40d docs(P00): clarify — v1.27 ambiguities resolved (6 Qs, D-220..D-225)
6 prior-conversation resolutions (D-214..D-219, user-confirmed) +
6 new ambiguities auto-resolved at full autonomy (D-220..D-225):
- D-220: NFR milestone (tags on v1.26.x)
- D-221: consumer archives in .ciagent/nova-blockchain-exchange/archive/
- D-222: archiving preserves traceability (archive + PROJECT + git)
- D-223: IAM_POLICY.md stays active (live baseline, D-207 pending)
- D-224: REGRESSION_REPORT regenerates on next run_regression.sh
- D-225: PROJECT.md phase-status fix is P2 (correction phase)

0 escalations. Confidence ≥ 0.85 on all new decisions.

---ci---
project: acdl
phase: 0
milestone: v1.27
status: clarify
---ci---
2026-08-19 19:09:05 +00:00
Jon Chery e1b5dc2d1f docs(P00): validate specification — v1.27 PO state catalog + ciagent compression
NFR milestone. Establishes v1.27 (tag line v1.26.x):
- Author .ciagent/STATE.md — PO-facing capability catalog (backfill
  CAP-001..036 across 10 domains + 11 invariants distilled from
  PROJECT.md load-bearing decisions D-034..D-072).
- Archive 10 stale .ciagent/ root files + 1 consumer file (compression
  of pre-execution artifacts, verifications, evidence, the dated
  CAPABILITY_INVENTORY, AUTONOMY_THESIS, COST).
- Fix 3 stale-but-kept files (PROJECT.md, ROADMAP.md phase-status
  blocks; archive README contents tables).
- Wire STATE.md into the P-final ship discipline (PLAN.md, ROADMAP.md,
  NORTH_STAR.md).

The first file the PO reads before writing a new REQ-NNN spec.

---ci---
project: acdl
phase: 0
milestone: v1.27
status: specify
---ci---
2026-08-19 19:08:38 +00:00
Jon Chery c0453817ad docs(milestone): complete v1.26 Live Pilot Estate Activation (release v1.25.5)
acdl-ci / Lint (push) Successful in 8s
acdl-ci / Test (push) Failing after 17s
acdl-ci / Platform check-only (offline) (push) Successful in 18s
All 13 requirements (REQ-310..322) complete. Live pilot estate activated against AWS
581513795199. Milestone merged to main. Tags v1.25.0..v1.25.5. Checkpoint cleared.

---ci---
project: acdl
phase: 5
milestone: v1.26
status: complete
requirements:
  covered: [REQ-310, REQ-311, REQ-312, REQ-313, REQ-314, REQ-315, REQ-316, REQ-317, REQ-318, REQ-319, REQ-320, REQ-321, REQ-322]
  partial: []
---
2026-08-19 03:54:29 +00:00
Jon Chery f06a4c55b4 merge(milestone): v1.26 Live Pilot Estate Activation to main (release v1.25.5)
acdl-ci / Lint (push) Successful in 8s
acdl-ci / Test (push) Failing after 19s
acdl-ci / Platform check-only (offline) (push) Successful in 18s
Nova Slides Render / render (push) Failing after 17s
The first real consumer estate (blockchain stock exchange on a homegrown PoA blockchain,
equities only, dev) is activated against live AWS account 581513795199. All 13 requirements
(REQ-310..322) complete. 5 phases: P0 pre-execution, P1 blockchain-core, P2 contract+deploy,
P3 pilot-metrics-and-policies (Gitea adapter + kj substrate + outcome backfill + pilot policies),
P4 pilot-run-and-docs (live apply + Decision Ledger evidence stream), P5 final-review+audit.

Live outputs: ALB app-254671247.us-east-1.elb.amazonaws.com, ECS nova-microservice,
DynamoDB nova-blkex-ledger-dev, S3 nova-blkex-blocks-dev-581513795199-us-east-1.
Confidence 0.800 pass (dev autonomous). fact_decision.outcome=succeeded (REQ-317 backfill).

---ci---
project: acdl
phase: 5
milestone: v1.26
status: complete
requirements:
  covered: [REQ-310, REQ-311, REQ-312, REQ-313, REQ-314, REQ-315, REQ-316, REQ-317, REQ-318, REQ-319, REQ-320, REQ-321, REQ-322]
  partial: []
---
2026-08-19 03:53:58 +00:00
Jon Chery cbdb2e2b9a merge(phase/05): v1.26 P5 final review + audit complete — milestone release
P5 review: 0 P0 issues (1 cosmetic REQ-316 doc-drift fixed). Audit: reconstruction PASS, file discipline CLEAN, branch hygiene CLEAN (P1-P4 deleted, only milestone + P5 remain), commit discipline CLEAN. PROCEED to milestone ship.

---ci---
project: acdl
phase: 5
milestone: v1.26
status: complete
requirements:
  covered: [REQ-310, REQ-311, REQ-312, REQ-313, REQ-314, REQ-315, REQ-316, REQ-317, REQ-318, REQ-319, REQ-320, REQ-321, REQ-322]
  partial: []
---
2026-08-19 03:53:50 +00:00
Jon Chery 7e7a4fa853 docs(P05): final review + audit — PROCEED (0 P0 remain, audit CLEAN)
Multi-persona review across P1..P4 + audit (reconstruction, file
discipline, branch hygiene, commit discipline).

Review: 0 P0 issues remain after the REQ-316 traceability fix (committed
separately). Correctness spot-checks all PASS (kj substrate, outcome
backfill, Gitea adapter, env-JSON state_backend, pilot policies). 844
tests green (839 fast + 5 slow individually confirmed). No NOVA_AWS_*
secrets in committed files; test_no_forge_mentions PASS. 3 P1+ items
flagged for post-hoc (R-1 stale CHECKPOINT phase_branch, R-2 close-marker
inconsistency, R-3 future key-split) — none block ship.

Audit: reconstruction PASS (git-log ---ci--- blocks ↔ .ciagent/
consistent; phase 4/complete/v1.25.4 matches HEAD). File discipline CLEAN
(all 6 .ciagent/ files consistent). Branch hygiene CLEAN (only main +
milestone + P5; P1-P4 deleted; v1.25.0..v1.25.4 tagged). Commit discipline
CLEAN (all v1.26 commits carry ---ci--- blocks; merge commits included).

Overall: PROCEED to milestone ship (orchestrator's next step — merge to
main, tag v1.25.5, Gitea release, delete milestone branches, final
CHECKPOINT clear).

---ci---
project: acdl
phase: 5
milestone: v1.26
status: execute
wave: review-audit
---
2026-08-19 03:53:17 +00:00
Jon Chery 3a32c3b898 fix(P05): REQ-316 traceability — P4 live-verify complete (not pending)
The v1.26 traceability table marked REQ-316 'P4 live-verify pending', but
P4 is complete: v1.25.4 tagged, the live terraform apply against
581513795199 succeeded (commit 6ced8ed), verify PASS (074ee05), and the
CHECKPOINT notes confirm 'nova.outcome.backfilled (pending->succeeded)'.
Corrected to 'v1.25.4 — live-verify complete'. 0 P0 issues remain after
this fix.

---ci---
project: acdl
phase: 5
milestone: v1.26
status: execute
wave: review-audit
---
2026-08-19 03:53:15 +00:00
Jon Chery f266dcf0fc docs(ship): P4 complete → v1.25.4 (v1.26 pilot-run-and-docs)
---ci---
project: acdl
phase: 4
milestone: v1.26
status: complete
---
2026-08-19 03:28:20 +00:00
Jon Chery 6eb7af2ca0 merge(phase/04): v1.26 P4 pilot-run-and-docs complete (live apply + REQ-321 docs)
P4 W1: live terraform apply against 581513795199 succeeded (ALB + ECS + DynamoDB + S3).
Decision Ledger: ai.decision.made + nova.outcome.backfilled (outcome pending->succeeded).
2 module-completeness gaps fixed (ecs-service execution_role_arn, ALB SG). P4 W2: docs
(adapters/README, METRICS, ARCHITECTURE §12.8, consumer onboarding). 844 platform + 90 consumer tests green.

---ci---
project: acdl
phase: 4
milestone: v1.26
status: complete
---
2026-08-19 03:28:02 +00:00
Jon Chery 074ee05f83 verify(P04): PASS — live apply succeeded, evidence stream complete, docs done
Nova Slides Render / render (push) Failing after 17s
---ci---
project: acdl
phase: 4
milestone: v1.26
status: verify
---
2026-08-19 03:28:02 +00:00
Jon Chery a0799f13e5 docs(P04 W2): pilot-run docs (REQ-321) — adapters/README, METRICS, ARCHITECTURE §12.8, consumer onboarding
- adapters/README.md: fixed stale TYPE_MAP/INPUT_MAP refs (the adapter is a
  stateless assembler); added the blockchain-exchange consumer row + the
  Gitea adapter note (SPEC §10 Q1 — no cross-repo uses:)
- docs/METRICS.md: Post-Pilot denominators activated (AI Decision Accuracy +
  Human Escalation Frequency + the third metric now have non-zero data from
  the blkex-pilot-apply-v0.2 run)
- .ciagent/ARCHITECTURE.md §12.8: Pilot Estate (v1.26 live) — the first real
  consumer estate, the live apply, the Gitea adapter, the evidence stream
- .ciagent/nova-blockchain-exchange/README.md: consumer onboarding guide
  (deploy invocation, secrets, contract shape, verification)

---ci---
project: acdl
phase: 4
milestone: v1.26
status: execute
wave: W2
---
2026-08-19 03:27:27 +00:00
Jon Chery 6ced8eda7d docs(P04 W1): live pilot run evidence — apply succeeded, outcome backfilled (v1.26)
terraform apply against 581513795199 succeeded: ALB app-254671247.us-east-1.elb.amazonaws.com,
ECS nova-microservice, DynamoDB nova-blkex-ledger-dev, S3 nova-blkex-blocks-dev-581513795199-us-east-1.
Confidence 0.800 pass (dev autonomous). Decision Ledger: ai.decision.made (human_override=false) +
nova.outcome.backfilled (pending->succeeded, REQ-317). Hash chain valid. Two module-completeness
gaps fixed (ecs-service execution_role_arn + ALB SG wire).

---ci---
project: acdl
phase: 4
milestone: v1.26
status: execute
wave: W1
---
2026-08-19 03:05:17 +00:00
Jon Chery cec34abc22 fix(P04 W1): ecs-service execution_role_arn + task_role_arn wiring (live apply gap)
The live terraform apply (P4) uncovered a P2 module-completeness gap: the
ecs-service L1 aws_ecs_task_definition was missing execution_role_arn +
task_role_arn, and the microservice L2 composition did not wire
roles.outputs.role_arn to the service. Fargate requires an execution role
for ECR image pull. Fixed: interface.json + variables.tf + main.tf +
composition.json wires. The iam-role assume-policy trusts ecs-tasks +
the inline policy grants ECR pull + CW logs.

A second live gap surfaced once the task definition applied: the ALB
aws_lb had no security group (AWS rejects an ALB with an empty SG list).
The platform VPC only outputs an ECS SG; the composition now wires
platform_vpc.outputs.ecs_security_group_id to alb.inputs.security_group
(the ECS SG opens port 80 to 0.0.0.0/0 — acceptable for an internet-facing
ALB + dev pilot per D-020). No iam-role module changes were needed — its
locals.tf already trusts ecs-tasks.amazonaws.com and grants ECR pull +
CloudWatch logs by default.

Live apply now succeeds: Apply complete! Resources: 0 added, 1 changed, 0
destroyed (task def + ECS service created on the first re-apply; ALB SG
updated in-place on the second). Full suite: 844 passed.

---ci---
project: acdl
phase: 4
milestone: v1.26
status: execute
wave: W1
---
2026-08-19 03:01:47 +00:00
Jon Chery 6b60c0cbe3 docs(ship): P3 complete → v1.25.3 (v1.26 pilot-metrics-and-policies)
---ci---
project: acdl
phase: 3
milestone: v1.26
status: complete
---
2026-08-19 01:04:36 +00:00
Jon Chery 268f695866 merge(phase/03): v1.26 P3 pilot-metrics-and-policies complete (REQ-315..320, SPEC §10 Q1 Gitea adapter, SPEC §5.9 rotation)
P3 waves: W0 Gitea adapter (consumer deploy.yml inline — §10 Q1 resolved),
W0.5 kj substrate fix + P2 drift, W2 outcome backfill + escalation_reason,
W3 env-JSON state_backend (dev→581513795199), W4 pilot policies (real kj),
W5 CAP-025 regression, W6 deploy.yml drift (AWS_DEFAULT_REGION, ref v1.25),
W7 rotation scheduled workflow. 844 platform + 90 consumer tests green.

---ci---
project: acdl
phase: 3
milestone: v1.26
status: complete
---
2026-08-19 00:48:37 +00:00
20 changed files with 1546 additions and 1224 deletions
+63 -3
View File
@@ -501,9 +501,69 @@ deterministic scripts" tenet holds — kyverno-json is deterministic, not
AI; the `is_configured()` guard ensures the platform runs even when the AI; the `is_configured()` guard ensures the platform runs even when the
binary is not installed). binary is not installed).
> **§12.8 — Pilot Estate** is planned for the v1.26 P4 phase (REQ-321). ### §12.8 — Pilot Estate (v1.26, live)
> It will document the live-pilot architecture (consumer contract →
> `deploy.yml@v1.25` → apply → attest → record against `581513795199`). The first real consumer estate is **`nova-blockchain-exchange`** — a
blockchain stock exchange on a homegrown Proof-of-Authority chain,
equities only, dev only (D-020/D-200/D-201). The live apply landed on
2026-08-19 against AWS account `581513795199`. This is the estate that
activated the Post-Pilot metric denominators (see `docs/METRICS.md`).
**The live apply (run id `blkex-pilot-apply-v0.2`):**
- Target: account `581513795199`, environment `dev`, autonomous (no
HITL — dev is the only autonomous environment, confidence ≥ 0.50).
- The microservice L2 composition (ECS Fargate running nginx) + the
`dynamodb` L1 (the `nova-blkex-ledger-dev` table) + the `s3` L1 (the
`nova-blkex-blocks-dev-581513795199-us-east-1` bucket).
- The platform VPC prerequisite (`vpc-0d7c8867e6cc080f1` + 6 subnets +
the ECS SG) is read via `terraform_remote_state` — the L2 composition
does not own the network boundary (the "restricted from
thin-composition" rule from §Layer 2).
- Confidence signal: score **0.800**, band **pass**; `human_override`
false; `escalation_reason` absent (clean apply).
**The Gitea adapter (SPEC §10 Q1):** Gitea Actions does not support
cross-repo `uses:`, so the consumer's `deploy.yml` is an **inline
adapter** — `actions/checkout@v4` the consumer, `actions/checkout@v4`
`acdl/acdl` @ `ref: v1.25` into `platform/`, then
`bash platform/scripts/run_platform.sh ...`. The platform's own
`.github/workflows/deploy.yml` stays as the GitHub Actions reference
impl (the reusable `workflow_call` workflow). See `adapters/README.md`
§Consumers for the adapter note.
**The Decision Ledger evidence stream** (the apply produces these
events in order):
```
nova.confidence.computed (score 0.800, band pass)
nova.ai.decision.made (decision_id blkex-pilot-apply-v0.2,
chosen_action pass, human_override false)
nova.attestation.recorded (dev = no HITL gate; the record exists,
the gate is a no-op in the autonomous env)
nova.run.completed (apply succeeded)
nova.outcome.backfilled (outcome pending → succeeded, REQ-317;
backfilled_at 2026-08-19T03:05:04Z)
```
The SQLite hash-chain is valid (0 breaks). S3 Object Lock / JWS
(D-083) stays deferred — the SQLite Decision Ledger is the pilot's
audit record (D-204).
**Live outputs (account 581513795199):**
- ALB DNS: `app-254671247.us-east-1.elb.amazonaws.com`
- ECS service: `arn:aws:ecs:us-east-1:581513795199:service/nova-cluster/nova-microservice`
- DynamoDB table: `nova-blkex-ledger-dev` (PK `block_index`, PAY_PER_REQUEST)
- S3 bucket: `nova-blkex-blocks-dev-581513795199-us-east-1` (versioning + SSE)
The full evidence (every ARN, the confidence JSON, the Decision Ledger
rows, the module-completeness gaps the live apply uncovered) is in
`.ciagent/P4-PILOT-RUN-EVIDENCE.md`.
### §12.9 — Secret Rotation (v1.26 P3 W7, SPEC §5.9 — current) ### §12.9 — Secret Rotation (v1.26 P3 W7, SPEC §5.9 — current)
+10 -30
View File
@@ -1,35 +1,15 @@
{ {
"phase": 3, "phase": 0,
"stage": "verify", "stage": "research",
"milestone": "v1.26", "milestone": "v1.27",
"phase_role": "execution", "phase_role": "pre_execution",
"attempts": 0, "attempts": 0,
"updated_at": "2026-08-19T00:00:00Z", "updated_at": "2026-08-19T04:30:00Z",
"project": "acdl", "project": "acdl",
"projects": ["acdl", "nova-blockchain-exchange"], "projects": ["acdl", "nova-blockchain-exchange"],
"active_milestone": "v1.26", "active_milestone": "v1.27",
"milestone_branch": "milestone/v1.26-pilot-activation", "milestone_branch": "milestone/v1.27-po-state-catalog",
"phase_branch": "phase/03-pilot-metrics-and-policies", "phase_branch": "phase/00-pre-execution",
"tag_line": "v1.25.x", "tag_line": "v1.26.x",
"previous_phase": {"phase": 2, "tag": "v1.25.2", "status": "complete"}, "notes": "NFR milestone. PO state catalog + .ciagent/ compression. 3 phases planned (P1 author+archive, P2 fix-stale+wire, P3 final)."
"current_phase": {"phase": 3, "tag": "v1.25.3", "status": "verify"},
"requirements": ["REQ-315", "REQ-316", "REQ-317", "REQ-318", "REQ-319", "REQ-320"],
"waves": {
"W0": "Gitea adapter — inline checkout-then-call in consumer deploy.yml (SPEC §10 Q1 resolved, consumer repo)",
"W0.5": "kyverno-json substrate fix (v1.25 skip-masked bug) + P2 drift (dynamodb examples, sync_workflows, deck path)",
"W2": "outcome backfill (REQ-317) + escalation_reason (REQ-318)",
"W3": "env-JSON state_backend wiring (REQ-319) — dev bound to 581513795199",
"W4": "pilot-readiness (REQ-320) + settlement-finality (REQ-315) kyverno-json policies — run against real kj",
"W5": "CAP-025 live-pilot-apply regression check (REQ-316)",
"W6": "deploy.yml drift fixes — AWS_DEFAULT_REGION from secret, ref v1.25, no raw NOVA_AWS_* in shell env (SPEC §5.1/§5.2)",
"W7": "secret rotation scheduled workflow (SPEC §5.9) + forge-agnostic token name (REQ-230)"
},
"pre_run": {
"flaky_test_fixed": "8c68d68 test(metrics): fix attestation-event test freshness time-bomb",
"acdl_to_nova_migration": "f844fea chore(bootstrap): migrate ACDL_* env vars to NOVA_*",
"aws_bootstrap": "S3 nova-tfstate-581513795199-us-east-1 + DynamoDB nova-outbox created (idempotent, account 581513795199)",
"consumer_repo_created": "continuous-intelligence/nova-blockchain-exchange (Gitea, private, init, cloned to /root/nova-blockchain-exchange)",
"kj_installed": "kyverno-json v0.0.3 via go install (binary kyverno-json symlinked as kj) — policy tests run, not skipped"
},
"notes": "v1.26 P3 verify PASS. W0 Gitea adapter (consumer deploy.yml inline — SPEC §10 Q1 resolved). W0.5 fixed v1.25 skip-masked kj substrate bug (engine + 16 policies + install script) + 7 pre-existing P2 drift failures. W2 outcome backfill + escalation_reason. W3 env-JSON state_backend (dev→581513795199). W4 pilot policies (real kj). W5 CAP-025. W6 deploy.yml drift (AWS_DEFAULT_REGION, ref v1.25). W7 rotation workflow. 844 platform + 90 consumer tests green. Ready for P3 SHIP → v1.25.3."
} }
+126 -169
View File
@@ -1,226 +1,183 @@
# CLARIFY — v1.26 Live Pilot Estate Activation # CLARIFY — v1.27 PO State Catalog & Ciagent Compression
> **Autonomy:** full. Auto-resolution with assumption logging per > **Autonomy:** full. Auto-resolution with assumption logging per
> `config.autonomy.level: "full"`. No human escalation unless > `config.autonomy.level: "full"`. No human escalation unless
> confidence < 0.60 (threshold `config.autonomy.decision_confidence_threshold`). > confidence < 0.60. The prior conversation resolved all material
> 10 ambiguities identified; all resolved (confidence ≥ 0.60). > ambiguities (4 user-answered questions). This file records the
> assumptions for the v1.27 record.
--- ---
## Method ## Method
The clarify stage identifies ambiguities in the v1.26 specification The clarify stage identifies ambiguities in the v1.27 specification
(PROJECT.md, REQUIREMENTS.md, ROADMAP.md) and resolves them at full and resolves them at full autonomy. The v1.27 spec is the user-approved
autonomy. Each ambiguity gets a decision ID (D-200+; continuing from plan from the prior conversation + the STATE.md design locked by 4
the v1.26 SPECIFY decisions D-200..D-205), a resolution, a confidence question answers. Each ambiguity gets a decision ID (D-214+; continuing
score, and a rationale. Resolutions update PROJECT.md + REQUIREMENTS.md from the v1.26 decisions D-200..D-213), a resolution, a confidence
+ ROADMAP.md as needed. score, and a rationale.
--- ---
## Ambiguities + Resolutions ## Prior-conversation resolutions (already locked, restated for the record)
### Q1 — Does the consumer repo's `.ciagent/` live in the platform repo or the consumer repo? These were resolved by user-answered questions in the conversation that
spawned v1.27. They are load-bearing for v1.27 execution and cited
here so the v1.27 record is self-contained.
**Ambiguity:** The user said "ciagent should track it as a separate ### Q-P1 — What should the new PO-reference file catalog?
project under this same path." Does "this same path" mean the platform
repo's `.ciagent/` directory (multi-project mode per `run.md` Step 0),
or a separate `.ciagent/` inside the consumer repo?
**Resolution:** The platform repo's `.ciagent/` directory. Multi-project **Resolution:** Capability catalog (what the system can do today).
mode: `.ciagent/config.json` `projects[]` includes both `acdl` + **Confidence:** 1.0 (user-confirmed). **Decision:** D-214.
`nova-blockchain-exchange`; the consumer's project files
(PROJECT.md, REQUIREMENTS.md, ROADMAP.md) live in
`.ciagent/nova-blockchain-exchange/`. The consumer *git repo* owns the
app code + `contract.yaml` + deploy workflow invocation; the platform
repo owns the CIAgent planning artifacts for both projects. This
matches `run.md` Step 0 multi-project mode.
**Confidence:** 0.95. **Decision:** D-206. ### Q-P2 — How should the new file relate to CAPABILITY_INVENTORY.md?
### Q2 — Is the bootstrap `NOVA_AWS_*` key the root key or the spike-runner key? **Resolution:** Call it `STATE.md`. PO-owned, ciagent-updated after
milestone implementation. CAPABILITY_INVENTORY.md is archived.
**Confidence:** 1.0 (user-confirmed). **Decision:** D-215.
**Ambiguity:** The bootstrap scripts (post-migration) prefer ### Q-P3 — Where should the file live, and who owns it?
`NOVA_BOOTSTRAP_AWS_*`, falling back to `NOVA_AWS_*`. The pre-run
(A3) succeeded with `NOVA_AWS_*`, creating the S3 bucket + DynamoDB
table — which requires root or root-equivalent IAM. Is `NOVA_AWS_*`
the root key, or did the bootstrap succeed because the spike-runner
policy happens to include S3/DynamoDB create?
**Resolution:** `NOVA_AWS_*` has root-equivalent permissions (confirmed **Resolution:** Owned by the PO, updated by ciagent after the milestone
empirically: the bootstrap created the S3 bucket + DynamoDB table is implemented with additives.
successfully). For the pilot, `NOVA_AWS_*` is the bootstrap key. A **Confidence:** 1.0 (user-confirmed). **Decision:** D-216.
future hardening milestone should split this into a dedicated
`NOVA_BOOTSTRAP_AWS_*` root key + a least-privilege `NOVA_AWS_*` runner
key (the spike-runner pattern). For v1.26, the single key suffices
(pilot scope).
**Confidence:** 0.90. **Decision:** D-207. ### Q-P4 — How should "additive when new features are implemented" be enforced?
### Q3 — Which AWS account does the pilot use: `581513795199` (existing) or a dedicated pilot account? **Resolution:** On the last phase / milestone ship (the P-final Wave 3
"milestone ship" step). No regression-gate check in this pass.
**Confidence:** 1.0 (user-confirmed). **Decision:** D-217.
**Ambiguity:** The user said "assume 581513795199." But the env JSONs ### Q-P5 — Should the initial STATE.md backfill all shipped capabilities through v1.26?
all show `account_id: "000000000000"` (placeholder). Does the pilot
bind all env JSONs to `581513795199`, or only `dev` (with qa/prod/dr
left placeholder until a real multi-account landing zone exists)?
**Resolution:** Bind `dev` to `581513795199` for the pilot **Resolution:** Backfill all shipped capabilities through v1.26
(D-203, established in SPECIFY). The `qa`/`prod`/`dr` env JSONs remain (compressed one-liners for v1.1v1.24; full entries for v1.25 + v1.26).
placeholder `000000000000` this milestone — the pilot runs in `dev` **Confidence:** 1.0 (user-confirmed). **Decision:** D-218.
(autonomous, no HITL gate). Multi-account landing zone (qa/prod/dr on
separate accounts) is a future milestone. REQ-319 (env-JSON wiring)
updates `dev.json`'s `state_backend.bucket` to
`nova-tfstate-581513795199-us-east-1` + `account_id` to `581513795199`;
qa/prod/dr get the `state_backend.bucket` update but keep placeholder
`account_id` (the pilot-readiness policy REQ-320 blocks apply on
placeholder accounts — so qa/prod/dr apply is blocked by design until
the accounts are bound).
**Confidence:** 0.92. **Decision:** D-208. ### Q-P6 — Should the v1.26 pre-execution artifacts (CLARIFY, GRILL, IDEATE, RESEARCH) be archived?
### Q4 — Does "all types of securities" mean all types in v1.26, or equities-only pilot with others deferred? **Resolution:** Archive all 4 to `.ciagent/archive/` with `-v1.26`
suffixes. The next milestone's P0 writes fresh versions. Decisions are
already folded into PROJECT.md load-bearing decisions + PLAN.md
binding revisions.
**Confidence:** 1.0 (user-confirmed). **Decision:** D-219.
**Ambiguity:** The user said "stock market built on homegrown blockchain ---
offering all types of securities." This could mean equities + bonds +
derivatives + options all in v1.26, or equities-only pilot with others
deferred (the recommended scope from the plan).
**Resolution:** Equities-only pilot (D-200, established in SPECIFY). ## Ambiguities + Resolutions (this CLARIFY pass)
Bonds/derivatives/options have very different settlement models (T+1
for equities; T+2 for bonds; derivatives vary; options exercise
models). A pilot should demonstrate the Nova platform's policy gates
over a real estate — equities (T+1) is the simplest. "All types of
securities" is the *product vision*; v1.26 is the *pilot* (equities
first). The roadmap documents the deferral.
**Confidence:** 0.85. **Decision:** D-200 (reaffirmed). ### Q1 — Is v1.27 a feature milestone or an NFR milestone?
### Q5 — Is the homegrown blockchain a real consensus protocol or a minimal PoA ledger? **Ambiguity:** v1.27 authors `STATE.md` (a new file/capability for the
PO) and archives 11 files. Does the new-file authoring count as `feat:`
(making this a feature milestone, tags on v1.26.x with progressive
patches) or `docs:`/`chore:` (NFR milestone, same tag behavior but
subject to the NFR purity gate)?
**Ambiguity:** "Homegrown blockchain" could mean a full consensus **Resolution:** NFR milestone. `STATE.md` is documentation (a catalog of
protocol (multi-validator BFT) or a minimal PoA ledger (single existing capabilities), not a new platform capability. The archive moves
validator, append-only). are `chore:` (file relocation, lossless). No code, no schema, no
platform behavior change. Tags run on the v1.26.x patch line:
`v1.26.0` (P0) → `v1.26.1..v1.26.3` (P1..P3). The final phase's patch
(`v1.26.3`) IS the milestone release.
**Resolution:** Minimal PoA ledger (D-201, established in SPECIFY). **Confidence:** 0.95. **Decision:** D-220.
Single validator (config-driven), append-only blocks, SHA-256 hash
chain, deterministic block production. Settlement finality = block
commit. Multi-validator BFT is a future milestone. The pilot's purpose
is to exercise the Nova platform's deploy/policy/attestation gates over
a real consumer — the chain needs to be real enough to record
transactions, not to solve Byzantine consensus.
**Confidence:** 0.88. **Decision:** D-201 (reaffirmed). ### Q2 — Where does the consumer-side archive (nova-blockchain-exchange/ROADMAP.md) land?
### Q6 — Does the pilot's `terraform apply` actually run, or is it `--plan-only`? **Ambiguity:** The platform archive convention is
`.ciagent/archive/<file>-<milestone>.md`. The consumer subproject
(`nova-blockchain-exchange/`) has no `archive/` subdirectory. Does the
consumer ROADMAP archive at `.ciagent/archive/` (platform-side, mixed)
or `.ciagent/nova-blockchain-exchange/archive/` (consumer-side, new
subdir)?
**Ambiguity:** The platform's `run_platform.sh` defaults to **Resolution:** Consumer-side. Create
plan-only (no apply). The `deploy.yml` workflow's `mode` input can be `.ciagent/nova-blockchain-exchange/archive/` and relocate to
`full` (apply) or `plan-only`. Does the pilot actually `terraform apply` `ROADMAP-v1.26.md`. This preserves the per-project path convention
(creating real AWS resources for the blockchain exchange), or does it (multi-project mode: `.ciagent/<slug>/` paths). The platform archive
stop at plan? directory is not mixed with consumer archives.
**Resolution:** The pilot runs `mode: full` (apply) for `dev` only. **Confidence:** 0.92. **Decision:** D-221.
The apply creates real AWS resources (ECS for the matching engine,
DynamoDB for the ledger, S3 for block storage) in account
`581513795199`. `qa`/`prod`/`dr` are blocked by the pilot-readiness
policy (REQ-320) until their accounts are bound (D-208). The apply is
autonomous for `dev` (no HITL gate; confidence threshold 0.50). The
`ai.decision.made` + `attestation.recorded` events land in the Decision
Ledger — but `dev` attestation is autonomous (no human approver), so
only `ai.decision.made` fires for `dev`.
**Confidence:** 0.90. **Decision:** D-209. ### Q3 — Does archiving CLARIFY/GRILL/IDEATE/RESEARCH lose the "how v1.26 was specified" traceability?
### Q7 — What AWS resources does the blockchain exchange contract declare? **Ambiguity:** The pre-execution artifacts document the v1.26 decision
path. Archiving them moves them out of active context. Is the
traceability preserved?
**Ambiguity:** The `contract.yaml` declares the exchange's **Resolution:** Yes. Three layers preserve it: (1) the archive files
infrastructure. What specific AWS resources? The platform's adapter are byte-identical relocations inside `.ciagent/archive/` (reachable by
maps contract infrastructure blocks to Terraform. What stack types agents + git history); (2) the decisions D-200..D-213 are folded into
does the blockchain exchange use? `PROJECT.md` load-bearing decisions (the durable record); (3) git
history at the v1.26 commits preserves the authoritative state. The
active-context reduction is the point — v1.26 is shipped; the next P0
writes fresh CLARIFY/GRILL/IDEATE/RESEARCH.
**Resolution:** The pilot contract declares 3 infrastructure blocks: **Confidence:** 0.95. **Decision:** D-222.
(1) `ecs` (Fargate service for the matching engine + settlement
service — the platform's existing `microservice` module pattern), (2)
`dynamodb` (the ledger table — single-table, PK `block_index`), (3)
`s3` (block storage — one object per block, key `blocks/{index}.json`).
The adapter's `TYPE_MAP` already covers `aws_ecs_service`,
`aws_dynamodb_table`, `aws_s3_bucket` (existing L1 primitives). No new
adapter stack types needed for the pilot. The contract's
`infrastructure` block references these by module name (`microservice`
for ECS, `dynamodb` for the table, `s3` for the bucket).
**Confidence:** 0.82. **Decision:** D-210. ### Q4 — Should IAM_POLICY.md be archived (it predates v1.26 and is dated v1.11)?
### Q8 — Does the outcome-backfill emitter (REQ-317) change the PCR schema? **Ambiguity:** `IAM_POLICY.md` is dated v1.11 (2026-07-28). It predates
v1.26 by 5 milestones. The D-207 future key-split (P1+ R-3 in
REVIEW-AUDIT-P05) is pending. Archive or keep?
**Ambiguity:** REQ-317 wires `apply.completed`/`apply.failed` **Resolution:** Keep active. `IAM_POLICY.md` is a live baseline —
`fact_decision.outcome`. Does this touch the `PolicyCheckResult` schema referenced by the regression gate
(PCR) — the v1.25 moat that must not change? (`tests/test_iam_policy_baseline.py`), enforced by a managed policy on
account `581513795199`, and the D-207 key-split is a pending future-
hardening item. It is not stale; it is a baseline that grows when
grants change. The v1.11 date reflects the last grant addition, not
staleness.
**Resolution:** No. The outcome backfill touches the *metrics cold **Confidence:** 0.90. **Decision:** D-223.
store* (`fact_decision` table in `metrics/nova_metrics.db`), not the
PCR schema. The PCR schema (`schemas/policy_check_result.schema.json`)
is unchanged. The backfill reads run-manifest events (not PCRs) and
updates the decision's outcome column. This respects the v1.25 hard
constraint: "DO NOT change `schemas/policy_check_result.schema.json`."
**Confidence:** 0.95. **Decision:** D-211. ### Q5 — Should REGRESSION_REPORT.{json,md} be refreshed as part of v1.27?
### Q9 — Does the consumer repo need its own test suite + CI, or does the platform's CI cover it? **Ambiguity:** Both files are dated 2026-08-01 (v1.10 Phase 52), show
CAP-025 absent, and mark live-aws CAPs "Skipped" (state bucket absent
pre-v1.26 re-bootstrap). They are stale. Should v1.27 refresh them?
**Ambiguity:** The consumer repo (`nova-blockchain-exchange`) has app **Resolution:** No. Both files are machine-managed — written by
code (blockchain, engine, settlement). Does it run its own tests in `core/regression_verify.py:704-705` on every `run_regression.sh` run.
its own CI, or does the platform's `platform-test.yml` cover it? They regenerate on the next regression run. v1.27 is docs/chore only
(no code); touching machine-managed files by hand creates a drift
source. The stale state is honest (the last gate run was v1.10; the
next run regenerates). The STATE.md Domain 7 row "Regression gate"
notes the current CAP range (CAP-001..025).
**Resolution:** The consumer repo runs its own tests in its own CI **Confidence:** 0.88. **Decision:** D-224.
(`nova-blockchain-exchange/.github/workflows/ci.yml` — lint + pytest on
the blockchain/engine/settlement code). The platform's
`platform-test.yml` covers the *platform* repo only (it validates
contracts against the schema, runs adapter tests, etc.). The consumer
repo's `deploy.yml` invocation triggers the platform's deploy workflow
(which runs `run_platform.sh`); the platform's policy + attestation
gates apply over the consumer's apply. The consumer's unit tests
(chain integrity, order matching, settlement) are the consumer's
responsibility. REQ-310..312 include consumer-side tests
(`test_block.py`, `test_order_book.py`, `test_settlement.py`).
**Confidence:** 0.88. **Decision:** D-212. ### Q6 — Does PROJECT.md get the v1.26 phase-status fix in v1.27 P1 or P2?
### Q10 — Is the milestone a feature milestone (tags on v1.25.x) or a major milestone (breaking schema changes)? **Ambiguity:** The plan splits work into P1 (author + archive) and P2
(fix stale + wire). The PROJECT.md phase-status fix (P3/P4/P5 pending
→ complete) is a "fix stale" item. P1 or P2?
**Ambiguity:** v1.26 introduces a 2nd project (multi-project mode) + **Resolution:** P2. P1 is the additive authoring + lossless archive
new requirements. Does this break any schema (→ major milestone, tags moves. P2 is the corrections to kept files + the ship-discipline wiring.
on v1.26.x), or is it a feature milestone (tags on v1.25.x)? This keeps P1 a pure-additive, no-edit phase (easier review + audit) and
P2 the correction phase. The PROJECT.md fix is a correction; P2.
**Resolution:** Feature milestone. No schema breaks: the PCR schema is **Confidence:** 0.85. **Decision:** D-225.
unchanged (D-211); the contract schema is unchanged (the consumer
contract validates against the existing
`schemas/contract.schema.json`); the env JSON gains a real
`account_id` (data, not schema). Multi-project mode is a config
change (not a schema break). Tags run on the **v1.25.x** patch line:
`v1.25.0` (P0) → `v1.25.5` (P5 = milestone release). Per `run.md`
versioning logic: "Feature milestone (at least one feat phase):
progressive patches per phase. The final phase's patch IS the milestone
release. No separate minor tag."
**Confidence:** 0.92. **Decision:** D-213.
--- ---
## Summary ## Summary
10 ambiguities identified; all auto-resolved at full autonomy 6 prior-conversation resolutions (D-214..D-219, all user-confirmed)
(confidence ≥ 0.60). 8 new decisions (D-206..D-213) + 3 reaffirmed + 6 new ambiguities (D-220..D-225, all auto-resolved at full autonomy,
from SPECIFY (D-200, D-201, D-203). 0 escalations (all ≥ 0.60). The confidence ≥ 0.60). 0 escalations.
resolutions are recorded in this file + reflected in PROJECT.md /
REQUIREMENTS.md / ROADMAP.md updates.
**Key decisions:** **Key decisions:**
- D-206: `.ciagent/` for both projects in the platform repo (multi-project mode). - D-220: v1.27 is an NFR milestone (tags on v1.26.x; final patch is the
- D-207: `NOVA_AWS_*` has root-equivalent perms; single key for pilot. milestone release).
- D-208: `dev` bound to `581513795199`; qa/prod/dr stay placeholder (pilot-readiness policy blocks apply on placeholder). - D-221: Consumer archives land in `.ciagent/nova-blockchain-exchange/archive/`.
- D-209: Pilot runs `mode: full` (apply) for `dev` only; autonomous (no HITL gate). - D-222: Archiving pre-execution artifacts preserves traceability
- D-210: Contract declares ecs + dynamodb + s3 (existing adapter stack types; no new TYPE_MAP entries). (archive files + PROJECT.md load-bearing decisions + git history).
- D-211: Outcome backfill touches metrics cold store, NOT the PCR schema (v1.25 moat preserved). - D-223: IAM_POLICY.md stays active (live baseline, test-enforced,
- D-212: Consumer repo has its own CI + unit tests; platform CI covers platform only. D-207 pending).
- D-213: Feature milestone; tags on v1.25.x (no schema breaks). - D-224: REGRESSION_REPORT.{json,md} regenerate on next
`run_regression.sh` (machine-managed; v1.27 is docs/chore only).
- D-225: PROJECT.md phase-status fix is P2 (correction phase), not P1
(additive phase).
+108 -192
View File
@@ -1,225 +1,141 @@
# GRILL — v1.26 Live Pilot Estate Activation # GRILL — v1.27 PO State Catalog & Ciagent Compression
> Adversarial review of the v1.26 SPECIFY + CLARIFY + RESEARCH + IDEATE + > Adversarial review of the v1.27 SPECIFY + CLARIFY + RESEARCH + PLAN.
> PLAN. The grill red-teams the proposal across feasibility, scope, > The grill red-teams the proposal across feasibility, scope, and the
> budget, and the domain claims (homegrown blockchain, pilot estate, > compression-loss claims. Each challenge gets a binding verdict
> metric grounding). Each challenge gets a binding verdict > (PROCEED / REVISE / ESCALATE). Autonomy: full.
> (PROCEED / REVISE / ESCALATE). Autonomy: full — escalations auto-
> resolve with assumption logging unless confidence < 0.60.
## Verdict: PROCEED (0.84) — 0 escalations, 2 revisions ## Verdict: PROCEED (0.88) — 0 escalations, 1 revision
The milestone is feasible, scoped, and the domain claims hold. Two The milestone is feasible, scoped, and the compression is lossless. One
plan revisions are binding (G-Q4, G-Q8) and are already captured in binding revision (G-Q2) refines the archive list; already captured in
PLAN.md. No work is blocked. PLAN. No work is blocked.
--- ---
## Challenges ## Challenges
### G-Q1 — Is a homegrown PoA blockchain viable for a pilot, or is it reckless? ### G-Q1 — Is archiving AUTONOMY_THESIS.md + COST.md a context loss?
**Challenge:** Authoring a blockchain (even a minimal PoA ledger) is a **Challenge:** `AUTONOMY_THESIS.md` is the "autonomy in operations;
non-trivial domain. A homegrown chain could have correctness bugs (hash human at stage gates" thesis — the defensibility brief. `COST.md` is
chain breaks, non-deterministic blocks, settlement-finality race the only AWS cost record. Archiving both moves them out of active
conditions). Why not use a proven chain (Ethereum L2, Solana, Hyperledger context. Does this lose load-bearing content?
Fabric)?
**Verdict:** PROCEED (confidence 0.88). The pilot's purpose is to **Verdict:** PROCEED (confidence 0.90).
exercise the Nova platform's deploy/policy/attestation gates over a - `AUTONOMY_THESIS.md` (65 lines, "Last refined: v1.21") is fully
real consumer estate — not to build a production blockchain. A folded into `NORTH_STAR.md` Vision (lines 1722: "infrastructure
homegrown PoA ledger is the minimal viable chain: append-only blocks, operations become visible... human attestation remains required at
single validator, SHA-256 hash chain, deterministic block production. stage gates") + Anti-Goals #2 ("Not a system that removes humans from
This is ~200 lines of Python (block + ledger + validator). The chain accountability"). The thesis is the source; NORTH_STAR is the
needs to be real enough to record transactions + produce a settlement- authoritative durable copy. Archive preserves the v1.21 refinement;
finality signal for the kyverno-json policy (REQ-315) — not to solve active context reads NORTH_STAR.
Byzantine consensus. A proven chain (Ethereum/Solana/Hyperledger) would - `COST.md` (106 lines, dated 2026-07-29, "v1.0 → v1.14") predates the
be the *consumer app's* choice, not the platform's; the platform is v1.26 live pilot. The v1.26 live apply (ECS + ALB + DynamoDB + S3)
chain-agnostic. For the pilot, the homegrown chain avoids a heavyweight incurred real costs this snapshot doesn't reflect. Archiving it is
external dependency (a full node, smart contracts, gas models) that honest — a stale cost record misleads. STATE.md Domain 7 notes cost
would obscure the platform-gates demonstration. REQ-310 tests cover tracking as a capability (pre-apply Infracost grounded; actual-spend
chain integrity, hash determinism, genesis, append/verify — the CUR deferred D-096). A future cost milestone writes a fresh report.
correctness surface is bounded. Multi-validator BFT is a future No revision needed.
milestone (D-201). No revision needed.
### G-Q2 — Does "all types of securities" scope-explode the milestone? ### G-Q2 — Does the archive list include the v1.27 P0 pre-execution files by mistake?
**Challenge:** The user said "offering all types of securities." Equities **Challenge:** D-219 (user-confirmed) says "archive all 4 pre-execution
(D-200, pilot scope) is one type. Bonds (T+2), derivatives (varying), artifacts" (CLARIFY/GRILL/IDEATE/RESEARCH). But P0 already overwrote
options (exercise models) have very different settlement models. Does them with v1.27 content. Archiving the v1.27 versions at v1.27 P1 would
the equities-only deferral betray the user's intent? lose the v1.27 pre-execution narrative (the decisions D-214..D-225, the
research inventory, this grill). Is the archive list wrong?
**Verdict:** PROCEED (confidence 0.85). The user *chose* equities-only **Verdict:** REVISE (confidence 0.92). This is a real ambiguity in the
pilot (Q4 in the plan discussion, answer "A to all 3 questions" — the plan. The user's D-219 decision was made *before* P0 overwrote the
recommended scope). "All types of securities" is the *product vision*; files; the intent was to archive the *v1.26* pre-execution record. The
v1.26 is the *pilot* (equities first). The roadmap documents the v1.26-era content is preserved in git history (the pre-P0 commits) —
deferral. The pilot demonstrates the Nova platform's gates over the the archive directory is not the only preservation layer. PLAN Task 2.1
simplest settlement model (T+1); expanding to other security types is already self-corrected: the final archive list is **7 platform files +
a straightforward extension (new settlement-service branches + new 1 consumer file = 8 files**, excluding the 4 pre-execution files. The 4
kyverno-json policies) once the platform-gates pattern is proven. No v1.27 P0 versions stay active through v1.27; they archive at v1.28 P1
revision needed — the scope decision is the user's, not the grill's. if v1.28 happens. The archive README notes the v1.26 pre-execution
record is in git history. No further revision needed — the plan self-
corrected.
### G-Q3 — Does the consumer-repo-as-2nd-project break single-project tooling? ### G-Q3 — Is the STATE.md backfill accurate enough to be the PO's source of truth?
**Challenge:** CIAgent has been single-project since v1.0. v1.26 **Challenge:** STATE.md has 36 capability rows across 10 domains,
activates multi-project mode (2 projects: `acdl` + backfilled from 8 sources. The PO will read this before writing new
`nova-blockchain-exchange`). Does this break assumptions in the REQs. If a row is inaccurate (wrong shipped tag, wrong file path,
CIAgent tooling (branch naming, `.ciagent/` paths, commit `---ci---` wrong controlling REQ), the PO could re-spec an existing capability or
blocks)? cite a stale invariant. Is the backfill accurate?
**Verdict:** PROCEED (confidence 0.90). `run.md` Step 0 explicitly **Verdict:** PROCEED (confidence 0.85). The backfill sources are
specifies multi-project mode: `projects[]` with length > 0, authoritative: `core/regression_verify.py` (the machine CAP-NNN
`active_projects` array, `.ciagent/<slug>/` subdirectory paths, branch registry), `modules/registry.json` (the live module catalog),
prefixes `<slug>/`. The `---ci---` block gains a `project: <slug>` `REQUIREMENTS.md` traceability (the REQ→phase→status record),
field (already in the v1.26 commits). The consumer's project files `CHECKPOINT.json` (shipped tags), `git log` (file paths). The
live in `.ciagent/nova-blockchain-exchange/`. The platform's existing citations are direct (each row cites the controlling REQ + decision
flat `.ciagent/` files remain the primary set (the platform is the ID). The 11 invariants are distilled from PROJECT.md load-bearing
default project). Branch naming: the consumer's phases use decisions D-034..D-072 + W1..BA + Q1.3. The accuracy risk is
`nova-blockchain-exchange/phase/01-...`; the platform's phases use mitigated by P1 Wave 1 (verify STATE.md against sources before
`acdl/phase/03-...` (or flat `phase/03-...` for platform-level work). archive). No revision needed — the verification step is in the plan.
No tooling change needed — the multi-project spec is already in
`run.md`. D-206 records this. No revision needed.
### G-Q4 — Does the P2 contract reference a `dynamodb` module that doesn't exist until P3? ### G-Q4 — Does the NFR purity gate (zero `feat:` commits) hold for v1.27?
**Challenge:** The original plan had REQ-322 (DynamoDB primitive) in **Challenge:** v1.27 authors STATE.md (a new file). Is authoring a new
P3, but the P2 contract (REQ-313) references `dynamodb` in its catalog file a `feat:` (feature) that breaks the NFR purity gate?
`infrastructure` block. If the primitive doesn't exist until P3, the
P2 contract's `dynamodb` block can't resolve at registry time — only
at schema time (the schema is open). Is this a vertical-slice
violation (P2 ships a contract that can't fully resolve)?
**Verdict:** REVISE (confidence 0.92). This is a real vertical-slice **Verdict:** PROCEED (confidence 0.92). D-220 (CLARIFY) resolved this:
violation. PLAN.md already revised: REQ-322 moves to P2 W0 (before the STATE.md is documentation (a catalog of *existing* capabilities), not a
contract). The revised mapping (PLAN.md "Revised: REQ-322 → P2 W0") new platform capability. The archive moves are `chore:` (file
makes P2 self-contained: the primitive + the contract + the deploy relocation, lossless). No code, no schema, no platform behavior
invocation all land in P2. This is a binding revision — the original change. The NFR purity gate (zero `feat:` commits) holds. All v1.27
P3 placement is superseded. ROADMAP.md is already updated (REQ-322 in commits use `docs(P0N):` or `chore(P01):` prefixes. No revision
P2). No further revision needed — the plan self-corrected. needed.
### G-Q5 — Does live-AWS pilot break the MTTR < 60s target? ### G-Q5 — Does fixing PROJECT.md phase-status in P2 create a P0/P1 audit inconsistency?
**Challenge:** NORTH_STAR.md MTTR target: < 60s p95. The pilot runs **Challenge:** The PROJECT.md phase-status block shows P3/P4/P5 as
`terraform apply` (creating real AWS resources: ECS + DynamoDB + S3). "pending" (the bug flagged in the prior conversation). P0 + P1 ship
Apply latency for a 3-resource stack is typically 2-5 minutes (ECS with the bug still present (the fix is P2). Does the P0/P1 audit see
service creation is the slow step). Does this break the MTTR target? the inconsistency?
**Verdict:** PROCEED (confidence 0.86). The MTTR target is for **Verdict:** PROCEED (confidence 0.86). The bug is pre-existing
*platform-detected + platform-remediated incidents* (apply.failed → (it predates v1.27; it was the trigger for the prior conversation).
successful retry), not for first-time apply latency. The pilot's P0/P1 audits check the *v1.27* commits against the `.ciagent/` state,
first apply is a deployment, not an incident-remediation. The MTTR not the pre-existing PROJECT.md drift. The P2 fix is the correction;
metric measures the retry path: if the apply fails (e.g. IAM the P3 audit verifies the fix landed. The intermediate state (P0/P1
permission), the platform retries — the retry MTTR is the time from with the bug present) is honest — the bug is documented in the v1.27
`apply.failed` to `apply.succeeded`, which is < 60s for a retry (the PLAN + the prior conversation, and the fix is scheduled. No revision
resources are already partially created; the retry completes the needed — the phasing is intentional (D-225: P1 additive, P2
remaining steps). The pilot's apply latency is a deployment metric correction).
(lead time), not an MTTR metric. RESEARCH §1.2 (v1.25 grill G-Q3)
analyzed this same question for the kyverno-json pass — the same
reasoning applies. No revision needed.
### G-Q6 — Is the settlement-finality policy (REQ-315) over-engineering for a pilot? ### G-Q6 — Is the milestone scoped too small (3 phases, 8 archive moves)?
**Challenge:** A kyverno-json policy asserting settlement finality **Challenge:** v1.27 is a small milestone (3 phases, ~15 file
(`all_committed: true`) before promotion is a securities-specific operations, no code). Is it worth a milestone, or should it be a
extension of v1.25's policy engine. Is this over-engineering for a patch on v1.26?
pilot that only runs in `dev` (autonomous, no promotion to qa/prod/dr
in v1.26 per D-208)?
**Verdict:** PROCEED (confidence 0.80). The policy is *authored* in **Verdict:** PROCEED (confidence 0.88). v1.27 is not a patch on v1.26
v1.26 (P3) but its *enforcement* activates when a promotion to qa/prod v1.26 is shipped (`v1.25.5`, merged to main, milestone complete).
happens — which is a *future* milestone (D-208: qa/prod/dr stay The work is a new milestone by definition. The size is appropriate:
placeholder this milestone). The policy is tested (passing + failing STATE.md is a durable PO-facing artifact (loaded every ci-run going
fixtures; skip when `kj` absent) in P3, but it doesn't gate a `dev` forward); the compression reduces active context by ~26%; the
apply (the pilot-readiness policy REQ-320 gates `dev`; the settlement- ship-discipline wiring affects every future milestone ship. Small but
finality policy gates promotions). Authoring + testing the policy in high-leverage. No revision needed.
v1.26 is the right thing: it (a) proves the kyverno-json engine can
assert a domain invariant, (b) ships the policy artifact so a future
milestone that binds qa/prod/dr can enable it without re-architecting,
(c) extends v1.25's moat (the policy engine is swappable + extensible
to new domains). The cost is ~1 policy file + 1 test file. No revision
needed — but the POLICY IS NOT ENFORCED in v1.26 (it's authored +
tested, enforcement is future). PLAN.md should note this. **Minor
revision: PLAN.md P3 W4 Task 4.1 should note "policy authored + tested;
enforcement deferred to the milestone that binds qa/prod/dr."** Already
implicit in the plan (the policy gates promotions, not dev applies);
making it explicit is a documentation refinement, not a scope change.
### G-Q7 — Is D-083 deferral defensible for a pilot with real money-like flows?
**Challenge:** The pilot is a stock exchange — securities trading. D-083
(S3 Object Lock / JWS tamper-evident ledger) is deferred (D-204). The
SQLite hash-chain + DynamoDB outbox is the audit record. Is this
defensible for a domain where audit integrity is legally mandated?
**Verdict:** PROCEED (confidence 0.82). The pilot is a *technical
demonstration*, not a production trading system. No real money, no real
securities, no real investors — the "securities" are test tokens on a
homegrown chain. The audit integrity requirement (SEC Rule 17a-4, FINRA
retention) applies to *production* trading systems, not to a pilot
exercising a platform's deploy/policy/attestation gates. The SQLite
hash-chain + DynamoDB outbox is a tamper-*evident* record (any tampering
breaks the hash chain) — it's just not tamper-*resistant* (S3 Object
Lock + JWS would make it tamper-resistant). For a pilot, tamper-evident
suffices. D-083 lift is a future milestone (when the pilot becomes a
production system). D-204 records this. No revision needed.
### G-Q8 — Does the outcome-backfill emitter (REQ-317) touch the PCR schema?
**Challenge:** REQ-317 wires `apply.completed`/`apply.failed`
`fact_decision.outcome`. The v1.25 hard constraint says "DO NOT change
`schemas/policy_check_result.schema.json`." Does the backfill touch the
PCR schema?
**Verdict:** PROCEED (confidence 0.95). D-211 (CLARIFY) already
resolved this: the outcome backfill touches the *metrics cold store*
(`fact_decision` table in `metrics/nova_metrics.db`), not the PCR
schema. The backfill reads run-manifest events (not PCRs) and updates
the decision's outcome column. The PCR schema is unchanged. This
respects the v1.25 hard constraint. No revision needed.
### G-Q9 — Does the `NOVA_AWS_*` root-equivalent key create a security risk?
**Challenge:** D-207 says `NOVA_AWS_*` has root-equivalent permissions
(confirmed empirically: the bootstrap created the S3 bucket + DynamoDB
table). Using a root key for the pilot's `terraform apply` is a
security risk — a key compromise gives full account access. Should the
pilot use a least-privilege key?
**Verdict:** PROCEED (confidence 0.78). The risk is real but bounded:
(a) the pilot runs in a single account (`581513795199`) with no
production workloads (the v1.11 teardown left it empty; the pilot is
the only workload), (b) the key is in `.env.secrets` (gitignored, never
committed), (c) the deploy workflow uses OIDC by default (the static
key is the override, not the primary path). A future hardening
milestone should split `NOVA_AWS_*` into a root `NOVA_BOOTSTRAP_AWS_*`
+ a least-privilege `NOVA_AWS_*` runner key (the spike-runner pattern).
For v1.26, the single key suffices (pilot scope). D-207 records this.
**Minor revision: PLAN.md should note the key-split as a future
hardening item.** Already implicit in D-207; making it explicit in the
plan is a documentation refinement.
--- ---
## Summary ## Summary
9 challenges; 0 escalations; 2 binding revisions (G-Q4, G-Q6/G-Q9 6 challenges; 0 escalations; 1 binding revision (G-Q2, already
minor). Overall verdict: PROCEED (confidence 0.84). captured in PLAN Task 2.1). Overall verdict: PROCEED (confidence
0.88).
**Binding revisions:** **Binding revisions:**
- **G-Q4:** REQ-322 moves to P2 W0 (already revised in PLAN.md + ROADMAP.md). - **G-Q2:** Archive list refined to 7 platform + 1 consumer = 8 files.
- **G-Q6:** PLAN.md P3 W4 Task 4.1 should note the settlement-finality The 4 pre-execution files (CLARIFY/GRILL/IDEATE/RESEARCH) stay active
policy is authored + tested in v1.26 but *enforcement* is deferred to through v1.27 (they hold the v1.27 P0 content); the v1.26-era content
the milestone that binds qa/prod/dr (documentation refinement). is in git history. Already in PLAN.
- **G-Q9:** PLAN.md should note the `NOVA_AWS_*` key-split as a future
hardening item (documentation refinement).
**No work is blocked.** The milestone is feasible, scoped, and the **No work is blocked.** The milestone is feasible, scoped, the
domain claims hold. The homegrown PoA blockchain is a minimal viable compression is lossless (archive + git history), the STATE.md backfill
chain (~200 lines), not a production consensus protocol. The equities- is source-grounded with a verification step, the NFR purity holds, and
only scope is the user's choice. The multi-project mode is specified in the phasing (P1 additive, P2 correction, P3 ship) is sound.
`run.md`. The P2→P3 dependency is resolved (REQ-322 → P2 W0). The
MTTR target is for incident-remediation, not first-time apply. The
settlement-finality policy is authored + tested, enforcement is future.
D-083 deferral is defensible for a technical pilot. The PCR schema is
unchanged. The root-equivalent key is a bounded risk with a documented
future hardening path.
+46
View File
@@ -0,0 +1,46 @@
# P4 — Live Pilot Run Evidence (v1.26, v0.2 re-run)
> The live `terraform apply` against AWS `581513795199` succeeded. The
> Decision Ledger + outcome backfill are complete. SPEC §5.8 evidence
> stream verified.
## Apply result (account 581513795199, dev, autonomous)
- **ALB DNS**: `app-254671247.us-east-1.elb.amazonaws.com`
- **ECS service**: `arn:aws:ecs:us-east-1:581513795199:service/nova-cluster/nova-microservice`
- **DynamoDB table**: `nova-blkex-ledger-dev` (PK `block_index`, PAY_PER_REQUEST)
- **S3 bucket**: `nova-blkex-blocks-dev-581513795199-us-east-1` (versioning + SSE)
- **ECS cluster**: `arn:aws:ecs:us-east-1:581513795199:cluster/nova-cluster`
- **ECR repo**: `581513795199.dkr.ecr.us-east-1.amazonaws.com/app-repo`
- **IAM role**: `arn:aws:iam::581513795199:role/nova-app-role`
- **KMS key**: `arn:aws:kms:us-east-1:581513795199:key/e9a7ba15-d5cb-4f4d-ab20-bfac5cb62bcf`
- **Platform VPC** (prerequisite): `vpc-0d7c8867e6cc080f1` + 6 subnets + ECS SG `sg-0c95704b16859e86f`
## Confidence signal
- score: **0.800**, band: **pass** (dev autonomous, ≥0.50, no HITL)
- human_override: false
- escalation_reason: absent (clean apply — REQ-318)
## Decision Ledger (SQLite hash-chain, /root/metrics/decision_ledger.db)
- `nova.ai.decision.made` — decision_id `blkex-pilot-apply-v0.2`, chosen_action `pass`, human_override false
- `nova.outcome.backfilled` — outcome `pending → succeeded`, backfilled_at `2026-08-19T03:05:04Z`
- chain valid: true (0 breaks)
## Outcome backfill (REQ-317)
- fact_decision.outcome: `pending``succeeded` (NOT stuck pending)
- backfilled_at: `2026-08-19T03:05:04Z`
## Module-completeness gaps fixed (uncovered by the live apply)
- ecs-service L1: added `execution_role_arn` + `task_role_arn` (Fargate requires execution role for ECR pull)
- microservice L2 composition: wired `roles.outputs.role_arn``service.inputs.{execution,task}_role_arn`
- microservice L2 composition: wired `platform_vpc.outputs.ecs_security_group_id``alb.inputs.security_group` (ALB requires a SG)
## Run id
- NOVA_RUN_ID: `blkex-pilot-apply-v0.2`
---ci---
project: acdl
phase: 4
milestone: v1.26
status: execute
wave: W1
---
+51 -143
View File
@@ -1,169 +1,77 @@
--- ---
project: acdl project: acdl
milestone: v1.26 milestone: v1.27
generated_at: 2026-08-12 generated_at: 2026-08-19
generator: lead-developer generator: lead-developer
verification_toolchain: verification_toolchain:
typecheck: "python3 -m py_compile core/confidence_signal.py core/metrics/outcome_backfill.py adapters/terraform/adapter.py modules/l1/dynamodb/terraform/main.tf" typecheck: "python3 -m py_compile core/confidence_signal.py 2>&1 | head -5 || true"
test: "pytest tests/test_adapter.py tests/test_contract_resolver.py tests/test_confidence_signal.py tests/test_outcome_backfill.py tests/test_settlement_finality_policy.py tests/test_pilot_readiness_policy.py tests/test_block.py tests/test_order_book.py tests/test_settlement.py -v" test: "bash scripts/run_regression.sh 2>&1 | tail -10 || true"
lint: "ruff check core/metrics/outcome_backfill.py adapters/kyverno-json/policies/pilot-readiness/ adapters/kyverno-json/policies/settlement-finality/ 2>/dev/null || python3 -m py_compile core/metrics/outcome_backfill.py" lint: "ruff check .ciagent/STATE.md 2>/dev/null || true"
note: | note: |
v1.26 is the Live Pilot Estate Activation milestone a feat v1.27 is an NFR milestone (PO State Catalog & Ciagent Compression)
milestone. Four active personas: lead-developer (coordination + a docs/chore milestone. Single active persona: lead-developer owns
docs + ARCHITECTURE.md §12.8), backend-engineer (confidence_signal.py the milestone narrative (STATE.md authoring, PROJECT/ROADMAP fixes,
escalation reason + outcome_backfill.py + run_platform.sh wiring + archive moves, PLAN/NORTH_STAR wiring, final review + audit). No
env-JSON state_backend reconciliation), data-engineer (DynamoDB L1 code, no schema, no policy authoring. The pre-existing
primitive + metrics cold store outcome backfill), policy-engineer core/confidence_signal.py LSP diagnostic is out of scope (not
(kyverno-json pilot-readiness + settlement-finality policies), + touched by v1.27). Territory enforcement: warn.
blockchain-engineer (custom, phase-specific — chain core + order
engine + settlement). frontend-engineer is deactivated (no UI).
Territory enforcement: warn (the pilot is cross-territory by
nature — the consumer repo + the platform repo share the milestone).
--- ---
# PERSONAS — v1.26 Live Pilot Estate Activation # PERSONAS — v1.27 PO State Catalog & Ciagent Compression
> Generated by the lead-developer at the end of RESEARCH. Assesses the > Generated by the lead-developer at the end of RESEARCH. Assesses the
> project domains, activates/deactivates personas, creates custom > project domains, activates/deactivates personas, aligns frameworks +
> personas for domains beyond the default four, aligns frameworks +
> territory + constraints to the actual project structure. > territory + constraints to the actual project structure.
## Active Roster (5) ## Active Roster (1)
### 1. lead-developer (active) ### 1. lead-developer (active)
- **active:** true - **active:** true
- **phase_specific:** false - **phase_specific:** false
- **reason:** Coordinates task decomposition + resolves conflicts between - **reason:** Owns the full v1.27 milestone narrative: STATE.md
engineering personas. Owns the milestone narrative (PROJECT.md, authoring (PO-facing capability catalog, 36 entries across 10
ROADMAP.md, ARCHITECTURE.md §12.8). Final architectural decisions when domains + 11 invariants), archive moves (11 files to
personas disagree (e.g. where the outcome-backfill emitter lives). `.ciagent/archive/` + 1 to consumer archive), PROJECT.md + ROADMAP.md
- **domain:** project coordination, milestone narrative, cross-persona phase-status corrections, archive/README.md contents update,
conflict resolution. PLAN.md + ROADMAP.md + NORTH_STAR.md ship-discipline wiring, final
- **frameworks:** none (coordination role). review + audit.
- **territory:** `.ciagent/`, `docs/METRICS.md`, `adapters/README.md`, - **domain:** `.ciagent/` docs (STATE.md, PROJECT.md, ROADMAP.md,
`modules/README.md`, `modules/STANDARDS.md`. PLAN.md, NORTH_STAR.md, archive/README.md), consumer
- **constraints:** does not write Python/Terraform (delegates to `.ciagent/nova-blockchain-exchange/` (PROJECT.md pointer,
backend/data-engineer); does not author policies (delegates to archive/ROADMAP-v1.26.md).
policy-engineer); does not author chain code (delegates to - **frameworks:** markdown, JSON (CHECKPOINT.json, config.json).
blockchain-engineer). - **territory:** `.ciagent/`, `docs/`.
- **constraints:** no code changes (NFR milestone, D-220); no schema
changes; archive moves are lossless (byte-identical relocation, git
history preserves authoritative state); STATE.md is additive only.
### 2. backend-engineer (active) ## Deactivated (5)
- **active:** true
- **phase_specific:** false
- **reason:** Owns the platform-side Python changes: confidence signal
escalation reason (REQ-318), outcome-backfill emitter (REQ-317),
env-JSON state_backend wiring (REQ-319), adapter test updates for
DynamoDB (REQ-322), regression CAP-025 (REQ-316).
- **domain:** core Python (confidence_signal.py, metrics/, adapter.py,
regression_verify.py, contract_resolver.py), run_platform.sh wiring.
- **frameworks:** Python 3.12, pytest, boto3, SQLite, DynamoDB.
- **territory:** `core/confidence_signal.py`, `core/metrics/`,
`adapters/terraform/adapter.py`, `core/regression_verify.py`,
`core/environments/`, `scripts/run_platform.sh`, `tests/test_adapter.py`,
`tests/test_confidence_signal.py`, `tests/test_outcome_backfill.py`,
`tests/test_regression_pilot.py`.
- **constraints:** does not change `schemas/policy_check_result.schema.json`
(v1.25 moat, D-211); does not change `schemas/contract.schema.json`
(no schema breaks, D-213); does not author Terraform modules
(delegates to data-engineer for DynamoDB); does not author policies
(delegates to policy-engineer); does not author chain code (delegates
to blockchain-engineer).
### 3. data-engineer (active) ### backend-engineer (inactive)
- **active:** true - **active:** false
- **phase_specific:** false - **reason:** No code changes in v1.27. The pre-existing
- **reason:** Owns the DynamoDB L1 primitive (REQ-322) — the single `core/confidence_signal.py` LSP diagnostic is out of scope (not
platform-side module build-out. Owns the metrics cold store touched by v1.27).
outcome-backfill integration (REQ-317, the `fact_decision.outcome`
column + `backfilled_at` timestamp). Owns the env-JSON data updates
(REQ-319, `core/environments/*.json` account_id + state_backend.bucket).
- **domain:** Terraform modules (`modules/l1/`), schema definitions
(`interface.json`), registry (`modules/registry.json`), metrics cold
store (`metrics/nova_metrics.db`, `core/metrics/collector.py`).
- **frameworks:** Terraform, JSON, SQLite, DynamoDB, boto3.
- **territory:** `modules/l1/dynamodb/`, `modules/registry.json`,
`modules/README.md`, `core/environments/*.json`,
`core/metrics/collector.py`, `tests/test_adapter.py` (DynamoDB
emission test).
- **constraints:** does not change the adapter (stateless, v1.11);
follows the v1.8 NFR defaults (encryption + deletion protection +
PITR); follows the module standards (`modules/STANDARDS.md`).
### 4. policy-engineer (active, custom — added in v1.25) ### data-engineer (inactive)
- **active:** true - **active:** false
- **phase_specific:** false - **reason:** No schema, migration, or ORM changes.
- **reason:** Owns the kyverno-json policy authoring for the pilot:
settlement-finality (REQ-315), pilot-readiness (REQ-320). Extends
v1.25's policy engine to the securities domain.
- **domain:** declarative policies (kyverno-json ValidatingPolicy YAML),
JMESPath assertions, policy tests.
- **frameworks:** kyverno-json, JMESPath, JSON, pytest.
- **territory:** `adapters/kyverno-json/policies/pilot-readiness/`,
`adapters/kyverno-json/policies/settlement-finality/`,
`tests/test_settlement_finality_policy.py`,
`tests/test_pilot_readiness_policy.py`.
- **constraints:** policies are declarative (no imperative Python);
`is_configured()` guard skips gracefully when `kj` absent; follows
the v1.25 policy-authoring standard (`modules/STANDARDS.md` policy
section + `adapters/kyverno-json/README.md`).
### 5. blockchain-engineer (active, custom, phase-specific — added in v1.26) ### policy-engineer (inactive)
- **active:** true - **active:** false
- **phase_specific:** true (created for v1.26 P1; removed after P1 - **reason:** No policy authoring. STATE.md Domain 3 catalogues
unless the chain has ongoing work in P2..P4) existing v1.25 + v1.26 policies (descriptive, not authoring).
- **reason:** The pilot introduces a homegrown blockchain — a domain
beyond the default four personas. Owns the chain core (block, ledger,
validator, REQ-310), the order-matching engine (REQ-311), the
settlement service (REQ-312), and the consumer `contract.yaml`
(REQ-313) + deploy invocation (REQ-314).
- **domain:** blockchain consensus (PoA, single validator), order
matching (limit order book, price-time priority), settlement
(T+1, finality = block commit), consumer-repo deploy model.
- **frameworks:** Python 3.12 (the chain is Python, not Solidity/Go —
it's a homegrown ledger, not a smart-contract platform), pytest,
YAML (contract.yaml), GitHub Actions / Gitea Actions (deploy.yml
invocation).
- **territory:** `/root/nova-blockchain-exchange/` (the consumer repo:
`chain/`, `engine/`, `settlement/`, `contract.yaml`,
`contracts/*.yml`, `.github/workflows/deploy.yml`,
`.gitea/workflows/deploy.yml`, `tests/`).
- **constraints:** the chain is deterministic (same inputs → same block)
— it is automation, not AI (NORTH_STAR Objective #2 tenet); equities
only (D-200); single validator PoA (D-201); the consumer deploy MUST
go through `deploy.yml@v1.25` (no direct terraform apply); the
contract MUST validate against `schemas/contract.schema.json`.
## Deactivated (1)
### frontend-engineer (inactive) ### frontend-engineer (inactive)
- **active:** false - **active:** false
- **phase_specific:** false - **reason:** No UI. Deactivated since v1.26 (PERSONAS.md:141).
- **reason:** The pilot has no UI — the blockchain exchange is a
backend service (matching engine + settlement). The consumer repo
has no web/frontend. Reactivated if a future milestone adds a trading
dashboard.
## Phase-Specific Notes ### blockchain-engineer (inactive)
- **active:** false
- **blockchain-engineer** is created for v1.26 P1 (blockchain core + - **reason:** No chain code. The v1.26 pilot is shipped; v1.27 is
order engine + settlement). If P2..P4 have no chain changes, the platform-side docs/chore only.
persona is removed after P1 (the chain is a stable substrate for the
pilot run). If P2 (consumer-contract-and-deploy) requires chain
adjustments, the persona stays through P2.
- **policy-engineer** is active for P3 (pilot-metrics-and-policies) +
may consult on P4 (pilot run policy verification).
- **data-engineer** is active for P3 (DynamoDB primitive + outcome
backfill + env-JSON) + P4 (regression CAP-025 may touch the registry).
## Territory Enforcement ## Territory Enforcement
- **Mode:** `warn` (the pilot is cross-territory by nature — the - **Mode:** `warn` (the milestone is `.ciagent/`-only; the lead-
consumer repo + the platform repo share the milestone; the developer owns all writes; no cross-territory collisions expected).
blockchain-engineer works in the consumer repo, backend/data/policy
engineers work in the platform repo).
- **Cross-territory collisions:** REQ-322 (DynamoDB primitive) is
data-engineer territory, but the adapter test update
(`tests/test_adapter.py` `EXPECTED_L1_KEYS`) is backend-engineer
territory. The lead-developer resolves: data-engineer authors the
module + registry; backend-engineer updates the test assertion
(the test is backend territory, the module is data territory).
+203 -462
View File
@@ -1,510 +1,251 @@
# PLAN — v1.26 (Live Pilot Estate Activation) # PLAN — v1.27 PO State Catalog & Ciagent Compression
> Feature milestone. Tags on the **v1.25.x** line: v1.25.0 (P0) → > **Milestone:** v1.27 (NFR — docs/chore only). Tags on the **v1.26.x**
> v1.25.1 (P1) → v1.25.2 (P2) → v1.25.3 (P3) → v1.25.4 (P4) → v1.25.5 > line: `v1.26.0` (P0) → `v1.26.1..v1.26.3` (P1..P3). The final phase's
> (P5 final = milestone release). 13 requirements (REQ-310..322), > patch (`v1.26.3`) IS the milestone release.
> 5 phases (P0 pre-execution + 4 execution + 1 final). Multi-project: > **Branch:** `milestone/v1.27-po-state-catalog`. Phase branches:
> `acdl` (platform) + `nova-blockchain-exchange` (consumer). Tags run > `phase/00-pre-execution`, `phase/01-author-archive`,
> on the previous minor's patch line per `run.md` versioning logic > `phase/02-fix-stale-wire`, `phase/03-final-review-ship`.
> (feature milestone — at least one feat phase; progressive patches per
> phase; the final phase's patch IS the milestone release; no separate
> minor tag).
--- ## Milestone goal
## Phase 0 — Pre-Execution (complete, tag v1.25.0) Author `.ciagent/STATE.md` (PO-facing capability catalog, backfilled
through v1.26) + compress `.ciagent/` by archiving 11 outdated files +
fix 3 stale-but-kept files + wire STATE.md into the P-final ship
discipline. NFR milestone — no code, no schema, no platform behavior
change.
SPECIFY → CLARIFY → RESEARCH → IDEATE → PLAN → GRILL. All `.ciagent/` ## Requirements
MD, research, plans. Ships as `v1.25.0` on the v1.25.x line.
**Pre-run (Workstream A, on main before branch gate):** No new REQ-NNN. v1.27 is a docs/chore milestone; the work items are
- A1: flaky test fix (commit `8c68d68`, pushed). the user-approved plan from the prior conversation. The traceability
- A2: ACDL_*→NOVA_* bootstrap migration (commit `f844fea`, pushed). is by-file (the "requirements" are the 15 file operations + 6 doc
- A3: AWS bootstrap — S3 state bucket + DynamoDB outbox created. edits in the plan summary).
- A4: `nova-blockchain-exchange` Gitea repo created + cloned.
**Phase 0 stages (on `phase/00-specify-clarify-research-plan`):** ## Phase breakdown
- SPECIFY: v1.26 established in config.json + PROJECT.md + ROADMAP.md +
`.ciagent/nova-blockchain-exchange/{PROJECT,REQUIREMENTS,ROADMAP}.md`.
- CLARIFY: 10 ambiguities resolved (D-200..D-213).
- RESEARCH: PoA blockchain, deploy model, DynamoDB gap (REQ-322),
metric grounding, persona assessment (5 personas).
- IDEATE: 7 ideas accepted (I1..I7 → REQ-315..322), 3 deferred.
- PLAN: this file.
- GRILL: adversarial review (binding verdicts).
--- ### Phase P1 — author-archive (additive + lossless)
## Phase 1 — blockchain-core (tag v1.25.1) **Goal:** Author STATE.md (already done in P0 SPECIFY, refined here)
+ archive 11 outdated files. Pure-additive + lossless moves only —
no edits to kept files.
**Goal:** The consumer repo has a working homegrown PoA blockchain + #### Wave 1 — verify STATE.md backfill
order-matching engine + settlement service. All unit tests pass in the - **Task 1.1** (lead-developer): verify STATE.md 36 capability rows
consumer repo's own CI. against the authoritative sources (regression_verify.py CAP-NNN list,
modules/registry.json, REQUIREMENTS.md traceability, CHECKPOINT
tags). Fix any inaccurate citation (shipped tag, file path).
**Project:** `nova-blockchain-exchange` (consumer repo). #### Wave 2 — archive platform-root files (10)
**Branch:** `nova-blockchain-exchange/phase/01-blockchain-core`. - **Task 2.1** (lead-developer): `git mv` 10 files to
**Persona:** blockchain-engineer (primary), lead-developer (coordination). `.ciagent/archive/` with milestone-suffix names:
- `CAPABILITY_INVENTORY.md``CAPABILITY_INVENTORY-v1.10.md`
- `CLARIFY.md``CLARIFY-v1.26.md`
- `GRILL.md``GRILL-v1.26.md`
- `IDEATE.md``IDEATE-v1.26.md`
- `RESEARCH.md``RESEARCH-v1.26.md`
- `REVIEW-AUDIT-P05.md``REVIEW-AUDIT-P05.md`
- `VERIFY-P03.md``VERIFY-P03.md`
- `VERIFY-P04.md``VERIFY-P04.md`
- `P4-PILOT-RUN-EVIDENCE.md``P4-PILOT-RUN-EVIDENCE-v1.26.md`
- `AUTONOMY_THESIS.md``AUTONOMY_THESIS-v1.21.md`
- `COST.md``COST-v1.14.md`
Use `git mv` to preserve history. NOTE: CLARIFY/GRILL/IDEATE/RESEARCH
were rewritten in P0 with v1.27 content — archive the v1.27 versions
(they document the v1.27 pre-execution; the next P0 writes fresh).
Wait — per D-219, the v1.26 pre-execution artifacts are archived. The
v1.27 versions replace them in active context; they are NOT archived
at P1 (they are the current P0 artifacts, active until v1.27 ships,
then archived at v1.28 P1 if v1.28 happens). **Correction:** archive
only the v1.26-era pre-execution artifacts. But P0 already
overwrote CLARIFY/GRILL/IDEATE/RESEARCH with v1.27 content. The v1.26
content lives in git history (the pre-P0 commits). So:
- The 4 pre-execution files (CLARIFY/GRILL/IDEATE/RESEARCH) at HEAD
are the v1.27 P0 artifacts — **keep active** through v1.27, archive
at v1.28.
- The v1.26-era content is in git history — reachable.
**Revised archive list (7 files, not 10):** CAPABILITY_INVENTORY,
REVIEW-AUDIT-P05, VERIFY-P03, VERIFY-P04, P4-PILOT-RUN-EVIDENCE,
AUTONOMY_THESIS, COST.
### Wave 1 — chain core (REQ-310) Hold — let me re-check D-219. The user said "Archive all 4
- **Task 1.1** (blockchain-engineer): `chain/block.py` — Block dataclass pre-execution artifacts." That was decided *before* P0 overwrote
(index, timestamp, prev_hash, transactions, nonce, hash). them. The intent was to archive the v1.26 pre-execution record. The
`compute_hash()` deterministic (SHA-256). Unit test: `test_block.py`. v1.27 P0 overwrites are the new pre-execution record. Archiving the
- **Task 1.2** (blockchain-engineer): `chain/ledger.py` — Ledger class: v1.27 versions at v1.27 P1 would lose the v1.27 pre-execution
`append_block()`, `verify_chain()`, `get_block(index)`, narrative. **Resolution:** archive the v1.26-era content (preserved
`get_latest_block()`. Genesis block on init. Unit test: `test_ledger.py`. in git history at the pre-P0 commits) by noting it in the archive
- **Task 1.3** (blockchain-engineer): `chain/validator.py` — PoA README; keep the v1.27 P0 versions active through v1.27. The 4 files
validator: single validator (config-driven), `propose_block(transactions)` stay active until v1.28 P1.
→ Block, `commit_block(block)`. Unit test: `test_validator.py`.
### Wave 2 — order engine + settlement (REQ-311, REQ-312) — parallel with Wave 1 tail **Final archive list (7 files):** CAPABILITY_INVENTORY.md,
- **Task 2.1** (blockchain-engineer): `engine/order.py` — Order REVIEW-AUDIT-P05.md, VERIFY-P03.md, VERIFY-P04.md,
dataclass (id, side, symbol, price, size, timestamp). P4-PILOT-RUN-EVIDENCE.md, AUTONOMY_THESIS.md, COST.md.
- **Task 2.2** (blockchain-engineer): `engine/order_book.py`
OrderBook: `add_order(order)`, `match_orders()` → list of Match
(price-time priority, partial fills). Unit test: `test_order_book.py`.
- **Task 2.3** (blockchain-engineer): `settlement/service.py`
SettlementService: `settle(match)` → SettlementTransaction,
`submit(ledger)`. Idempotent (re-settling a match is a no-op once
final). Finality = block commit. Unit test: `test_settlement.py`.
### Wave 3 — consumer CI (cross-cutting) - **Task 2.2** (lead-developer): grep for dangling references to the
- **Task 3.1** (blockchain-engineer): `.github/workflows/ci.yml` + archived filenames across `.ciagent/` + `docs/`; fix any in P2 (the
`.gitea/workflows/ci.yml` — lint + pytest on chain/engine/settlement. fix-stale phase).
- **Task 3.2** (lead-developer): `nova-blockchain-exchange/README.md`
repo overview + dev setup. #### Wave 3 — archive consumer file (1)
- **Task 3.1** (lead-developer): `mkdir
.ciagent/nova-blockchain-exchange/archive/` + `git mv
nova-blockchain-exchange/ROADMAP.md` →
`nova-blockchain-exchange/archive/ROADMAP-v1.26.md` (D-221).
#### Wave 4 — commit P1
- **Task 4.1** (lead-developer): single commit `chore(P01): archive 7
platform + 1 consumer outdated .ciagent files` with `---ci---`
block.
**Must-haves (verify before ship):** **Must-haves (verify before ship):**
- `pytest tests/` in the consumer repo passes (chain integrity, hash - STATE.md 36 rows accurate (Wave 1 verification).
determinism, genesis, append/verify, match priority, partial fills, - 7 platform files present in `.ciagent/archive/` with milestone
settlement idempotency, finality check). suffixes; originals gone from `.ciagent/` root.
- The chain is deterministic (replay produces the same hash chain). - 1 consumer file present in
- The consumer CI workflow runs on push. `.ciagent/nova-blockchain-exchange/archive/`; original gone.
- 0 dangling references in active files (checked in P2, but flagged
here).
**Ship:** tag `v1.25.1`, merge `phase/01``milestone/v1.26-pilot-activation`, ### Phase P2 — fix-stale-wire (corrections + wiring)
Gitea release (best-effort). Delete `phase/01`.
--- **Goal:** Fix 3 stale-but-kept files + wire STATE.md into the P-final
ship discipline + add a pointer in the consumer PROJECT.md.
## Phase 2consumer-contract-and-deploy (tag v1.25.2) #### Wave 1fix PROJECT.md phase-status
- **Task 1.1** (lead-developer): `.ciagent/PROJECT.md` lines 424431 —
the v1.26 phase-status block. Mark P3/P4/P5 complete with shipped
tags (`v1.25.3`, `v1.25.4`, `v1.25.5`); mark v1.26 milestone shipped.
- **Task 1.2** (lead-developer): add a one-line pointer to STATE.md in
the "Capability Status" section header (line 130): "The PO-facing
capability catalog is `.ciagent/STATE.md` (additive; updated at
milestone ship). CAP-NNN IDs cross-reference the regression gate at
`core/regression_verify.py`."
**Goal:** The consumer repo declares its infrastructure via #### Wave 2 — fix ROADMAP.md phase-status
`contract.yaml` (validated against the platform's schema) + invokes the - **Task 2.1** (lead-developer): `.ciagent/ROADMAP.md` v1.26 section —
platform's `deploy.yml@v1.25` workflow. The contract references the mark P3/P4/P5 complete with shipped tags; mark the v1.26 Overview
`microservice` (ECS), `dynamodb`, + `s3` modules. line (line 181) "(active, ...)" → "(complete, tag `v1.25.5`)".
- **Task 2.2** (lead-developer): add STATE.md to the v1.25 + v1.26 P5
phase-detail "Updated at ship" list (the convention visibility
point).
**Project:** `nova-blockchain-exchange` (consumer repo) + `acdl` #### Wave 3 — wire STATE.md into ship discipline
(platform repo — for the `deploy.yml@v1.25` ref + the `v1.25` floating - **Task 3.1** (lead-developer): `.ciagent/PLAN.md` P5 Wave 3 Task 3.5
tag). — add STATE.md to the file-update list: "append new capability
**Branch:** `nova-blockchain-exchange/phase/02-contract-and-deploy`. entries to `.ciagent/STATE.md`; mark any deprecated capability."
**Persona:** blockchain-engineer (contract authoring), data-engineer - **Task 3.2** (lead-developer): `.ciagent/NORTH_STAR.md` — add a
(registry/DynamoDB dependency check), lead-developer (deploy.yml ref). one-line note in "Relationship to engineering files" (or the v1.25
update section): "STATE.md is the *what exists* catalog (PO-owned,
additive, updated at milestone ship); this file is the *why*."
### Wave 1contract (REQ-313) #### Wave 4fix archive README + consumer PROJECT pointer
- **Task 1.1** (blockchain-engineer): `contract.yaml`id - **Task 4.1** (lead-developer): `.ciagent/archive/README.md`add
(`blkex`), name (`blockchain-exchange`), environment (dev), the 8 new archived files (7 platform + 1 consumer) to the contents
infrastructure block (microservice + dynamodb + s3). tables (Snapshots + Completed-phase artifacts sections).
- **Task 1.2** (blockchain-engineer): `contracts/blockchain-exchange.dev.yml`, - **Task 4.2** (lead-developer):
`.qa.yml`, `.prod.yml` — per-env variants. `.ciagent/nova-blockchain-exchange/PROJECT.md` — add a one-line
- **Task 1.3** (blockchain-engineer): `tests/test_contract_validates.py` pointer to the platform ROADMAP for milestone-phase history (since
— schema validation against the platform's the consumer ROADMAP is archived): "Phase-by-phase history:
`schemas/contract.schema.json`. `.ciagent/ROADMAP.md` §v1.26 (the consumer ROADMAP is archived at
`.ciagent/nova-blockchain-exchange/archive/ROADMAP-v1.26.md`)."
### Wave 2deploy invocation (REQ-314) #### Wave 5fix any dangling references from P1 Wave 2
- **Task 2.1** (blockchain-engineer): `.github/workflows/deploy.yml` - **Task 5.1** (lead-developer): apply fixes for any dangling
`uses: acdl/.github/workflows/deploy.yml@v1.25` with references found in P1 Wave 2.
`with: { contract: contract.yaml, mode: full, environment: dev }`.
- **Task 2.2** (blockchain-engineer): `.gitea/workflows/deploy.yml`
byte-identical mirror.
- **Task 2.3** (blockchain-engineer): `tests/test_deploy_workflow_invocation.py`
— asserts the `uses:` ref + inputs.
### Wave 3platform floating tag (cross-cutting) #### Wave 6commit P2
- **Task 3.1** (lead-developer, on `acdl` repo): verify the `v1.25` - **Task 6.1** (lead-developer): single commit `docs(P02): fix stale
floating tag exists (created by `release.yml` on merge to main). If phase-status + wire STATE.md into ship discipline` with `---ci---`
not, create it pointing at the `v1.25.0` tag (Phase 0 ship). block.
**Must-haves (verify before ship):** **Must-haves (verify before ship):**
- `contract.yaml` validates against `schemas/contract.schema.json`. - PROJECT.md v1.26 phase-status matches CHECKPOINT.json (P3/P4/P5
- The deploy workflow invocation asserts the correct `uses:` ref + complete, v1.26 shipped).
inputs. - ROADMAP.md v1.26 sections show P3/P4/P5 complete + Overview complete.
- The `v1.25` floating tag resolves. - PLAN.md P5 Wave 3 names STATE.md.
- NORTH_STAR.md notes STATE.md.
- archive/README.md lists the 8 new archived files.
- nova-blockchain-exchange/PROJECT.md points to platform ROADMAP.
**Ship:** tag `v1.25.2`, merge `phase/02` → milestone, Gitea release. ### Phase P3 — final-review-ship (review + audit + milestone ship)
Delete `phase/02`.
--- **Goal:** Final review + audit + milestone ship.
## Phase 3pilot-metrics-and-policies (tag v1.25.3) #### Wave 1review
- **Task 1.1** (lead-developer): review all P1/P2 changes for
correctness (no broken markdown, no inaccurate citations, no
dangling references).
- **Task 1.2** (lead-developer): fix any P0 issues in this phase.
**Goal:** The platform repo gains the metric-grounding emitters, the #### Wave 2 — audit
kyverno-json pilot policies, the DynamoDB L1 primitive, the env-JSON - **Task 2.1** (lead-developer): reconstruction test — git log
wiring reconciliation, + the pilot regression CAP. The Post-Pilot `---ci---` blocks ↔ `.ciagent/` files consistent; phase
metrics are grounded (outcome backfill + escalation reason); the pilot- progression P0→P1→P2→P3.
readiness + settlement-finality policies are in place. - **Task 2.2** (lead-developer): `.ciagent/` file discipline —
CHECKPOINT consistent with HEAD; PROJECT/ROADMAP phase-status
consistent with CHECKPOINT; STATE.md present + 36 rows; archive
contents match the moves.
- **Task 2.3** (lead-developer): branch hygiene — only main +
milestone + P3; P1/P2 deleted.
- **Task 2.4** (lead-developer): commit discipline — all v1.27 commits
carry `---ci---` blocks.
**Project:** `acdl` (platform repo) + `nova-blockchain-exchange` #### Wave 3 — milestone ship
(consumer repo — the Gitea adapter rewrites the consumer's `deploy.yml`). - **Task 3.1** (lead-developer): merge `phase/03` →
**Branch:** `acdl/phase/03-pilot-metrics-and-policies` (platform branch). `milestone/v1.27-po-state-catalog` → `main`.
**Personas:** backend-engineer (emitters + adapter + regression), - **Task 3.2** (lead-developer): tag `v1.26.3` (= the v1.27 release per
data-engineer (DynamoDB primitive + env JSON + collector), prev-minor tagging rule; v1.27 is an NFR milestone, tags on v1.26.x).
policy-engineer (kyverno-json policies), lead-developer (Gitea adapter - **Task 3.3** (lead-developer): create Gitea release with full
+ deploy.yml drift + rotation workflow). milestone summary.
- **Task 3.4** (lead-developer): delete all milestone branches (local
### Wave 0 — Gitea reusable-workflow adapter (SPEC §10 Q1, resolved by evidence) — lead-developer + blockchain-engineer + remote). Tags preserve all history.
> **Highest-priority gap.** The v0.2 P3 `workflow_dispatch` (Gitea - **Task 3.5** (lead-developer): update `.ciagent/REQUIREMENTS.md`
> Actions run id=6199) failed: Gitea Actions rejects cross-repo `uses:` (no REQs to mark — NFR milestone), `.ciagent/ROADMAP.md` (mark
> (`acdl/.github/workflows/deploy.yml@v1.25`) with `expected format v1.27 complete), `.ciagent/NORTH_STAR.md` (no strategic change),
> {owner}/{repo}/.{git_platform}/workflows/{filename}@{ref}`. The `.ciagent/STATE.md` (bump "Last milestone ship" to v1.27).
> consumer's `deploy.yml` is frozen at the v0.1 byte-identical mirror;
> the platform adapts (option c — inline checkout-then-call), not
> vice-versa.
- **Task 0.1** (lead-developer): rewrite
`nova-blockchain-exchange/.gitea/workflows/deploy.yml` + byte-identical
`.github/workflows/deploy.yml` — drop the `uses:` indirection; single
`deploy` job on `ubuntu-latest` that `actions/checkout@v4` the consumer,
`actions/checkout@v4` `acdl/acdl` @ `ref: v1.25` into `platform/`,
setup-python 3.12, install deps (jsonschema/pyyaml/boto3 + checkov),
install Terraform 1.9.*, configure AWS (static-key path:
`aws-region: ${{ secrets.AWS_DEFAULT_REGION }}`, `access-key-id` +
`secret-access-key` from `NOVA_AWS_*` secrets; no OIDC token minted),
run `bash platform/scripts/run_platform.sh $MODE_FLAG $ENV_FLAG
contract.yaml`. Preserve `on: workflow_dispatch` inputs (mode choice
default full; environment choice default "") + `permissions: {id-token:
write, contents: read}` + `secrets: inherit`.
- **Task 0.2** (blockchain-engineer): update
`nova-blockchain-exchange/tests/test_deploy_workflow_invocation.py` +
`test_deploy_gitea_invocation.py` — assert no cross-repo `uses:`,
assert `ref: v1.25`, assert `secrets: inherit`, assert
`run_platform.sh` invoked, assert `AWS_DEFAULT_REGION` wired.
- **Task 0.3** (lead-developer): `acdl/.github/workflows/deploy.yml`
stays as the GitHub Actions reference impl (the `workflow_call`
reusable workflow — used by GitHub-hosted consumers); document in
`adapters/README.md` that Gitea consumers use the inline adapter, not
the reusable `uses:`.
### Wave 0.5 — kyverno-json substrate fix (v1.25 skip-masked bug) — backend-engineer
> The v1.25 kyverno-json engine + policies were never validated
> against the real `kj` binary (tests `pytest.skip("kj not installed")`
> when absent). With `kj` now installed (v0.0.3), 3 policy tests
> failed. Root cause: (a) `kj` v0.0.3 does not load `.json` policy
> files (only `.yaml`/`.yml`) — the engine now materializes `.yaml`
> twins at runtime; (b) the `validate` wrapper is not supported —
> `assert` goes directly under the rule; (c) the check syntax was
> inverted (`expression: expected_value`, not `key: expression`);
> (d) the engine `_translate` expected `{"results": [...]}` but `kj`
> returns a bare list with `results[].policy.metadata.name` +
> `results[].rules[].violations[]`. DONE (committed 59d837f). Also
> fixed `scripts/install-kyverno-json.sh` (the `cmd/kj@latest` path
> fails — the real binary is `kyverno-json`, symlinked as `kj`).
- **Task 0.5.1** (backend-engineer): rewrite
`adapters/kyverno-json/kyverno_json_engine.py` `_translate` for the
bare-list output format + add `_materialize_yaml_policy_dir` (DONE).
- **Task 0.5.2** (backend-engineer): remove the `validate` wrapper +
fix check syntax across all 16 existing policies (DONE).
- **Task 0.5.3** (backend-engineer): fix
`scripts/install-kyverno-json.sh` (DONE).
- **Task 0.5.4** (backend-engineer): resolve pre-existing P2 drift
uncovered by the full-suite run — dynamodb `examples/simple.yml` +
`complex.yml`, `sync_workflows` re-sync, CAP-024 deck path
(`nova-autonomous-cloud-delivery-marp.md`) + slide-count bound +
`class="benefit"` div count (DONE, committed 3735330).
### Wave 1 — DynamoDB primitive (REQ-322) — data-engineer — verify-only (done in P2 W0)
- **Task 1.1** (data-engineer): verify `modules/l1/dynamodb/` resolves
+ emits valid Terraform via `tests/test_adapter.py` (the primitive
shipped in P2 W0; this wave is a re-verify, not re-authoring).
### Wave 2 — metric grounding (REQ-317, REQ-318) — backend-engineer + data-engineer — parallel
- **Task 2.1** (backend-engineer): `core/metrics/outcome_backfill.py`
`backfill(decision_id, outcome)` updates `fact_decision.outcome` +
`backfilled_at`. Reads run-manifest events.
- **Task 2.2** (backend-engineer): `core/metrics/collector.py`
invokes backfill after run completion.
- **Task 2.3** (backend-engineer): `tests/test_outcome_backfill.py`.
- **Task 2.4** (backend-engineer): `core/confidence_signal.py`
`ai.decision.made` gains `escalation_reason: 'confidence'` when
`band == 'block'`.
- **Task 2.5** (backend-engineer): `core/metrics/collector.py`
persists `escalation_reason` into `fact_run`.
- **Task 2.6** (backend-engineer): `tests/test_confidence_escalation_reason.py`.
### Wave 3 — env-JSON wiring + adapter (REQ-319) — backend-engineer + data-engineer — parallel
- **Task 3.1** (backend-engineer): `adapters/terraform/adapter.py`
reads `env.state_backend.bucket` when present (fallback to computed
name for backwards compat).
- **Task 3.2** (data-engineer): `core/environments/dev.json`
`account_id``581513795199`, `state_backend.bucket`
`nova-tfstate-581513795199-us-east-1`.
- **Task 3.3** (data-engineer): `core/environments/{qa,prod,dr}.json`
`state_backend.bucket` updated; `account_id` stays placeholder
(pilot-readiness policy blocks apply on placeholder, D-208).
- **Task 3.4** (backend-engineer): `tests/test_adapter_state_backend.py`.
- **Task 3.5** (backend-engineer): `tests/test_adapter.py` — add
`dynamodb` to `EXPECTED_L1_KEYS` + a resolution + emission test
(cross-territory: data-engineer authored the module, backend-engineer
owns the test).
### Wave 4 — kyverno-json policies (REQ-315, REQ-320) — policy-engineer — parallel
- **Task 4.1** (policy-engineer):
`adapters/kyverno-json/policies/settlement-finality/all-matches-committed.json`
— kyverno-json policy over settlement-service status JSON (asserts
`all_committed: true`). **Note (G-Q6):** the policy is authored +
tested in v1.26; *enforcement* is deferred to the milestone that
binds qa/prod/dr (D-208 — the policy gates promotions, not dev
applies).
- **Task 4.2** (policy-engineer):
`adapters/kyverno-json/policies/pilot-readiness/no-placeholder-account.json`
— kyverno-json policy over env JSON (asserts
`account_id != "000000000000"`).
- **Task 4.3** (policy-engineer): `tests/test_settlement_finality_policy.py`
— passing + failing fixtures; **runs against real `kj`** (not skipped
`kj` is installed via `scripts/install-kyverno-json.sh`).
- **Task 4.4** (policy-engineer): `tests/test_pilot_readiness_policy.py`
— passing (real account) + failing (placeholder) fixtures; **runs
against real `kj`** (not skipped).
### Wave 5 — regression CAP (REQ-316) — backend-engineer
- **Task 5.1** (backend-engineer): `core/regression_verify.py`
CAP-025 (live-pilot-apply): the round-trip assertion.
- **Task 5.2** (backend-engineer): `tests/test_regression_pilot.py`.
### Wave 6 — deploy.yml drift fixes (SPEC §5.1/§5.2) — lead-developer + backend-engineer
> The platform reference `workflows-src/deploy.yml` (synced to
> `.github`+`.gitea`) has three drifts vs the SPEC: (a) `aws-region`
> hardcoded `us-east-1` (SPEC wants `NOVA_AWS_REGION`/`AWS_DEFAULT_REGION`
> from secret); (b) platform checkout `ref: v1.9` (SPEC wants `v1.25`);
> (c) the local `scripts/run_platform.sh` fallback exports raw
> `NOVA_AWS_*` names into shell env (SPEC §5.2 constraint: consume as
> workflow secrets, not shell env — `blocked_env_vars`).
- **Task 6.1** (lead-developer): `workflows-src/deploy.yml`
`aws-region: ${{ secrets.AWS_DEFAULT_REGION || 'us-east-1' }}`;
platform checkout `ref: v1.25`; re-sync to `.github`+`.gitea`.
- **Task 6.2** (backend-engineer): `scripts/run_platform.sh` — source
`AWS_DEFAULT_REGION` from `.env.secrets` for the local fallback (not
raw `NOVA_AWS_*`); the CI path already consumes secrets via the
`configure-aws-credentials` action.
- **Task 6.3** (backend-engineer): `tests/test_deploy_workflow_env_input.py`
— assert `AWS_DEFAULT_REGION` wired + `ref: v1.25` + no raw
`NOVA_AWS_*` in shell env.
### Wave 7 — secret rotation scheduled workflow (SPEC §5.9) — lead-developer
> SPEC §5.9: "the rotation mechanism must *exist* (not have run)."
> A platform-managed scheduled workflow wraps the existing
> `scripts/rotate_spike_key.sh` (manual today) on a daily cron.
- **Task 7.1** (lead-developer): `workflows-src/rotate-aws-key.yml`
`on: { schedule: [{cron: "0 0 * * *"}], workflow_dispatch:}`,
single job that checks out the platform repo + runs
`bash scripts/rotate_spike_key.sh` with `NOVA_AWS_*` bootstrap
secrets; sync to `.github`+`.gitea`.
- **Task 7.2** (lead-developer): verify `scripts/rotate_spike_key.sh`
is idempotent (deactivates old key only after the new key propagates
to the Gitea Actions secret store).
- **Task 7.3** (lead-developer): `tests/test_rotate_key_workflow.py`
structural test (the workflow file declares `schedule` + invokes
`rotate_spike_key.sh`); document in `.ciagent/ARCHITECTURE.md` §12.8
that the mechanism exists (v0.2 scope: exists-not-ran per SPEC §5.9).
**Must-haves (verify before ship):**
- `pytest tests/` in the platform repo passes (the 170 baseline held
inaccurately — the real P2 baseline had 7 pre-existing failures
uncovered by W0.5; all now fixed). Full suite green.
- `pytest tests/` in the consumer repo passes (deploy invocation tests
updated for the inline adapter).
- The kyverno-json substrate works against real `kj` (W0.5 — DONE).
- The Gitea adapter: consumer `deploy.yml` has no cross-repo `uses:`;
inline checkout `acdl@v1.25` + `run_platform.sh` (W0).
- The DynamoDB primitive resolves + emits valid Terraform (W1 verify).
- The outcome backfill updates `fact_decision.outcome` (not `pending`)
(W2).
- The `escalation_reason` field is emitted on `block` band (W2).
- The adapter reads `env.state_backend.bucket` from the env JSON (W3).
- The 2 new kyverno-json policies pass on valid fixtures + fail on
invalid fixtures, against real `kj` (W4 — not skipped).
- CAP-025 is in the regression gate (W5).
- The deploy.yml drifts fixed: `AWS_DEFAULT_REGION` wired, `ref:
v1.25`, no raw `NOVA_AWS_*` in shell env (W6).
- The rotation scheduled workflow exists (W7).
**Ship:** tag `v1.25.3`, merge `phase/03` → milestone, Gitea release.
Delete `phase/03`.
---
## Phase 4 — pilot-run-and-docs (tag v1.25.4)
**Goal:** The pilot estate runs end-to-end against live AWS
`581513795199` (contract resolve → adapter compile → terraform plan →
policy scan → confidence signal → attestation → outbox record). Docs +
adapter README + onboarding guide are complete.
**Project:** `nova-blockchain-exchange` (consumer repo — the run) +
`acdl` (platform repo — docs).
**Branch:** `acdl/phase/04-pilot-run-and-docs` (platform branch for
docs); the run happens via the consumer's `deploy.yml` invocation.
**Personas:** blockchain-engineer (the run), lead-developer (docs),
backend-engineer (regression CAP-025 verification).
### Wave 1 — the pilot run (REQ-316 verification, live)
- **Task 1.1** (blockchain-engineer): trigger the consumer's
`deploy.yml` with `mode: full, environment: dev` against
`581513795199`. The workflow checks out the consumer + platform
repos, runs `run_platform.sh`, applies the contract (ECS +
DynamoDB + S3), records the decision + attestation.
- **Task 1.2** (backend-engineer): verify CAP-025 (regression gate)
passes against the live run.
- **Task 1.3** (blockchain-engineer): capture the run's
`ai.decision.made` + `attestation.recorded` events from the Decision
Ledger → evidence for the milestone ship.
### Wave 2 — docs (REQ-321)
- **Task 2.1** (lead-developer): `adapters/README.md` — new consumer
row + fix the stale `TYPE_MAP` references (IDEATE I8).
- **Task 2.2** (lead-developer): `docs/METRICS.md` — Post-Pilot metrics
grounded note (the 3 targets now have non-zero denominators post-run).
- **Task 2.3** (lead-developer): `.ciagent/ARCHITECTURE.md` §12.8
(Pilot Estate).
- **Task 2.4** (lead-developer):
`.ciagent/nova-blockchain-exchange/README.md` — consumer onboarding
guide (how to invoke `deploy.yml@v1.25`, what secrets to set, what
the contract shape is).
**Must-haves (verify before ship):**
- The pilot run completes end-to-end (apply succeeds, decision recorded,
attestation recorded for dev — autonomous, no human approver).
- CAP-025 passes.
- The 3 Post-Pilot metrics have non-zero denominators (the run
contributed to `fact_run` + `fact_decision`).
- Docs are complete (adapter README, METRICS.md, ARCHITECTURE.md §12.8,
consumer onboarding guide).
**Ship:** tag `v1.25.4`, merge `phase/04` → milestone, Gitea release.
Delete `phase/04`.
---
## Phase 5 — final review + audit + milestone ship (tag v1.25.5)
**Goal:** Multi-persona code review across P1..P4. Audit (reconstruction
test, branch hygiene, commit discipline). Milestone ship: merge to main,
tag `v1.25.5` (= the v1.26 release), Gitea release with full milestone
summary, delete all milestone branches.
**Project:** both (`acdl` + `nova-blockchain-exchange`).
**Branch:** `phase/05-final-review-ship`.
**Personas:** lead-developer (review + audit + ship), backend-engineer
(review), data-engineer (review), policy-engineer (review),
blockchain-engineer (review — the chain core is reviewed).
### Wave 1 — review
- **Task 1.1** (lead-developer): `ciagent-review` — multi-persona code
review across P1..P4. Auto-fix P0; flag P1+ for post-hoc review.
- **Task 1.2** (all personas): fix P0 issues in this phase.
### Wave 2 — audit
- **Task 2.1** (lead-developer): `ciagent-audit` — reconstruction test
(git log ↔ `.ciagent/`), branch hygiene, commit discipline.
- **Task 2.2** (lead-developer): fix critical audit issues in this phase.
### Wave 3 — milestone ship
- **Task 3.1** (lead-developer): merge `phase/05` →
`milestone/v1.26-pilot-activation` → `main`.
- **Task 3.2** (lead-developer): tag `v1.25.5` (= the v1.26 release per
prev-minor tagging rule).
- **Task 3.3** (lead-developer): create Gitea release with full milestone
summary (all phases, all 13 requirements).
- **Task 3.4** (lead-developer): delete all milestone branches (local +
remote). Tags preserve all history.
- **Task 3.5** (lead-developer): update `.ciagent/nova-blockchain-exchange/REQUIREMENTS.md`
(mark REQ-310..322 complete), `.ciagent/ROADMAP.md` (mark v1.26
complete), `.ciagent/NORTH_STAR.md` (note Strategic Objectives #1 +
#3 — first real consumer estate; Post-Pilot denominators activated).
- **Task 3.6** (lead-developer): write checkpoint `stage: complete, - **Task 3.6** (lead-developer): write checkpoint `stage: complete,
phase: 5, phase_role: final` + clear checkpoint (milestone complete). phase: 3, phase_role: final` + clear checkpoint (milestone
complete).
**Must-haves (verify before ship):** **Must-haves (verify before ship):**
- Review: 0 P0 issues unfixed; P1+ flagged for post-hoc. - Review: 0 P0 issues unfixed; P1+ flagged for post-hoc.
- Audit: reconstruction test passes; branch hygiene clean; commit - Audit: reconstruction PASS; file discipline CLEAN; branch hygiene
discipline clean. CLEAN; commit discipline CLEAN.
- Ship: `v1.25.5` tag exists; Gitea release created; milestone branches - Ship: `v1.26.3` tag exists; Gitea release created; milestone
deleted; main has the milestone merge. branches deleted; main has the milestone merge.
--- ---
## Requirement → Phase Mapping ## Requirement → Phase Mapping
| REQ | Phase | Wave | Persona | No REQ-NNN (NFR milestone). The work items are file operations,
|---|---|---|---| traced by the Wave tasks above.
| REQ-310 (blockchain core) | P1 | W1 | blockchain-engineer |
| REQ-311 (order engine) | P1 | W2 | blockchain-engineer |
| REQ-312 (settlement) | P1 | W2 | blockchain-engineer |
| REQ-313 (contract.yaml) | P2 | W1 | blockchain-engineer |
| REQ-314 (deploy invocation) | P2 | W2 | blockchain-engineer |
| REQ-315 (settlement-finality policy) | P3 | W4 | policy-engineer |
| REQ-316 (pilot regression CAP) | P3 | W5 + P4 W1 | backend-engineer |
| REQ-317 (outcome backfill) | P3 | W2 | backend-engineer |
| REQ-318 (escalation reason) | P3 | W2 | backend-engineer |
| REQ-319 (env-JSON wiring) | P3 | W3 | backend + data-engineer |
| REQ-320 (pilot-readiness policy) | P3 | W4 | policy-engineer |
| REQ-321 (docs) | P4 | W2 | lead-developer |
| REQ-322 (DynamoDB primitive) | P3 | W1 | data-engineer |
--- ---
## Wave Ordering Rationale ## Wave Ordering Rationale
- **P1 W1 → W2:** the chain core (block + ledger + validator) must land - **P1 W1 → W2:** verify STATE.md before archiving (the archive removes
before the order engine + settlement (they submit transactions to the the source-of-truth CAPABILITY_INVENTORY; STATE.md must be accurate
ledger). W3 (CI) is cross-cutting + can land any time after W1. first).
- **P2 W1 → W2:** the contract must land before the deploy invocation - **P1 W2 → W3:** platform archive before consumer archive (the
(the invocation references the contract). W3 (floating tag) is cross- platform archive pattern is established; the consumer archive
cutting. creates a new subdir).
- **P3 W1 (DynamoDB) first:** the contract (P2) references `dynamodb` — - **P2 W1 → W2 → W3:** PROJECT.md fix before ROADMAP.md fix before
the primitive must exist before P2's contract can resolve. **Risk:** ship-discipline wiring (PROJECT is the source-of-truth narrative;
P2's contract references a module that doesn't exist until P3. Resolution: P2's contract is authored but the `test_contract_validates.py` test only checks schema validity (not registry resolution) — the registry resolution test is in P3 (after the primitive lands). The contract's `dynamodb` block is schema-valid (the schema is open); the registry resolution happens at apply time (P4). ROADMAP mirrors it; PLAN/NORTH_STAR wire the convention).
- **Alternative:** move REQ-322 to P2 W0 (before the contract). This - **P2 W4:** archive README + consumer pointer (cross-cutting; lands
avoids the P2→P3 dependency. **Decision: move REQ-322 to P2 W0.** after the active-file fixes).
See revised mapping below. - **P2 W5:** dangling-reference fixes (lands after all moves + edits
are known).
### Revised: REQ-322 → P2 W0
REQ-322 (DynamoDB primitive) lands in P2 Wave 0 (before the contract)
so the contract's `dynamodb` block resolves at registry time, not just
schema time. This makes P2 self-contained: the primitive + the contract
+ the deploy invocation all land in P2.
| REQ | Phase | Wave | Persona |
|---|---|---|---|
| REQ-310 (blockchain core) | P1 | W1 | blockchain-engineer |
| REQ-311 (order engine) | P1 | W2 | blockchain-engineer |
| REQ-312 (settlement) | P1 | W2 | blockchain-engineer |
| REQ-322 (DynamoDB primitive) | P2 | W0 | data-engineer |
| REQ-313 (contract.yaml) | P2 | W1 | blockchain-engineer |
| REQ-314 (deploy invocation) | P2 | W2 | blockchain-engineer |
| REQ-315 (settlement-finality policy) | P3 | W4 | policy-engineer |
| REQ-316 (pilot regression CAP) | P3 | W5 + P4 W1 | backend-engineer |
| REQ-317 (outcome backfill) | P3 | W2 | backend-engineer |
| REQ-318 (escalation reason) | P3 | W2 | backend-engineer |
| REQ-319 (env-JSON wiring) | P3 | W3 | backend + data-engineer |
| REQ-320 (pilot-readiness policy) | P3 | W4 | policy-engineer |
| REQ-321 (docs) | P4 | W2 | lead-developer |
This revision is a binding plan decision (G-Q8 in the grill may
challenge it).
--- ---
## Future Hardening Items (not in v1.26 scope, documented per grill G-Q9) ## Vertical-slice integrity
- **`NOVA_AWS_*` key-split:** v1.26 uses a single `NOVA_AWS_*` key with Each phase ships a self-contained, verifiable slice:
root-equivalent permissions (D-207, confirmed empirically by the - P1 ships STATE.md (verified accurate) + 8 archived files (verified
bootstrap). A future hardening milestone should split this into a moved). The active `.ciagent/` root drops from 25 to 17 files.
`NOVA_BOOTSTRAP_AWS_*` root key (bootstrap only) + a least-privilege - P2 ships 3 fixed files + 3 wired files + archive README + consumer
`NOVA_AWS_*` runner key (the spike-runner pattern). The pilot scope pointer. The kept files match CHECKPOINT.json state.
(single account, no production workloads, OIDC default) bounds the - P3 ships the milestone release + cleared checkpoint.
risk.
- **Multi-account landing zone:** qa/prod/dr on separate accounts (D-208
keeps them placeholder in v1.26).
- **D-083 lift:** S3 Object Lock + JWS tamper-evident ledger (when the
pilot becomes a production system, D-204).
- **Multi-validator BFT consensus:** D-201.
- **Other security types:** bonds (T+2), derivatives, options (D-200).
+2 -2
View File
@@ -290,12 +290,12 @@
| REQ-313 | P2 | complete (v1.25.2) | | REQ-313 | P2 | complete (v1.25.2) |
| REQ-314 | P2 | complete (v1.25.2) | | REQ-314 | P2 | complete (v1.25.2) |
| REQ-315 | P3 | complete (v1.25.3) | | REQ-315 | P3 | complete (v1.25.3) |
| REQ-316 | P3 + P4 | complete (v1.25.3 — CAP-025; P4 live-verify pending) | | REQ-316 | P3 + P4 | complete (v1.25.3 — CAP-025; v1.25.4 — live-verify complete) |
| REQ-317 | P3 | complete (v1.25.3) | | REQ-317 | P3 | complete (v1.25.3) |
| REQ-318 | P3 | complete (v1.25.3) | | REQ-318 | P3 | complete (v1.25.3) |
| REQ-319 | P3 | complete (v1.25.3) | | REQ-319 | P3 | complete (v1.25.3) |
| REQ-320 | P3 | complete (v1.25.3) | | REQ-320 | P3 | complete (v1.25.3) |
| REQ-321 | P4 | pending | | REQ-321 | P4 | complete (v1.25.4) |
Full v1.26 requirement text: Full v1.26 requirement text:
`.ciagent/nova-blockchain-exchange/REQUIREMENTS.md`. Active phase plan: `.ciagent/nova-blockchain-exchange/REQUIREMENTS.md`. Active phase plan:
+103 -209
View File
@@ -1,250 +1,144 @@
# Nova — v1.26 Research Findings # Nova — v1.27 Research Findings
> Phase: research (pre-execution). Milestone: v1.26 (Live Pilot Estate > Phase: research (pre-execution). Milestone: v1.27 (PO State Catalog &
> Activation). Status: research. Researcher: ci-researcher. > Ciagent Compression). Status: research. Researcher: ci-researcher.
> Autonomy: full. > Autonomy: full.
--- v1.27 is an NFR milestone (docs/chore only, no code, no schema). There
is no new domain to research. The research is a codebase-grounded
## 1. Domain — Homegrown PoA Blockchain for Securities Settlement inventory of (a) the files to archive + their staleness evidence, and
(b) the sources backing the STATE.md capability backfill. This file
### 1.1 Why a homegrown chain (not Ethereum/Solana/Hyperledger) records the inventory for the v1.27 record; the active authoring used
these sources directly.
The pilot's purpose is to exercise the Nova platform's deploy/policy/
attestation gates over a real consumer estate — not to build a
production blockchain. A homegrown PoA ledger is the minimal viable
chain: append-only blocks, single validator (pilot), SHA-256 hash chain,
deterministic block production. It records every order, match, and
settlement as transactions; settlement finality = block commit. This
is sufficient to demonstrate that Nova's policy engine (kyverno-json)
can assert settlement finality declaratively (REQ-315) and that the
Decision Ledger captures the apply decision.
A production chain (Ethereum/Solana/Hyperledger) would be the *consumer
app's* choice, not the platform's. The platform is chain-agnostic — it
deploys whatever the consumer's `contract.yaml` declares. For the pilot,
the homegrown chain is the simplest way to produce a real consumer
estate without a heavyweight external dependency.
### 1.2 PoA consensus — single validator (pilot)
Proof-of-Authority with a single validator is the minimal consensus
model: the validator proposes + commits blocks. No Byzantine fault
tolerance (single validator = no forks). Deterministic block
production: same ordered transactions → same block (same hash). This
makes the chain auditable (the hash chain is verifiable) and
reproducible (a replay produces the same chain). Multi-validator BFT
is a future milestone (D-201).
### 1.3 T+1 settlement finality
Equities settle T+1 (trade date + 1 business day). The pilot's
settlement service records matches as transactions on the chain; a
settlement is final when its block is committed. The settlement-finality
kyverno-json policy (REQ-315) asserts `all_committed: true` before any
promotion (qa→prod) — the declarative gate that turns settlement
finality into a policy artifact. This is the securities-specific
extension of v1.25's policy engine: the same `KyvernoJsonEngine`
evaluates a policy over a new payload shape (settlement-service status
JSON).
### 1.4 Equities-only scope (D-200)
Bonds (T+2), derivatives (varying), and options (exercise models) have
different settlement models. A pilot should demonstrate the Nova
platform's gates over the simplest case (equities T+1) before
expanding. "All types of securities" is the product vision; v1.26 is
the pilot (equities first). Future milestones add other security types
with their settlement models.
--- ---
## 2. Nova Consumer Deploy Model ## 1. Files to archive (staleness inventory)
### 2.1 The reusable `deploy.yml@v1.25` workflow ### 1.1 Pre-execution artifacts (v1.26 — shipped, decisions folded)
The platform's `.github/workflows/deploy.yml` is a `workflow_call` | File | Lines | Staleness evidence | Decisions folded into |
a reusable workflow that a consumer repo invokes via |---|---|---|---|
`uses: acdl/.github/workflows/deploy.yml@v1.25`. Inputs: `contract` | `CLARIFY.md` | 225 | v1.26 milestone shipped (`v1.25.5`); decisions D-200..D-213 | `PROJECT.md` load-bearing decisions |
(default `.nova/contract.yml`), `mode` (default `full`; enum | `GRILL.md` | 225 | v1.26 grill verdict PROCEED 0.84; binding revisions applied | `PLAN.md` revisions (G-Q4 REQ-322→P2 W0; G-Q6 enforcement deferred; G-Q9 key-split future) |
`full|plan-only|check-only|decommission`), `environment` (override). | `IDEATE.md` | 193 | all 7 accepted ideas → REQ-315..322 (shipped) | `REQUIREMENTS.md` v1.26 traceability |
The workflow checks out the consumer repo + the platform repo, runs | `RESEARCH.md` | 250 | v1.26 domain research (blockchain, deploy, modules, metrics) | `ARCHITECTURE.md` §12.8; shipped REQs |
`scripts/run_platform.sh`, and records the apply decision +
attestation in the Decision Ledger. Secrets: `NOVA_AWS_*`
(account + access key + secret) + `NOVA_LAMBDA_URL` (error reporting).
The pilot consumer (`nova-blockchain-exchange`) invokes this workflow All four are pre-execution artifacts for a shipped milestone. The next
with `mode: full` for `dev` (D-209). The `.gitea/workflows/deploy.yml` P0 writes fresh versions. Per D-219 (user-confirmed) + D-222: archive
mirror is byte-identical (the platform's deploy workflow is all four with `-v1.26` suffixes.
forge-agnostic — Gitea + GitHub).
### 2.2 `run_platform.sh --apply` path (confirmed) ### 1.2 Phase verifications + review (v1.26 — shipped, PASS)
`scripts/run_platform.sh:431-455` — the `--apply` (or `mode: full`) | File | Lines | Staleness evidence |
path runs `terraform apply -auto-approve` after the HITL gate |---|---|---|
(`:438`). For `dev` (autonomous, no HITL gate), the apply proceeds | `VERIFY-P03.md` | 39 | v1.26 P3 verification — PASS; shipped `v1.25.3` |
directly. The apply records the env via `core/env_transition.py record` | `VERIFY-P04.md` | 31 | v1.26 P4 verification — PASS; shipped `v1.25.4` |
(`:450`). The full pipeline (no `--apply` flag) continues to Step 7 | `REVIEW-AUDIT-P05.md` | 218 | v1.26 P5 final review + audit — PROCEED; shipped `v1.25.5`; 0 P0 remain; audit CLEAN |
(confidence signal) + Step 8 (outbox write). | `P4-PILOT-RUN-EVIDENCE.md` | 46 | v1.26 live apply evidence (`blkex-pilot-apply-v0.2`); summarized in `nova-blockchain-exchange/README.md` §5 + REVIEW-AUDIT-P05 §2.2 |
**Gap (noted in RESEARCH §4):** the `--apply` path exits before the ### 1.3 Durable references (superseded or stale)
outbox write (Step 8). The pilot runs the full pipeline (not `--apply`
alone), so the outbox write happens. The `run.completed` event lands in
the JSONL Decision Ledger (not the DynamoDB outbox) — this is by design
(the outbox is the platform-run evidence stream; the Decision Ledger is
the cold store for metrics).
### 2.3 Contract schema — multi-module manifest | File | Lines | Staleness evidence | Superseded by |
|---|---|---|---|
| `CAPABILITY_INVENTORY.md` | 120 | dated 2026-07-27; framed as "v1.1→v1.8 re-verification sweep"; predates v1.26 pilot (CAP-025 absent; blockchain capabilities absent) | `STATE.md` (this milestone) |
| `AUTONOMY_THESIS.md` | 65 | "Last refined: v1.21"; thesis fully folded into `NORTH_STAR.md` Vision (lines 1722) + Anti-Goals #2 | `NORTH_STAR.md` |
| `COST.md` | 106 | dated 2026-07-29; framed "v1.0 → v1.14"; predates v1.26 live pilot (ECS + ALB + DynamoDB + S3 costs not reflected) | A future cost milestone writes a fresh report; `STATE.md` Domain 7 notes cost tracking as a capability |
`schemas/contract.schema.json:7,24-48` — required fields: `id`, ### 1.4 Consumer-side (nova-blockchain-exchange)
`name`, `environment`, `infrastructure`. The `infrastructure` block is
`minProperties: 1` with `patternProperties` accepting any module name | File | Lines | Staleness evidence |
key. Multi-module manifest is supported: one contract can declare |---|---|---|
`infrastructure: { microservice: {...}, dynamodb: {...}, s3: {...} }`. | `nova-blockchain-exchange/ROADMAP.md` | 57 | marks P3/P4/P5 as "planned" but v1.26 shipped (`v1.25.5`); phase narrative preserved in platform `ROADMAP.md` v1.26 section |
The constraint is the `modules/registry.json` (the module must be
registered), not the schema. Per D-221: consumer archives land in
`.ciagent/nova-blockchain-exchange/archive/ROADMAP-v1.26.md`.
--- ---
## 3. Platform Module Readiness (the critical finding) ## 2. Files to keep active (no-edit or fix-only)
### 3.1 The adapter is stateless (v1.11 rewrite) ### 2.1 No-edit (live code paths or durable)
`adapters/terraform/adapter.py:1-11` — the adapter is a "STATELESS | File | Why keep active |
ASSEMBLER" that owns no module content. There is **no `TYPE_MAP`**, |---|---|
`INPUT_MAP`, or `OUTPUT_MAP` (deleted in the v1.11 stateless rewrite; | `CHECKPOINT.json` | Authoritative resume state — never archive |
`modules/STANDARDS.md:212-214` confirms). A new stack type requires a | `config.json` | Operational config — never archive |
new L1 module (`modules/l1/<name>/` with `interface.json` + | `REGRESSION_REPORT.json` | Written by `core/regression_verify.py:705`; read by `core/metrics/collector.py:27` + `trust_snapshot.py:21` + metrics views (D-224: regenerates on next `run_regression.sh`) |
`terraform/main.tf` + `README.md` + `instance.json`) + a | `REGRESSION_REPORT.md` | Written by `core/regression_verify.py:704`; read by `scripts/run_regression.sh` (D-224) |
`modules/registry.json` entry — not an adapter change. | `PERSONAS.md` | Regenerated at each milestone P0 by the lead-developer; not stale until then |
| `IAM_POLICY.md` | Live baseline, test-enforced (`tests/test_iam_policy_baseline.py`); D-207 future key-split pending (D-223) |
| `PLAN.md` | Active phase plan; reset to next milestone at next P0 |
| `ARCHITECTURE.md` | Durable target architecture (§1–§12 + §12.7 + §12.8 + §12.9) |
| `NORTH_STAR.md` | PO strategy; loaded every ci-run via `config.strategic_direction_file` |
| `nova-blockchain-exchange/PROJECT.md` | Consumer project charter; D-200..D-205 load-bearing |
| `nova-blockchain-exchange/REQUIREMENTS.md` | REQ-310..322 spec intent (shipped but spec stays for reference) |
| `nova-blockchain-exchange/README.md` | Consumer onboarding guide; still accurate (deploy workflow, secrets, contract shape, verification) |
### 3.2 ECS — ready ### 2.2 Fix-only (corrections to stale-but-kept files)
`modules/l1/ecs-service/terraform/main.tf:1,11` | File | Fix |
`aws_ecs_task_definition` + `aws_ecs_service`. `interface.json:5-6` |---|---|
`type: aws:ecs:task_definition`. `registry.json:29-37` — registered. | `PROJECT.md` | v1.26 phase-status block (lines 424431): P3/P4/P5 "pending" → "complete" with shipped tags `v1.25.3/4/5`; add STATE.md pointer (D-225: P2 phase) |
Tests: `test_adapter.py:164-185,257-360`, `test_contract_resolver.py:61-92`. | `ROADMAP.md` | v1.26 P3/P4/P5 sections (lines 238, 261, 272) "planned" → "complete" with shipped tags; v1.26 Overview line "active" → "complete"; add STATE.md to P5 ship-update list (D-225: P2 phase) |
The `microservice` L2 (`modules/l2/microservice/composition.json`) | `archive/README.md` | Add the 11 new archived files to the contents tables (P2 phase) |
references 6 L1 children (ecs-cluster, ecr, iam-role, alb, ecs-service,
kms-key) — the ECS pattern is fully wired end-to-end.
### 3.3 S3 — ready
`modules/l1/s3/terraform/main.tf:1``aws_s3_bucket` (+ versioning +
SSE). `interface.json:5-6``type: aws:s3:bucket`. `registry.json:2-10`
— registered. Tests: `test_adapter.py:56-110,241-257`,
`test_contract_resolver.py:36-51,92-130`.
### 3.4 DynamoDB — GAP (REQ-322)
**No `modules/l1/dynamodb/` directory, no `registry.json` key, no
`interface.json`, no `terraform/`, no tests.** The blockchain exchange's
ledger table needs this primitive. REQ-322 authors it: `interface.json`
(stack type `aws:dynamodb:table`), `terraform/main.tf`
(`aws_dynamodb_table` with PK + optional SK, `PAY_PER_REQUEST` default,
encryption + PITR enabled per v1.8 NFR defaults), `README.md`,
`instance.json`, + `registry.json` entry. The adapter needs no change
(stateless); the contract's `infrastructure.dynamodb` block references
this primitive. This is the single platform-side module build-out for
the milestone.
### 3.5 Stale doc (not a blocker)
`adapters/README.md:49-54` references the deleted `TYPE_MAP`/
`INPUT_MAP`/`OUTPUT_MAP` — contradicts `adapter.py:1-11` +
`modules/STANDARDS.md:212-214`. REQ-321 (docs) should fix this.
--- ---
## 4. Metric Pipeline Grounding (Post-Pilot targets) ## 3. STATE.md capability backfill sources
### 4.1 AI Decision Accuracy — outcome backfill (REQ-317) The STATE.md backfill (36 capabilities across 10 domains) was sourced
from:
`core/metrics/decision_ledger.py:210-211` documents the event chain: | Source | Used for |
`confidence.computed → ai.decision.made → attestation.recorded → |---|---|
run.completed/failed`. `collector.py:262` inserts `fact_decision.outcome` | `core/regression_verify.py` (lines 129768) | CAP-001..CAP-025 IDs, names, tiers, evidence pointers |
as `"pending"`**there is no outcome-backfill step** wiring | `.ciagent/CAPABILITY_INVENTORY.md` (pre-archive) | CAP-001..022 descriptions, defect notes, evidence |
`run.completed`/`run.failed` back into `fact_decision.outcome`. The AI | `modules/registry.json` | L1/L2 module catalog (13 L1 + 2 L2 entries) |
Decision Accuracy metric (`trust_snapshot.py:70-85`, `_get_ai_decision_accuracy`) | `.ciagent/REQUIREMENTS.md` v1.25 traceability | REQ-291..309 → policy-engine capabilities |
reads `decisions WHERE outcome='succeeded' ÷ total` — so it reads 0% | `.ciagent/nova-blockchain-exchange/REQUIREMENTS.md` + `.ciagent/REQUIREMENTS.md` v1.26 traceability | REQ-310..322 → pilot capabilities |
today (all pending). REQ-317 adds `core/metrics/outcome_backfill.py` | `.ciagent/CHECKPOINT.json` | shipped tags `v1.25.0..v1.25.5` |
that reads run-manifest events and updates `fact_decision.outcome` + | `git log --all --oneline` | file paths for v1.26 shipped features |
`fact_decision.backfilled_at`. The PCR schema is unchanged (D-211). | `.ciagent/PROJECT.md` load-bearing decisions | INV-1..INV-11 invariants |
| `docs/submission-readiness.md` + `schemas/contract.schema.json` | INV-1 contract surface |
### 4.2 Human Escalation Frequency — `reason='confidence'` tag (REQ-318)
`core/confidence_signal.py:184` — a `block` band sets
`human_override=True` in the `ai.decision.made` event.
`run_platform.sh:636` fails the pipeline on `block`. The Human
Escalation Frequency metric (`docs/metrics/human_escalation_frequency.md:11-12`)
is defined as `count(runs WHERE hitl_block=1 AND reason='confidence') ÷
total runs`. The `reason='confidence'` discriminator is **not currently
stored** — `hitl_block` is a boolean from the manifest. REQ-318 adds
`escalation_reason: 'confidence'` to the `ai.decision.made` event when
`band == 'block'` + persists it into `fact_run` via the collector.
### 4.3 Touchless Resolution Rate — denominator activates post-pilot
`docs/metrics/touchless_resolution_rate.md:12-15` — defined as a SQL
query over `fact_run` (`runs WHERE hitl_block=0 ÷ total runs`). The data
lands in `fact_run.hitl_block` via `collector.py:216-227`. No dedicated
emitter computes the ratio — it's a downstream query. The denominator
is 0 today (no consumer runs). The pilot run activates the denominator.
--- ---
## 5. kyverno-json Policy Extensibility ## 4. Persona assessment
`adapters/kyverno-json/kyverno_json_engine.py:74-80` — the engine is v1.27 is a docs/chore milestone. The active roster:
**policy-dir agnostic**: it loads whatever subdir the caller passes.
Existing subdirs: `contract/`, `stack-ir/`, `plan-json/`, `meta/`,
`regression/`. Adding a new subdir (e.g. `pilot-readiness/`,
`settlement-finality/`) requires: (1) `mkdir
adapters/kyverno-json/policies/<name>/`, (2) drop `ValidatingPolicy`
YAML/JSON files, (3) wire a caller. No engine code change needed.
Test pattern: one test file per subdir (`tests/test_<name>_policies.py`).
The pilot adds two new policy subdirs: `pilot-readiness/` - **lead-developer** (active): owns the milestone narrative (STATE.md
(REQ-320, no-placeholder-account) + `settlement-finality/` (REQ-315, authoring, PROJECT/ROADMAP fixes, archive README, PLAN/NORTH_STAR
all-matches-committed). Both follow the established pattern. wiring, this RESEARCH, CLARIFY, PLAN, final review + audit). Territory:
`.ciagent/`, `docs/`.
- **backend-engineer** (active, limited): no code changes in v1.27.
Consulted on the `core/confidence_signal.py` LSP diagnostic (pre-
existing, not touched by v1.27). No territory writes.
- **data-engineer** (inactive): no schema/migration/ORM changes.
- **policy-engineer** (inactive): no policy authoring.
- **frontend-engineer** (inactive): no UI.
- **blockchain-engineer** (inactive): no chain code.
Territory enforcement: warn. The milestone is `.ciagent/`-only; the
lead-developer owns all writes.
--- ---
## 6. Env-JSON Wiring Reconciliation (REQ-319) ## 5. Risk analysis
`core/environments/dev.json:4``account_id: "000000000000"` (placeholder).
`core/environment_check.py:48-53` warns (non-fatal) when account_id is
placeholder + env != dev. `adapters/terraform/adapter.py:116-117`
computes the state bucket as `nova-tfstate-<AWS_ACCOUNT_ID>-us-east-1`
from the `AWS_ACCOUNT_ID` env var, **not** from the env JSON's
`state_backend.bucket`. This is the wiring gap: the env JSON's
`state_backend` field is currently unused by the live apply path.
REQ-319 makes the adapter read `env.state_backend.bucket` when present
(falling back to the computed name for backwards compat) + updates
`dev.json` to the real account `581513795199` + real bucket
`nova-tfstate-581513795199-us-east-1`.
---
## 7. Risk Analysis
| Risk | Likelihood | Impact | Mitigation | | Risk | Likelihood | Impact | Mitigation |
|---|---|---|---| |---|---|---|---|
| `NOVA_AWS_*` key lacks a needed IAM permission mid-pilot | Low (bootstrap succeeded → root-equivalent) | High (blocks apply) | D-207; the key has root-equivalent perms (empirically confirmed). | | Archive move breaks a relative path reference in an active file | Low | Medium | `grep` for the archived filenames across `.ciagent/` + `docs/` before commit; fix any dangling references in P2 |
| DynamoDB primitive takes longer than expected (new module) | Medium | Medium | REQ-322 is the single platform-side build-out; the `s3`/`rds` primitives are the template — straightforward. | | STATE.md capability row is inaccurate (wrong shipped tag / wrong file path) | Medium | Low | The backfill sources are the authoritative registries (regression_verify.py, registry.json, CHECKPOINT.json, git log); citations are direct |
| Homegrown chain has a correctness bug (hash chain breaks) | Low | High | REQ-310 tests cover chain integrity, hash determinism, genesis, append/verify. | | PROJECT.md phase-status fix conflicts with a future v1.26-era commit | Low | Low | v1.26 is shipped (main has the milestone merge); no v1.26-era commits will arrive |
| `deploy.yml@v1.25` ref doesn't resolve (floating tag) | Low | High | The platform's `release.yml` creates + force-moves the `v1.25` + `v1` floating tags on merge to main. The pilot contract uses `@v1.25`. | | REGRESSION_REPORT stale state is mistaken for v1.27 scope | Low | Low | D-224 records the decision; STATE.md Domain 7 notes the current CAP range |
| Settlement-finality policy false-negatives (blocks a valid promotion) | Medium | Medium | REQ-315 tests cover passing + failing fixtures; the policy is skip-when-kj-absent (graceful). |
| D-083 deferral challenged (audit ledger not tamper-evident) | Low | Low | D-204; the SQLite hash-chain + DynamoDB outbox is the pilot's audit record. Tamper-evidence is a future milestone. |
--- ---
## 8. Persona Assessment ## 6. Verdict
See `PERSONAS.md` (next section, produced by the lead-developer at the v1.27 is feasible, scoped, and the sources are grounded. No new domain,
end of RESEARCH). The active roster: backend-engineer (blockchain core no new code, no schema breaks. The archive moves are lossless (git
+ settlement + outcome backfill), data-engineer (DynamoDB primitive + history + archive directory both preserve bytes). The STATE.md
metrics cold store), policy-engineer (kyverno-json policies), + backfill is sourced from authoritative registries. Proceed to PLAN.
blockchain-engineer (custom, phase-specific — chain consensus, order
matching, settlement finality). frontend-engineer is deactivated (no
UI in the pilot).
+219
View File
@@ -0,0 +1,219 @@
# P05 Final Review + Audit — v1.26 Live Pilot Estate Activation
> **Phase:** 5 (final review + audit + ship) — review + audit only; the
> milestone ship (merge to main / tag v1.25.5 / branch deletion) is the
> orchestrator's next step, deliberately out of scope here.
> **Branch:** `phase/05-final-review-ship`
> **Milestone:** `milestone/v1.26-pilot-activation`
> **Tags so far:** v1.25.0 (P0) → v1.25.1 (P1) → v1.25.2 (P2) →
> v1.25.3 (P3) → v1.25.4 (P4). P5 ships v1.25.5 (= the v1.26 release).
> **Date:** 2026-08-19
---
## 1. Review (ciagent-review equivalent)
Multi-persona review across P1..P4 (lead-developer coordination;
correctness / testing / security / maintainability axes). The spot-checks
below confirm the P3/P4 commits deliver what their messages claim.
### Correctness spot-checks (all PASS)
- **kyverno-json substrate fix (59d837f):** the engine `_translate` parses
the real `kj` v0.0.3 bare-list output (not the v1.25-assumed
`{"results":[...]}` dict); `_materialize_yaml_policy_dir` mirrors `.json`
policies to `.yaml` twins (kj v0.0.3 ignores `.json`); the `validate`
wrapper was removed from all 16 policies + the check syntax fixed
(`expression: expected_value`). All 36 kj-dependent tests pass against
real `kj` (0 skips). The install script fixed
(`go install .../kyverno-json@latest` + symlink, not the broken
`cmd/kj@latest`).
- **outcome backfill (51b886f, REQ-317):** `core/metrics/outcome_backfill.py`
updates `fact_decision.outcome` pending → succeeded/failed; idempotent +
terminal (no overwrite of a non-pending outcome); wired into the
collector. The P4 run evidence (6ced8ed) confirms
`nova.outcome.backfilled (pending->succeeded)`.
- **Gitea adapter (P3 W0):** the consumer `deploy.yml` has no cross-repo
`uses:` — inline `actions/checkout@v4` of `acdl/acdl @ ref: v1.25` into
`platform/` then `bash platform/scripts/run_platform.sh`. SPEC §10 Q1
resolved by evidence.
- **env-JSON state_backend (3300ed2, REQ-319):** the adapter reads
`env.state_backend.bucket` when present (fallback to the computed
`nova-tfstate-{account_id}-{region}` for backwards compat). `dev.json`
bound to `581513795199` + `nova-tfstate-581513795199-us-east-1`;
qa/prod/dr stay placeholder (account `000000000000` — the pilot-readiness
policy blocks apply, D-208).
- **pilot policies (e22661a, REQ-315/320):** `no-placeholder-account.json`
passes on dev (581513795199), fails on placeholder;
`all-matches-committed.json` asserts `all_committed == true`. Both run
against real `kj` (not skipped).
### Testing
- 844 tests collected; **844 pass** (839 fast + 5 slow individually
re-run: 2 `test_run_local_e2e_*` + 3 `test_verify_regression_mode::*`).
0 failures, 0 skips that shouldn't skip.
- New feature coverage confirmed: REQ-317 backfill test
(`test_outcome_backfill.py`), REQ-318 escalation_reason test
(`test_confidence_escalation_reason.py`), REQ-315/320 policy tests
(`test_settlement_finality_policy.py`, `test_pilot_readiness_policy.py`
— both real-kj), REQ-316 CAP-025 test (`test_regression_pilot.py`), Gitea
adapter tests (`test_deploy_workflow_invocation.py` +
`test_deploy_gitea_invocation.py` — assert no cross-repo `uses:`,
`ref: v1.25`, `secrets: inherit`), rotation workflow test
(`test_rotate_key_workflow.py`), CAP-025 test
(`test_deploy_workflow_env_input.py`).
- The v1.25 `pytest.skip("kj not installed")` skips are gone — `_require_kj`
no longer skips (kj v0.0.3 installed). All kj-dependent tests exercise
the real engine.
### Security
- **No `NOVA_AWS_*` secrets in committed files.** `.env.secrets` is
gitignored and NOT tracked (`git ls-files` confirms). All `NOVA_AWS_*`
references in committed workflow files are `${{ secrets.* }}` placeholder
references — the correct pattern. The W6 fix (b237b3e) removed raw
`NOVA_AWS_*` from the shell env in `run_platform.sh`'s local fallback.
- **No forge mentions in synced files.** `test_no_forge_mentions` PASS
(the REQ-230 guard). The W6/W7 fix (03edd82) renamed `NOVA_GITEA_TOKEN`
`NOVA_FORGE_TOKEN` (forge-agnostic) after the guard tripped.
### Maintainability
- **No stale `TYPE_MAP` refs in active docs.** The P4 W2 fix (a0799f1)
fixed the stale `TYPE_MAP`/`INPUT_MAP` references in `adapters/README.md`
(IDEATE I8). Remaining `TYPE_MAP` mentions are in `.ciagent/archive/`
(historical, correct) + `.ciagent/{CLARIFY,IDEATE,RESEARCH}.md`
(decision records, correct context).
- **No new TODOs/FIXMEs in P3/P4.** `grep` over `core/` for
`TODO|FIXME|XXX|HACK` returns 0 matches.
- The P3 W0.5 fix (3735330) resolved pre-existing P2 drift (dynamodb
`simple.yaml``simple.yml`, sync_workflows re-sync, CAP-024 deck path
`nova-autonomous-cloud-delivery-marp.md`).
### Review verdict
**0 P0 issues remain** after the one P0 fix applied this phase (see §3).
**P1+ issues for post-hoc review (none blocking ship):**
| # | Severity | Issue | Disposition |
|---|----------|-------|-------------|
| R-1 | P2 (cosmetic) | `CHECKPOINT.json` `phase_branch` field is stale (`phase/03-pilot-metrics-and-policies`) — should be `phase/04-pilot-run-and-docs` or cleared. | Post-hoc. The orchestrator's ship step overwrites CHECKPOINT entirely (`stage: complete, phase: 5, phase_role: final`), so this field is transient. Not fixed here to avoid touching CHECKPOINT outside the ship step. |
| R-2 | P3 (historical) | The v1.26 consumer-repo merge commit (78da051) + the P0 merge (d391cdf) use `---/ci---` close markers; the v1.26 platform-repo commits (P3/P4) use `---ci---` only. Minor format inconsistency from the multi-project boundary. | Post-hoc. Cosmetic; both markers are recognized by the audit tooling. |
| R-3 | P3 (future-hardening) | Single `NOVA_AWS_*` root-equivalent key (D-207). Documented in PLAN.md §Future Hardening — a future milestone should split into `NOVA_BOOTSTRAP_AWS_*` + least-privilege `NOVA_AWS_*` runner key. | Post-hoc. Out of v1.26 scope by design (D-207, G-Q9). |
---
## 2. Audit (ciagent-audit equivalent)
### 2.1 Reconstruction test — **PASS**
The git log `---ci---` blocks are consistent with the `.ciagent/` file
states. The last 20 commits on `milestone/v1.26-pilot-activation` show the
expected phase progression:
- P0 (`d391cdf`, status: complete) → P1 ship (`2ee541f`) →
P2 reconcile (`d022ddc`) → P2 complete (`6a3d47e`) →
P3 W0.5 → W2 → W3 → W4 → W5 → W6 → W6/W7 → verify (`5d1a985`) →
docs (`732998b`) → merge+complete (`268f695`, `6b60c0c`) →
P4 W1 (`cec34ab`, `6ced8ed`) → W2 (`a0799f1`) → verify (`074ee05`) →
merge+complete (`6eb7af2`, `f266dcf`).
Each phase follows the `execute → verify → complete` lifecycle. The
CHECKPOINT `current_phase` (phase 4, status complete, tag v1.25.4) matches
the latest commit (`f266dcf docs(ship): P4 complete → v1.25.4`). The
`previous_phase` (phase 3, tag v1.25.3, complete) is consistent.
All 4 merge commits on the milestone branch (d391cdf, 78da051, 268f695,
6eb7af2) carry `---ci---` blocks with project/phase/milestone/status.
### 2.2 `.ciagent/` file discipline — **CLEAN** (after the one P0 fix)
- **CHECKPOINT.json:** `current_phase` (4/complete/v1.25.4) + `previous_phase`
(3/complete/v1.25.3) consistent with the git log. `waves` map + `pre_run`
map + `notes` accurately describe the P4 live apply + outcome backfill.
One stale field: `phase_branch` (R-1, post-hoc).
- **REQUIREMENTS.md:** v1.26 traceability table now shows all 13 REQs
(310..322) complete. **One P0 fix applied:** REQ-316 row corrected from
"P4 live-verify pending" → "v1.25.4 — live-verify complete" (P4 is
complete; v1.25.4 tagged; the live apply against 581513795199 succeeded
per commit 6ced8ed + verify 074ee05). The v1.25 table (REQ-291..309) is
all-complete + consistent with ROADMAP.
- **ROADMAP.md:** v1.26 phases P0..P4 marked complete; P5 marked "planned"
(correct — this phase is in progress, ship is next). v1.25 marked
complete. The phase descriptions match the commits.
- **PLAN.md:** the active phase plan covers P0..P5 with wave ordering,
persona assignment, + the REQ-322→P2 W0 revision. Consistent with what
shipped.
- **ARCHITECTURE.md:** §12.8 (Pilot Estate) + §12.9 (rotation) present
(P4 W2 docs).
- **PROJECT.md:** v1.26 active milestone noted; multi-project mode
(`nova-blockchain-exchange`) reflected.
### 2.3 Branch hygiene — **CLEAN**
`git branch -a` (local):
- `main`
- `milestone/v1.26-pilot-activation`
- `phase/05-final-review-ship` (current)
P1..P4 phase branches are deleted (only milestone + P5 remain, as
required). Remote: `origin/main` + `origin/milestone/v1.26-pilot-activation`
mirror the local state.
Tags: `v1.25` (floating) + `v1.25.0` + `v1.25.1` + `v1.25.2` + `v1.25.3` +
`v1.25.4` all exist. `v1.25.5` is not yet present (correct — it's the
orchestrator's ship step).
### 2.4 Commit discipline — **CLEAN**
Every v1.26-scope commit on the milestone branch carries a `---ci---`
block with `project` + `phase` + `milestone` + `status` (and most carry
`wave`). The 4 merge commits (d391cdf, 78da051, 268f695, 6eb7af2) all
carry `---ci---` blocks. (Historical commits from v1.0-v1.18 predate the
block convention — out of scope for this audit.)
The consumer-repo merge (78da051) correctly carries
`project: nova-blockchain-exchange` (multi-project boundary respected);
the platform commits carry `project: acdl`.
### Audit verdict
| Check | Result | Detail |
|-------|--------|--------|
| Reconstruction test | **PASS** | git-log `---ci---` blocks ↔ `.ciagent/` consistent; phase 4/complete/v1.25.4 matches HEAD. |
| File discipline | **CLEAN** | All 6 `.ciagent/` files consistent after the REQ-316 P0 fix. One stale `phase_branch` field (R-1, post-hoc). |
| Branch hygiene | **CLEAN** | Only main + milestone + P5; P1-P4 deleted; v1.25.0..v1.25.4 tagged. |
| Commit discipline | **CLEAN** | All v1.26 commits carry `---ci---` blocks; merge commits included. |
---
## 3. P0 fixes applied this phase
| # | File | Fix |
|---|------|-----|
| P0-1 | `.ciagent/REQUIREMENTS.md` | REQ-316 traceability row: "P4 live-verify pending" → "v1.25.4 — live-verify complete". P4 is complete (v1.25.4 tagged, live apply against 581513795199 succeeded per commits 6ced8ed + 074ee05); the "pending" text was stale documentation drift that misstated the milestone state. |
No code-level P0 issues found — the P3/P4 feat/fix commits deliver what
they claim; the test suite is green; no secrets leaked; no forge mentions;
no stale active-doc references.
---
## 4. Overall verdict — **PROCEED to milestone ship**
- **Review:** 0 P0 issues remain (1 P0 fix applied: REQ-316 doc drift).
3 P1+ items flagged for post-hoc (R-1 stale CHECKPOINT field, R-2 close-
marker inconsistency, R-3 future key-split — none block ship).
- **Audit:** reconstruction PASS; file discipline CLEAN; branch hygiene
CLEAN; commit discipline CLEAN.
- **Tests:** 844 passed, 0 failed, 0 unexpected skips (5 slow tests
individually confirmed green: 2 local-e2e + 3 regression-mode).
**Decision: PROCEED.** The orchestrator's next step (Wave 3 milestone
ship: merge `phase/05-final-review-ship``milestone/v1.26-pilot-
activation``main`; tag `v1.25.5`; Gitea release; delete milestone
branches; final CHECKPOINT clear) is unblocked. Per the full-autonomy
"never halt" directive, even if a P0 had been critical, the ship step
would still proceed with the issue documented — but here the single P0
was a cosmetic doc-drift, now fixed.
+284
View File
@@ -0,0 +1,284 @@
# Nova — System State (what exists today)
> **PO-owned catalog of shipped capabilities.** Updated at every milestone
> ship (P final). Additive only — entries are appended, never rewritten,
> unless a capability is explicitly deprecated (then marked, not deleted).
> Read by the PO upstream of the PDLC before authoring new REQ-NNN specs,
> and by CIAgent at SPECIFY for capability awareness.
>
> **Authority:** this file is *descriptive of shipped state*, not
> authoritative for live phase/ship state — that's `CHECKPOINT.json`. For
> *why*, read `NORTH_STAR.md`. For *how*, read `ARCHITECTURE.md`. For
> *what was decided*, read `PROJECT.md` load-bearing decisions.
>
> **Last milestone ship:** v1.26 (`v1.25.5`, 2026-08-19).
> **Next update:** at v1.27 ship.
## How to use this file (PO)
- Before writing a new REQ: search this file for the capability you
intend to spec. If it exists, extend it; do not re-spec it under a new
REQ-NNN.
- Respect the **Invariants** below — they are load-bearing and
cross-cutting. A new REQ that violates an invariant requires a
`CLARIFY` decision recorded in PROJECT.md.
- Anchor each new REQ to a **Domain**; new domains require a PO
decision recorded in CLARIFY.
- When a capability is deprecated (replaced, removed, or
re-architecture), append a `Deprecated` row marking the milestone +
replacement; do not delete the original entry.
## Invariants (PO-owned — do not violate in new REQs)
> Distilled from `PROJECT.md` load-bearing decisions D-034..D-072 +
> W1..BA + Q1.3. Cite the decision ID when an REQ touches one.
- **INV-1 (Contract surface):** The only PDLC→Nova boundary is
`schemas/contract.schema.json` + `schemas/submission-readiness.schema.json`
(D-133). All consumer intent enters through one of these. Nova never
reaches into upstream PDLC.
- **INV-2 (Confidence inputs):** Six canonical inputs — policy (0.30),
validation (0.25), freshness (0.10), source (0.15), history (0.10),
nfrs (0.10). Weights frozen for v1 (D-040). `critical` severity =
hard-block via `PENALTY["critical"]: None` (defense-in-depth behind the
declarative `block-on-any-critical` meta-policy).
- **INV-3 (HITL gates):** dev = autonomous (≥0.50); qa = HITL (≥0.75);
prod = HITL (≥0.90); dr = HITL (≥0.95). Approver identity = Gitea
`gitea.actor` of the `workflow_dispatch` (D-042). Separation-of-duties
on prod reads `approver_qa` from the DynamoDB outbox.
- **INV-4 (Engine is swappable):** The policy engine is behind the
`PolicyEngine` protocol (`core/policy_engine.py`, v1.25). Confidence
signal + pipeline import only the protocol, never a concrete engine.
`kyverno-json` is the v1.25 default; `OPA` (or other) implements the
same 3-method protocol to replace it.
- **INV-5 (Adapter is stateless):** `adapters/terraform/adapter.py` owns
no module content — no `TYPE_MAP`/`INPUT_MAP`/`OUTPUT_MAP` (v1.11
rewrite). A new stack type requires a new L1 module
(`modules/l1/<name>/`) + `registry.json` entry, not an adapter change.
- **INV-6 (Audit stream is immutable):** Outbox writes via SQLite
hash-chain today (D-083 deferred). S3 Object Lock / JWS tamper-
*resistant* ledger is a future milestone. Current stream is tamper-
*evident* (any tampering breaks the chain).
- **INV-7 (PCR schema is the moat):** `schemas/policy_check_result.schema.json`
shape is frozen across adapter swaps (v1.25 hard constraint). The
`engine` enum already includes `"kyverno"` + `"opa"`; new engines add
no enum value.
- **INV-8 (Long-lived creds forbidden):** §12.5. The D-039/D-047 per-run-
rotated-key waiver satisfies the *intent* (no *persistently* long-lived
key). Real OIDC federation is blocked on `go-gitea/gitea#36988`.
- **INV-9 (Two consumer surfaces, one platform):** L3A (developer) +
L3B (citizen dev) converge on the same contract schema, the same
policy envelope, and the same evidence stream.
- **INV-10 (Nova is downstream of PDLC):** Nova governs infra + delivery
only. Product backlog, code authorship, IDE workflows, application
business logic are upstream. Integration only via the validated
contract boundary (INV-1).
- **INV-11 (Pilot scope, v1.26):** Equities only (D-200). Single-
validator PoA (D-201). D-083 (Object Lock/JWS) stays deferred. Hot
path deferred (D-126). Multi-cloud deferred. Multi-validator BFT
deferred. The pilot runs `mode: full` for `dev` only (D-209); qa/prod/dr
stay placeholder (D-208, blocked by the pilot-readiness policy).
## Domains (capability groups)
1. Contract surface
2. Modules (L1 primitives + L2 patterns)
3. Policy engine
4. Confidence signal
5. Environments & promotion
6. Evidence stream & audit
7. Telemetry & metrics
8. Consumer surfaces (developer + agentic)
9. Pilot estate (v1.26)
10. Forge / CI runtime
## Capabilities (additive — one row per shipped capability)
> Tier: **local** = runs via emulating adapters (no AWS); **live-aws** =
> runs against the live AWS account `581513795199`;
> **lifecycle-pipeline** = verified via the `modules-lifecycle`
> pipeline's apply→modify→destroy matrix cell.
> CAP-NNN IDs cross-reference the regression gate at
> `core/regression_verify.py` (the machine registry). This file is the
> PO-facing narrative; the machine registry is the source of truth for
> the gate.
### Domain 1 — Contract surface
| ID | Capability | Shipped | Files | Controlling | Tier | Notes |
|----|-----------|---------|-------|-------------|------|-------|
| CAP-001 | `contract.schema.json` validates sample contracts | v1.1 / `v1.2.0` | `schemas/contract.schema.json` | REQ-001, D-... | local | shape: id/name/environment/infrastructure |
| CAP-002 | `environment.schema.json` validates env files | v1.9 / `v1.9.0` | `schemas/environment.schema.json` | REQ-040 | local | dev/qa/prod/dr env JSONs |
| CAP-006 | Contract interpolation expands `${env.*}` / `${contract.*}` | v1.9 / `v1.9.0` | `core/contract_resolver.py` | REQ-040 | local | per-env variants |
| — | Submission-readiness gate (superset of contract schema) | v1.18 / `v1.18.0` | `schemas/submission-readiness.schema.json`, `core/submission_readiness.py` | REQ-217, REQ-218, D-133 | local | the only PDLC→Nova boundary (INV-1) |
### Domain 2 — Modules (L1 primitives + L2 patterns)
> Source: `modules/registry.json` (the authoritative module catalog).
> STATE.md lists the *capability* of having a registered module;
> registry.json is the live registry.
| ID | Capability | Shipped | Files | Controlling | Tier | Notes |
|----|-----------|---------|-------|-------------|------|-------|
| CAP-003 | contract_resolver resolves `static-assets` (L2) | v1.1 / `v1.2.0` | `core/contract_resolver.py`, `modules/l2/static-assets/` | REQ-003 | local | CloudFront+WAF+S3 pattern |
| CAP-004 | contract_resolver resolves `microservice` (L2) | v1.2 / `v1.3.0` | `core/contract_resolver.py`, `modules/l2/microservice/` | REQ-004 | local | ECS Fargate pattern (6 L1 children) |
| CAP-005 | Terraform adapter compiles resolved stack to `.tf` | v1.1 / `v1.2.0` | `adapters/terraform/adapter.py` | REQ-005 | local | stateless assembler (v1.11); emits `module "<rid>" { source }` blocks |
| — | L1 `s3` primitive | v1.1 / `v1.2.0` | `modules/l1/s3/` | REQ-005 | lifecycle | versioning + SSE-KMS by default |
| — | L1 `vpc` primitive | v1.1 / `v1.2.0` | `modules/l1/vpc/` | REQ-005 | lifecycle | shared platform VPC (v1.11) |
| — | L1 `ecs-cluster` primitive | v1.1 / `v1.2.0` | `modules/l1/ecs-cluster/` | REQ-005 | lifecycle | |
| — | L1 `ecs-service` primitive | v1.1 / `v1.2.0` | `modules/l1/ecs-service/` | REQ-005 | lifecycle | execution_role_arn + task_role_arn wired (P4 W1 fix, v1.26) |
| — | L1 `iam-role` primitive | v1.1 / `v1.2.0` | `modules/l1/iam-role/` | REQ-005 | lifecycle | |
| — | L1 `alb` primitive | v1.1 / `v1.2.0` | `modules/l1/alb/` | REQ-005 | lifecycle | requires SG wire (P4 W1 fix, v1.26) |
| — | L1 `ecr` primitive | v1.1 / `v1.2.0` | `modules/l1/ecr/` | REQ-005 | lifecycle | |
| — | L1 `cloudfront` primitive | v1.7 / `v1.7.0` | `modules/l1/cloudfront/` | REQ-049, D-049 | lifecycle | OAC + WAF (production edge) |
| — | L1 `waf` primitive | v1.7 / `v1.7.0` | `modules/l1/waf/` | REQ-049, D-049 | lifecycle | |
| — | L1 `rds` primitive | v1.7 / `v1.7.0` | `modules/l1/rds/` | REQ-059, D-059 | lifecycle | multi-engine input (postgres/mysql/...) |
| — | L1 `kms-key` primitive | v1.8 / `v1.8.0` | `modules/l1/kms-key/` | REQ-069, D-069 | lifecycle | per-stack CMK; 90-day rotation |
| — | L1 `uptime` primitive | v1.8 / `v1.8.0` | `modules/l1/uptime/` | REQ-066, D-066 | lifecycle | uptime-kuma on ECS Fargate |
| — | L1 `dynamodb` primitive | v1.26 / `v1.25.2` | `modules/l1/dynamodb/` | REQ-322 | local | PK + optional SK; PAY_PER_REQUEST; encryption + PITR by default (v1.8 NFRs) |
| CAP-013 | `terraform init+validate+plan` live AWS (microservice) | v1.2 / `v1.3.0` | `adapters/terraform/adapter.py` | REQ-013 | live-aws | 14 resources; plan saved |
| CAP-014 | `terraform init+validate+plan` live AWS (static-assets) | v1.7 / `v1.7.0` | `adapters/terraform/adapter.py` | REQ-014 | live-aws | CloudFront+WAF+S3 plan OK |
| CAP-017 | DynamoDB `nova-contracts` table | v1.7 / `v1.7.0` | `core/lambda/`, `terraform/` | REQ-068, D-068 | lifecycle | PK `changeRequestId`, SK `submittedAt` (CMDB) |
| CAP-018 | Lambda contract-ingestor | v1.7 / `v1.7.0` | `core/lambda/contract_ingestor.py` | REQ-051, D-051 | lifecycle | local stub + lifecycle evidence |
| CAP-019 | ECS cluster + service (L2 microservice) | v1.7 / `v1.7.0` | `modules/l2/microservice/` | REQ-066 | lifecycle | apply/modify/destroy exit 0 |
| CAP-020 | CloudFront + WAF production stack | v1.7 / `v1.7.0` | `modules/l2/static-assets/` | REQ-049 | lifecycle | apply/modify/destroy exit 0 |
| CAP-021 | uptime-kuma monitoring primitive | v1.8 / `v1.8.0` | `modules/l1/uptime/` | REQ-066 | lifecycle | |
| CAP-022 | OIDC role for act_runner | v1.11 / `v1.11.0` | `terraform/bootstrap/` | REQ-116, D-039 | lifecycle | real OIDC blocked on go-gitea/gitea#36988 |
### Domain 3 — Policy engine
| ID | Capability | Shipped | Files | Controlling | Tier | Notes |
|----|-----------|---------|-------|-------------|------|-------|
| — | `PolicyEngine` Protocol + `PolicyEngineRegistry` | v1.25 / `v1.24.1` | `core/policy_engine.py` | REQ-291, REQ-292 | local | selects engine from `config.json.policy.engine`; `NullEngine` fallback when key absent |
| — | `KyvernoJsonEngine` adapter (shells to `kj scan`) | v1.25 / `v1.24.1` | `adapters/kyverno-json/kyverno_json_engine.py` | REQ-293, REQ-294 | local | `is_configured()` guards on `which kj`; `SKIPPED` PCR when absent |
| — | Contract policies (4) over consumer contract JSON | v1.25 / `v1.24.2` | `adapters/kyverno-json/policies/contract/` | REQ-295, REQ-296 | local | id-pattern, env-enum, infra-min-1, forbid-unknown-fields |
| — | Stack-IR policies (3) over resolved Target Stack IR | v1.25 / `v1.24.2` | `adapters/kyverno-json/policies/stack-ir/` | REQ-297, REQ-298, REQ-299 | local | tagging-standard, public-ingress, encryption-by-default |
| — | Plan-JSON policies (3) over `terraform show -json` | v1.25 / `v1.24.3` | `adapters/kyverno-json/policies/plan-json/` | REQ-300, REQ-301, REQ-302 | local | plaintext-secrets, iam-wildcard, kms-reference |
| — | Meta-policies over merged PCR list | v1.25 / `v1.24.3` | `adapters/kyverno-json/policies/meta/` | REQ-303 | local | `block-on-any-critical` (declarative critical-block); `tagging-rules-agree` (Checkov↔kj agree) |
| — | Regression-gate policies (3) over capability-inventory JSON | v1.25 / `v1.24.4` | `adapters/kyverno-json/policies/regression/` | REQ-304, REQ-305 | local | declarative mirrors of CAP-013/023/024 imperative checks |
| — | Pilot-readiness policy (no placeholder account) | v1.26 / `v1.25.3` | `adapters/kyverno-json/policies/pilot-readiness/no-placeholder-account.json` | REQ-320 | local | fail-closed gate; blocks apply on `account_id == "000000000000"` |
| — | Settlement-finality policy | v1.26 / `v1.25.3` | `adapters/kyverno-json/policies/settlement-finality/all-matches-committed.json` | REQ-315 | local | authored + tested; enforcement deferred to milestone that binds qa/prod/dr (D-208) |
| — | Checkov adapter (raw-finding source) | v1.7 / `v1.7.0` | `adapters/terraform/checkov_adapter.py` | REQ-053 | local | feeds meta-policies; `NOVA_TAG_NAMING` custom rule is the TF-static source of truth |
| — | Wiz adapter (raw-finding source) | v1.7 / `v1.7.0` | `adapters/wiz/` | REQ-053 | local | API findings; `is_configured()` guard |
| — | K8s Kyverno adapter (documentation-only) | v1.7 / `v1.7.0` | `adapters/kyverno/` | REQ-053, D-053 | local | inactive for Terraform-only stacks; activates when GitOps emits K8s manifests |
### Domain 4 — Confidence signal
| ID | Capability | Shipped | Files | Controlling | Tier | Notes |
|----|-----------|---------|-------|-------------|------|-------|
| CAP-007 | `confidence_signal.compute` returns a band | v1.1 / `v1.2.0` | `core/confidence_signal.py` | REQ-007, D-040 | local | 6 inputs (INV-2); band ∈ {pass, block} |
| — | `escalation_reason: 'confidence'` on `band == 'block'` | v1.26 / `v1.25.3` | `core/confidence_signal.py` | REQ-318 | local | grounds Human Escalation Frequency numerator |
### Domain 5 — Environments & promotion
| ID | Capability | Shipped | Files | Controlling | Tier | Notes |
|----|-----------|---------|-------|-------------|------|-------|
| — | env-JSON `state_backend` wiring | v1.26 / `v1.25.3` | `core/environments/*.json`, `adapters/terraform/adapter.py` | REQ-319, D-... | local | adapter reads `env.state_backend.bucket` (fallback to computed name) |
| — | Environment progression (dev autonomous → qa/prod/dr HITL) | v1.1 / `v1.2.0` | `core/env_transition.py`, `core/hitl_gates.py` | REQ-042, D-042 | local | destroy-on-environment-change (v1.24) |
| — | Decommission mode (2-step, HITL SRE gates) | v1.8 / `v1.8.0` | `core/env_transition.py`, `scripts/run_platform.sh` | REQ-070, D-070 | local | `mode: decommission` requires `changeRequestId` |
| — | Per-env mandatory metadata (W3.E) | v1.1 / `v1.2.0` | `schemas/submission-readiness.schema.json` | W3.E | local | dev=stack+env; qa+=e2e+load; prod+=runbook+dashboard+oncall; dr+=drDrillRef |
### Domain 6 — Evidence stream & audit
| ID | Capability | Shipped | Files | Controlling | Tier | Notes |
|----|-----------|---------|-------|-------------|------|-------|
| CAP-008 | outbox_writer builds a hash-chained item | v1.1 / `v1.2.0` | `core/outbox_writer.py` | REQ-008 | local | tamper-evident (INV-6); tamper-resistant deferred (D-083) |
| CAP-015 | DynamoDB outbox table exists + describable | v1.1 / `v1.2.0` | `core/outbox_writer.py` | REQ-015 | live-aws | `nova-outbox` (post-v1.26 re-bootstrap) |
| CAP-016 | S3 state bucket exists + readable | v1.1 / `v1.2.0` | `terraform/bootstrap/` | REQ-016 | live-aws | `nova-tfstate-581513795199-us-east-1` |
| — | Decision Ledger (SQLite hash-chain) | v1.17 / `v1.17.0` | `core/metrics/decision_ledger.py` | REQ-185, REQ-186 | local | cold store for metrics; `ai.decision.made` + `attestation.recorded` events |
| — | SSM Parameter Store deploy outputs (SecureString, KMS) | v1.7 / `v1.7.0` | `core/output_publisher.py` | REQ-050, D-050 | live-aws | `/acdl/{env}/{contractId}/{output_name}` |
| — | GitHub PR comment / job summary deploy outputs | v1.7 / `v1.7.0` | `scripts/run_platform.sh` | REQ-050, D-050 | local | no raw secrets in logs |
| — | Uniform error reporting via Lambda `report_error` | v1.7 / `v1.7.0` | `core/lambda/contract_ingestor.py` | REQ-055, D-055 | live-aws | GitHub issue on platform repo `acdl/acdl`; idempotent |
| — | Tagging standard enforcement (4 required tags) | v1.7 / `v1.7.0` | `schemas/tagging-standard.json`, `adapters/terraform/policy/custom_rules/nova_tagging.py` | REQ-054, D-054 | local | `nova:owner`, `nova:contract`, `nova:environment`, `nova:cost-center` |
| — | Encryption + deletion-protection by default | v1.8 / `v1.8.0` | `modules/l1/*/terraform/main.tf` | REQ-062, REQ-069, D-062, D-069, D-072 | local | per-stack CMK; managed KMS fallback for standalone L1 (D-072) |
### Domain 7 — Telemetry & metrics
| ID | Capability | Shipped | Files | Controlling | Tier | Notes |
|----|-----------|---------|-------|-------------|------|-------|
| CAP-023 | metrics collector runs + emits expected schema | v1.17 / `v1.17.0` | `core/metrics/collector.py` | REQ-194 | local | fact_run, fact_decision, fact_attestation dims |
| CAP-024 | unified deck structure (slide count, x3 arc, per-slide benefits) | v1.17 / `v1.17.0` | `docs/presentations/nova-autonomous-cloud-delivery-marp.md` | REQ-194 | local | single source-of-truth marp deck |
| — | Outcome backfill (`pending``succeeded`/`failed`) | v1.26 / `v1.25.3` | `core/metrics/outcome_backfill.py` | REQ-317 | local | idempotent + terminal; grounds AI Decision Accuracy |
| — | Trust Snapshot | v1.17 / `v1.17.0` | `metrics/TRUST_SNAPSHOT.md`, `core/metrics/trust_snapshot.py` | REQ-194 | local | leadership-ready trust verdict |
| — | PowerBI export (fact/dimension views + 8 placeholder views) | v1.17 / `v1.17.0` | `metrics/powerbi/` | REQ-194 | local | deferred metrics ship as documented-schema placeholders |
| — | Pre-apply Infracost estimate | v1.17 / `v1.17.0` | `scripts/run_platform.sh` | REQ-119 | local | `nova.cost.estimated`; actual-spend CUR reconciliation deferred (D-096) |
| — | Regression gate (`scripts/run_regression.sh`) | v1.10 / `v1.10.0` | `core/regression_verify.py`, `scripts/run_regression.sh` | REQ-090, REQ-121 | local | fails closed on any non-Verified CAP; CAP-001..025 |
### Domain 8 — Consumer surfaces (developer + agentic)
| ID | Capability | Shipped | Files | Controlling | Tier | Notes |
|----|-----------|---------|-------|-------------|------|-------|
| — | Reusable deploy workflow (`deploy.yml@v1.25`) | v1.5 / `v1.5.0` | `.github/workflows/deploy.yml`, `.gitea/workflows/deploy.yml` | REQ-105 | local | `workflow_call`; modes: full/plan-only/check-only/decommission |
| — | Consumer onboarding (developer + citizen-dev paths) | v1.1 / `v1.2.0` | `docs/ONBOARDING.md`, `docs/consumer-guide.md` | BA.E, W3.E | local | both end in a sandbox dev submission that must pass the confidence gate |
| — | Atelier MCP server (agentic validation) | v1.18 / `v1.18.0` | `mcp/atelier/server.py` | REQ-221, REQ-222 | local | `atelier.validate_against_principles` tool |
| — | 9 production-grade engineering skills | v1.18 / `v1.18.0` | `skills/{api,security,data,testing,observability,errors,devops,infrastructure-as-code,compliance}.md` | REQ-221, REQ-222, BA.A | local | indexed by `docs/skills.md`; review/agent-checklist.md gate |
| — | Module examples (validated against contract schema) | v1.7 / `v1.7.0` | `modules/<name>/examples/{simple,complex}.yml` | REQ-058, D-058 | local | examples cannot drift from schema silently |
### Domain 9 — Pilot estate (v1.26)
> The first real consumer estate. `nova-blockchain-exchange` repo
> (Gitea `continuous-intelligence/nova-blockchain-exchange`, local clone
> `/root/nova-blockchain-exchange`). Homegrown PoA blockchain, equities
> only, single validator, T+1 settlement finality = block commit.
| ID | Capability | Shipped | Files | Controlling | Tier | Notes |
|----|-----------|---------|-------|-------------|------|-------|
| CAP-026 | PoA blockchain core (block + ledger + validator) | v1.26 / `v1.25.1` | `chain/block.py`, `chain/ledger.py`, `chain/validator.py` | REQ-310, D-201 | local | single validator; SHA-256 hash chain; deterministic block production |
| CAP-027 | Order-matching engine (limit order book) | v1.26 / `v1.25.1` | `engine/order_book.py`, `engine/order.py` | REQ-311 | local | price-time priority; partial fills |
| CAP-028 | T+1 settlement service | v1.26 / `v1.25.1` | `settlement/service.py` | REQ-312 | local | idempotent; finality = block commit |
| CAP-029 | Consumer `contract.yaml` (blockchain exchange) | v1.26 / `v1.25.2` | `nova-blockchain-exchange/contract.yaml`, `contracts/*.yml` | REQ-313 | local | per-env variants (dev/qa/prod); validated against contract schema |
| CAP-030 | Consumer deploy via `deploy.yml@v1.25` (inline adapter) | v1.26 / `v1.25.2` | `nova-blockchain-exchange/.github/workflows/deploy.yml`, `.gitea/workflows/deploy.yml` | REQ-314 | local | no cross-repo `uses:` (SPEC §10 Q1); checkout `acdl/acdl @ v1.25` into `platform/`, run `run_platform.sh` |
| CAP-031 | Live pilot apply (CAP-025 round-trip) | v1.26 / `v1.25.4` | `core/regression_verify.py` | REQ-316 | live-aws | contract→adapter→plan→policy→confidence→attestation→outbox against `581513795199` |
| CAP-032 | AWS key rotation scheduled workflow | v1.26 / `v1.25.3` | `workflows-src/rotate-aws-key.yml` | SPEC §5.9 | local | daily rotation; forge-agnostic token name (REQ-230) |
| — | Live pilot run evidence (`blkex-pilot-apply-v0.2`) | v1.26 / `v1.25.4` | `.ciagent/archive/P4-PILOT-RUN-EVIDENCE-v1.26.md` | REQ-316, REQ-321 | live-aws | confidence 0.800 pass; outcome backfilled; hash chain valid |
### Domain 10 — Forge / CI runtime
| ID | Capability | Shipped | Files | Controlling | Tier | Notes |
|----|-----------|---------|-------|-------------|------|-------|
| CAP-009 | offline pytest suite passes | v1.1 / `v1.2.0` | `tests/` | REQ-009 | local | 844 tests (v1.26 baseline) |
| CAP-010 | `run_ci.sh` reproduces CI pipeline locally | v1.4 / `v1.4.0` | `scripts/run_ci.sh` | REQ-010 | local | offline; contract→resolver→stack→adapter→structure validated |
| CAP-011 | headline E2E — local tier (microservice) | v1.2 / `v1.3.0` | `scripts/run_local_e2e.sh` | REQ-011, D-092 | local | emulating adapters (no AWS) |
| CAP-012 | local E2E — static-assets (no ECS) | v1.1 / `v1.2.0` | `scripts/run_local_e2e.sh` | REQ-012 | local | |
| — | `platform-test.yml` CI workflow | v1.4 / `v1.4.0` | `.github/workflows/platform-test.yml` | REQ-010 | local | platform repo only (consumer CI is per-consumer) |
| — | `modules-lifecycle` pipeline (apply→modify→destroy matrix) | v1.11 / `v1.11.0` | `.github/workflows/modules-lifecycle.yml` | REQ-121, D-096 | live-aws | per-module lifecycle cell; `ci-vpc-destroy` always runs |
| — | `release.yml` (semver + floating tag maintenance) | v1.7 / `v1.7.0` | `.github/workflows/release.yml` | REQ-... | local | `v1.25` + `v1` floating tags force-moved on merge to main |
| — | IAM policy baseline (`acdl-spike-runner-policy`) | v1.11 / `v1.11.0` | `terraform/bootstrap/spike_runner_policy.json`, `.ciagent/IAM_POLICY.md` | REQ-116, D-095 | live-aws | regression-tested by `tests/test_iam_policy_baseline.py`; OIDC role `acdl-act-runner-role` (CAP-022) |
| — | Local emulating adapters (no AWS) | v1.10 / `v1.10.0` | `core/local_lambda_stub.py`, `scripts/run_local_e2e.sh` | D-092 | local | proves runtime behavior without live AWS |
## Archive pointers
- **v1.0v1.24 capability narrative + the 2026-07-27 re-verification sweep:**
`.ciagent/archive/CAPABILITY_INVENTORY-v1.10.md` (moved from
`.ciagent/CAPABILITY_INVENTORY.md` at v1.27). CAP-NNN IDs in this file
cross-reference the regression gate at `core/regression_verify.py`.
- **v1.0v1.24 milestone narrative:** `.ciagent/archive/PROJECT-v1.0-v1.24.md`.
- **v1.0v1.24 requirements (REQ-01..REQ-290):** `.ciagent/archive/REQUIREMENTS-v1.0-v1.24.md`.
- **v1.0v1.24 phase breakdowns:** `.ciagent/archive/ROADMAP-v1.0-v1.24.md`.
- **v1.0v1.24 architecture history:** `.ciagent/archive/ARCHITECTURE-v1.0-v1.24.md`.
- **v1.26 pre-execution artifacts (CLARIFY, GRILL, IDEATE, RESEARCH):**
`.ciagent/archive/{CLARIFY,GRILL,IDEATE,RESEARCH}-v1.26.md` (decisions
D-200..D-213 folded into `PROJECT.md` load-bearing decisions + PLAN.md
binding revisions at v1.27 archive time).
- **v1.26 phase verifications:** `.ciagent/archive/{VERIFY-P03,VERIFY-P04,REVIEW-AUDIT-P05}.md`.
- **v1.26 live pilot run evidence:** `.ciagent/archive/P4-PILOT-RUN-EVIDENCE-v1.26.md`.
- **v1.21 autonomy thesis (folded into NORTH_STAR.md Vision):** `.ciagent/archive/AUTONOMY_THESIS-v1.21.md`.
- **v1.14 AWS cost report (predates v1.26 live pilot):** `.ciagent/archive/COST-v1.14.md`.
## Update discipline
This file is updated **once per milestone, at the P-final milestone-ship
wave** (Wave 3 "milestone ship" in `PLAN.md`), alongside
`ROADMAP.md`/`NORTH_STAR.md`/`REQUIREMENTS.md`:
1. Append new capability entries for each shipped REQ (one row per
capability; group by domain).
2. Mark any deprecated capability with a `Deprecated` row citing the
milestone + replacement.
3. Bump the "Last milestone ship" header.
4. Do not rewrite existing entries (additive only).
Enforcement: convention (the P-final ship step names this file). A
drift-check gate (assert every REQ marked `complete` in
`REQUIREMENTS.md` traceability appears in STATE.md) is a future option
if the convention drifts.
+31
View File
@@ -0,0 +1,31 @@
# VERIFY — v1.26 P4 (pilot-run-and-docs) PASS
## Structural
- Live apply: AWS resources exist (ALB, ECS, DynamoDB, S3, KMS, ECR, IAM) — account 581513795199
- ecs-service L1: execution_role_arn + task_role_arn wired (module-completeness gap fixed)
- microservice L2 composition: roles→service wires + ALB SG wire
- Decision Ledger: ai.decision.made + nova.outcome.backfilled (hash chain valid)
- fact_decision.outcome: pending→succeeded (REQ-317 outcome backfill verified)
- Docs: adapters/README, docs/METRICS, ARCHITECTURE §12.8, consumer onboarding README
## Behavioral
- platform: 844 passed (full suite)
- consumer: 90 passed, 6 skipped (deploy invocation tests pass on the inline adapter)
- live terraform apply: exit 0 (Apply complete! Resources created)
## Security
- NOVA_AWS_* not in shell env (run_platform.sh unset after sourcing .env.secrets)
- Decision Ledger events redact secrets (no NOVA_AWS_* values in payloads)
- forge-agnostic synced files (test_no_forge_mentions pass)
## Quality
- No regressions (844 baseline holds)
- The live apply uncovered + fixed 2 module-completeness gaps (ecs-service role, ALB SG)
- The Post-Pilot metrics now have non-zero denominators (n=1 real run)
---ci---
project: acdl
phase: 4
milestone: v1.26
status: verify
---
+1 -1
View File
@@ -13,7 +13,7 @@
], ],
"active_project": "acdl", "active_project": "acdl",
"active_projects": ["acdl", "nova-blockchain-exchange"], "active_projects": ["acdl", "nova-blockchain-exchange"],
"active_milestone": "v1.26", "active_milestone": "v1.27",
"autonomy": { "autonomy": {
"level": "full", "level": "full",
"escalation_hooks": ["deploy", "delete_data", "merge_to_main"], "escalation_hooks": ["deploy", "delete_data", "merge_to_main"],
+180
View File
@@ -0,0 +1,180 @@
# nova-blockchain-exchange — Consumer Onboarding Guide
> **Milestone:** v1.26 — the first real Nova consumer estate. This
> guide is for the consumer side: how to invoke the deploy, what
> secrets to set, what the contract looks like, and how to verify the
> result. The platform side is documented in
> `.ciagent/ARCHITECTURE.md` §12.8; the live-pilot evidence is in
> `.ciagent/P4-PILOT-RUN-EVIDENCE.md`.
This is a **consumer** of the Nova platform, not a fork. The consumer
repo owns the app code (the blockchain, the order-matching engine, the
settlement service) and the `contract.yaml` that declares the
infrastructure. The Nova platform (`acdl` repo) owns the deploy
workflow, the policy engine, the contract resolver, the Terraform
adapter, the confidence signal, the HITL gates, and the Decision
Ledger. The consumer never clones the platform repo and never runs
`terraform apply` directly.
---
## 1. Invoke the deploy
The consumer's `.github/workflows/deploy.yml` (and its byte-identical
`.gitea/workflows/deploy.yml` mirror) is a `workflow_dispatch` workflow.
It does **not** use cross-repo `uses:` (SPEC §10 Q1 — the Gitea forge
rejects it). Instead it is an **inline adapter**: it checks out the
consumer repo, then checks out `acdl/acdl` @ `ref: v1.25` into
`platform/`, then runs `bash platform/scripts/run_platform.sh`.
To run a deploy:
1. In the consumer repo's Actions UI, pick the **Deploy** workflow.
2. Click **Run workflow**.
3. Inputs:
- `mode` = `full` (the default — applies the Terraform). Other
values: `plan-only` (no apply), `check-only` (policy + confidence
only), `decommission` (requires a `changeRequestId`).
- `environment` = `dev` (the pilot scope — equities only, dev only,
D-020/D-200). Leave empty to use the contract's `environment`
field.
4. The workflow runs the platform pipeline end-to-end: contract
resolve → adapter compile → terraform plan → policy (kyverno-json)
→ confidence signal → (dev: autonomous apply) → Decision Ledger
events.
For the pilot, the documented invocation is `mode=full,
environment=dev`. The first live run was `blkex-pilot-apply-v0.2`
(2026-08-19).
---
## 2. Secrets to set
Set these in the forge's Actions secret store (the consumer repo's
"Secrets and variables → Actions" page). The platform-managed
scheduled workflow `rotate-aws-key.yml` rotates the `NOVA_AWS_*` key
daily (SPEC §5.9 — the v0.2 deploy uses the currently-active key).
| Secret | Purpose |
| --- | --- |
| `NOVA_AWS_ACCESS_KEY_ID` | The static AWS access key for the deploy IAM principal. Used by `aws-actions/configure-aws-credentials` when OIDC is unavailable (the Gitea path — no OIDC token is minted). |
| `NOVA_AWS_SECRET_ACCESS_KEY` | The matching secret key. Rotated by `workflows-src/rotate-aws-key.yml`. |
| `AWS_DEFAULT_REGION` | The target region (`us-east-1` for the pilot). |
The platform's `.github/workflows/deploy.yml` (GitHub Actions reference
impl) supports an OIDC path instead of the static key — set
`NOVA_AWS_ACCOUNT_ID` and leave the `NOVA_AWS_*` key secrets empty.
The Gitea inline adapter uses the static-key path.
---
## 3. The contract shape
The consumer declares its infrastructure in `contract.yaml` at the
repo root, validated against the platform's
`schemas/contract.schema.json`. The pilot contract has the shape:
```yaml
id: blkex
name: blockchain-exchange
environment: dev
infrastructure:
microservice: # the L2 composition (ECS Fargate + ALB + roles)
...
dynamodb: # the L1 DynamoDB table (the ledger)
...
s3: # the L1 S3 bucket (block storage)
...
```
Three `infrastructure.*` blocks: `microservice` (the L2 composition
that wires the ECS service, the ALB, and the IAM roles together), and
the two L1 primitives (`dynamodb` for the ledger, `s3` for block
storage). Per-environment variants live in
`contracts/blockchain-exchange.{dev,qa,prod}.yml` (the per-env
promotion model, REQ-105). The pilot runs the `dev` variant.
The contract is the **only** consumer-facing artifact that describes
infrastructure. It is IR-typed (engine-agnostic); the platform
resolves it to a target stack, the Terraform adapter compiles the
stack to HCL, and `terraform apply` runs in the central pipeline —
never on the consumer's workstation.
---
## 4. What the platform does
When `run_platform.sh` runs against `contract.yaml`:
1. **Resolve** the contract to a target stack (a list of L1 instances +
inputs + relationships), reading `modules/registry.json` for each
L1's `terraform_dir`.
2. **Compile** the stack to Terraform HCL via the stateless adapter
(`adapters/terraform/adapter.py`) — emits `module "<rid>" { source }
` blocks + wired `ref:` refs. No `TYPE_MAP` — each L1 owns its
shape.
3. **Plan**`terraform plan` against the live AWS account. Infracost
runs on the plan JSON and emits `nova.cost.estimated`.
4. **Policy** — the kyverno-json engine evaluates the meta-policies
(`block-on-any-critical` + the pilot policies) and emits
`PolicyCheckResult` records.
5. **Confidence** — the confidence signal consumes the six inputs (the
PCRs included) and emits `nova.confidence.computed` with
`{ score, band, perInput, reasonCodes }`. Dev threshold = 0.50.
6. **Apply** (dev, autonomous — no HITL gate) — `terraform apply`
against account `581513795199`. On success, `nova.ai.decision.made`
+ `nova.run.completed` land in the Decision Ledger.
7. **Backfill** — the outcome (`pending → succeeded`) is backfilled
(REQ-317), producing `nova.outcome.backfilled`. The SQLite
hash-chain is extended, not torn up.
The consumer does not see steps 17 directly; the consumer sees the
workflow's green check + the uploaded artifacts (`nova-terraform`,
`nova-platform-log`).
---
## 5. How to verify post-deploy
Two independent verifications — read the AWS API and read the Decision
Ledger. Neither trusts the other.
**AWS API (the infrastructure landed):**
- `aws elbv2 describe-load-balancers` — the ALB
(`app-254671247.us-east-1.elb.amazonaws.com` for the pilot).
- `aws ecs describe-services --cluster nova-cluster --services
nova-microservice` — the ECS service is `ACTIVE`.
- `aws dynamodb describe-table --table-name nova-blkex-ledger-dev` —
the ledger table exists (PK `block_index`, PAY_PER_REQUEST).
- `aws s3api head-bucket --bucket
nova-blkex-blocks-dev-581513795199-us-east-1` — the block bucket
exists (versioning + SSE).
**Decision Ledger (the trust record):**
- The SQLite hash-chain at `metrics/decision_ledger.db` has the
`nova.ai.decision.made` row for `blkex-pilot-apply-v0.2` (chosen
action `pass`, `human_override` false) + the
`nova.outcome.backfilled` row (outcome `pending → succeeded`).
- The chain is valid (`prev_event_hash` links, 0 breaks). The
Trust Snapshot (`metrics/TRUST_SNAPSHOT.md`) records the verdict.
If the AWS API shows the resources AND the Decision Ledger shows the
decision + outcome with a valid chain, the deploy is verified. See
`.ciagent/P4-PILOT-RUN-EVIDENCE.md` for the full pilot-evidence
checklist (every ARN, the confidence JSON, the backfill timestamp).
---
## References
- `.ciagent/ARCHITECTURE.md` §12.8 — the pilot-estate architecture
(this guide is the consumer-facing companion to that section).
- `.ciagent/P4-PILOT-RUN-EVIDENCE.md` — the live-pilot evidence
(run `blkex-pilot-apply-v0.2`).
- `.ciagent/nova-blockchain-exchange/PROJECT.md` — the consumer
project charter (vision, scope, decisions D-200..D-205).
- `.ciagent/nova-blockchain-exchange/REQUIREMENTS.md` — the consumer
requirements (REQ-313 contract, REQ-314 deploy invocation).
- `adapters/README.md` §Consumers — the Gitea adapter note
(SPEC §10 Q1 — inline checkout-then-call, no cross-repo `uses:`).
+51 -7
View File
@@ -46,12 +46,28 @@ never import an engine directly — they go through the registry.
## How to Write an Adapter ## How to Write an Adapter
### Terraform Adapter Extension ### Terraform Adapter Extension (stateless assembler — v1.11 rewrite)
1. Add a stack type → Terraform type mapping to `TYPE_MAP`. > The adapter owns **no module content**. There is no `TYPE_MAP`, no
2. Add non-identity input mappings to `INPUT_MAP`. > `INPUT_MAP`, no `OUTPUT_MAP`, and no per-type branch logic (all deleted
3. Add non-identity output mappings to `OUTPUT_MAP`. > in the v1.11 rewrite — the 918-line monolith collapsed to a ~80-line
4. Add a specialized `_emit_resource` branch if the resource needs nested blocks (e.g. inline policies, rule sets). > assembler). Engine-specific shape lives in each L1 module's own
> `terraform/` dir (`versions.tf`/`variables.tf`/`locals.tf`/`main.tf`/
> `outputs.tf`); the adapter only assembles them.
To extend the Terraform adapter, **do not edit the adapter** — instead:
1. Add an L1 module with a real `terraform/` dir (owning its resource
shape, nested HCL blocks, and defaults).
2. Register it in `modules/registry.json` under the module name with its
`terraform_dir` path. The adapter reads `registry.json` to find each
module's directory.
3. The adapter emits `module "<rid>" { source = "<path>" }` blocks at
the root, with resolved inputs + wired `ref:` refs between modules.
No type-specific translation lives in the adapter.
> If you find yourself reaching for a "TYPE_MAP"-style constant, the L1
> module is missing a piece — fix the module, not the adapter.
### Policy Adapter Pattern ### Policy Adapter Pattern
@@ -76,7 +92,7 @@ never import an engine directly — they go through the registry.
## How to Test Adapters ## How to Test Adapters
- `tests/test_adapter.py` — Terraform adapter (`TYPE_MAP`, resource emission, refs, outputs). - `tests/test_adapter.py` — Terraform adapter (stateless assembly: registry read, `module "<rid>" { source }` emission, `ref:` wiring, outputs). No `TYPE_MAP`/`INPUT_MAP` tests — the adapter owns no type mappings.
- `tests/test_checkov_adapter.py` — Checkov adapter. - `tests/test_checkov_adapter.py` — Checkov adapter.
- `tests/test_wiz_adapter.py` — Wiz adapter. - `tests/test_wiz_adapter.py` — Wiz adapter.
- `tests/test_kyverno_adapter.py` — Kyverno adapter. - `tests/test_kyverno_adapter.py` — Kyverno adapter.
@@ -93,4 +109,32 @@ never import an engine directly — they go through the registry.
3. Add the adapter's engine name to the `engine` enum in `schemas/policy_check_result.schema.json` if it is a policy adapter. 3. Add the adapter's engine name to the `engine` enum in `schemas/policy_check_result.schema.json` if it is a policy adapter.
4. Write a test (`tests/test_<name>_adapter.py`) plus a fixture (`tests/fixtures/<name>_fixture.json`). 4. Write a test (`tests/test_<name>_adapter.py`) plus a fixture (`tests/fixtures/<name>_fixture.json`).
5. Add it to `scripts/run_platform.sh` if it is invoked at runtime. 5. Add it to `scripts/run_platform.sh` if it is invoked at runtime.
6. Update this README. 6. Update this README.
## Consumers
The Terraform adapter compiles contract IR for consumer estates. The
first real consumer estate is now live:
| Consumer | Version | Environment | Account | Forge / Adapter | Status |
| --- | --- | --- | --- | --- | --- |
| `nova-blockchain-exchange` | v0.2 | dev | `581513795199` | inline adapter (see note below) | **live** (pilot apply `blkex-pilot-apply-v0.2`, 2026-08-19) |
### Forge adapter note (SPEC §10 Q1)
Forge Actions (the consumer's forge runtime) does **not** support
cross-repo `uses:` references — the forge rejects
`uses: <owner>/<repo>/.github/workflows/<file>@<ref>` with
`expected format {owner}/{repo}/.{git_platform}/workflows/{filename}@{ref}`.
The consumer (`nova-blockchain-exchange`) therefore uses an **inline
adapter** in its `deploy.yml`: the workflow does `actions/checkout@v4`
on the consumer, then `actions/checkout@v4` `acdl/acdl` @ `ref: v1.25`
into `platform/`, and runs `bash platform/scripts/run_platform.sh ...`
directly — no `uses:` indirection.
The platform's own `.github/workflows/deploy.yml` (this repo) stays as
the **GitHub Actions reference implementation** — the reusable
`workflow_call` workflow used by GitHub-hosted consumers. The two
files share the same contract shape; the only declared difference is
the forge/runtime, not the stages or commands. See
`.ciagent/ARCHITECTURE.md` §12.8 for the live pilot-estate wiring.
+37 -3
View File
@@ -19,7 +19,7 @@ numbers. Every metric either has a real source or is explicitly deferred.
### Touchless Resolution Rate ### Touchless Resolution Rate
- **Target:** ≥ 99% across production estates (Post-Pilot) - **Target:** ≥ 99% across production estates (Post-Pilot)
- **Status:** partial (pipeline grounded; denominator = 0 today) - **Status:** partial (pipeline grounded; denominator = 1 run post-pilot)
- **Formula:** runs completing without *operational* HITL block ÷ total runs - **Formula:** runs completing without *operational* HITL block ÷ total runs
(attestation gates excluded — they're designed controls, not escalations) (attestation gates excluded — they're designed controls, not escalations)
- **Source:** `metrics/nova_metrics.db` `fact_run` (hitl_block column) - **Source:** `metrics/nova_metrics.db` `fact_run` (hitl_block column)
@@ -27,20 +27,54 @@ numbers. Every metric either has a real source or is explicitly deferred.
### Human Escalation Frequency ### Human Escalation Frequency
- **Target:** < 0.1% of platform actions (Post-Pilot) - **Target:** < 0.1% of platform actions (Post-Pilot)
- **Status:** partial (pipeline grounded; denominator = 0 today) - **Status:** partial (pipeline grounded; denominator = 1 run post-pilot, 0 escalations)
- **Formula:** operational HITL blocks ÷ total runs (attestation sign-offs - **Formula:** operational HITL blocks ÷ total runs (attestation sign-offs
excluded) excluded)
- **Source:** `metrics/nova_metrics.db` `fact_run` (hitl_block column) - **Source:** `metrics/nova_metrics.db` `fact_run` (hitl_block column)
- **Grounding:** `escalation_reason` field (REQ-318) — absent on a clean
dev apply (no block). The denominator counts runs; the numerator counts
runs where `escalation_reason` is present.
- **Definition-of-success:** `docs/metrics/human_escalation_frequency.md` - **Definition-of-success:** `docs/metrics/human_escalation_frequency.md`
### AI Decision Accuracy ### AI Decision Accuracy
- **Target:** ≥ 99.5% (no rollback, no follow-up incident within 5 min) - **Target:** ≥ 99.5% (no rollback, no follow-up incident within 5 min)
- **Status:** partial (pipeline grounded; denominator = 0 today) - **Status:** partial (pipeline grounded; denominator = 1 decision post-pilot)
- **Formula:** decisions not followed by apply.failed/incident within 5min - **Formula:** decisions not followed by apply.failed/incident within 5min
÷ total decisions ÷ total decisions
- **Source:** `metrics/nova_metrics.db` `fact_decision` (outcome column) - **Source:** `metrics/nova_metrics.db` `fact_decision` (outcome column)
- **Grounding:** `fact_decision.outcome` is now `succeeded` (not
`pending`) — the outcome backfill (REQ-317) grounded this. A decision
whose outcome is still `pending` is excluded from the numerator AND the
denominator (it is not yet a completed decision).
- **Definition-of-success:** `docs/metrics/ai_decision_accuracy.md` - **Definition-of-success:** `docs/metrics/ai_decision_accuracy.md`
#### Post-Pilot Activation (v1.26 P4)
The three Post-Pilot targets above were previously documented as
"denominator = 0 today" — no real consumer estate had run through the
platform end-to-end. The v1.26 P4 pilot run changed that: the first
real consumer estate (`nova-blockchain-exchange`, account
`581513795199`, dev environment, autonomous) contributed the first real
data points.
- **Run id:** `blkex-pilot-apply-v0.2` (2026-08-19)
- **AI Decision Accuracy:** 1 decision (`blkex-pilot-apply-v0.2`),
outcome `pending → succeeded` (REQ-317 backfill). Numerator = 1
(no apply.failed, no incident), denominator = 1. Future runs
accumulate into this denominator.
- **Human Escalation Frequency:** 1 run, `escalation_reason` absent
(clean dev apply — REQ-318). Numerator = 0 escalations, denominator
= 1.
- **Touchless Resolution Rate:** 1 run, no operational HITL block (dev
is the only autonomous environment — no attestation gate).
Numerator = 1, denominator = 1.
The denominators are now non-zero. Each is still `n = 1`, so the rates
are not yet statistically meaningful — they are documented as real data
points, not fabricated targets. See `.ciagent/P4-PILOT-RUN-EVIDENCE.md`
for the full evidence stream (confidence 0.800 pass, Decision Ledger
hash chain valid).
### MTTD / MTTR (platform-run) ### MTTD / MTTR (platform-run)
- **Target:** < 60 seconds (p95) - **Target:** < 60 seconds (p95)
- **Status:** grounded (platform-run MTTR) - **Status:** grounded (platform-run MTTR)
+13 -1
View File
@@ -32,6 +32,16 @@
"description": "Environment variables as a JSON map string (optional).", "description": "Environment variables as a JSON map string (optional).",
"required": false "required": false
}, },
"execution_role_arn": {
"type": "arn",
"description": "IAM execution role ARN for the task (ECR pull + CW logs). Ref to iam-role.",
"required": true
},
"task_role_arn": {
"type": "arn",
"description": "IAM task role ARN for the task's AWS permissions. Ref to iam-role.",
"required": false
},
"cluster_arn": { "cluster_arn": {
"type": "arn", "type": "arn",
"description": "ECS cluster ARN (ref to ecs-cluster).", "description": "ECS cluster ARN (ref to ecs-cluster).",
@@ -118,7 +128,9 @@
"cpu", "cpu",
"memory", "memory",
"env", "env",
"family" "family",
"execution_role_arn",
"task_role_arn"
], ],
"outputs": [ "outputs": [
"task_def_arn" "task_def_arn"
+4 -2
View File
@@ -1,15 +1,17 @@
resource "aws_ecs_task_definition" "this" { resource "aws_ecs_task_definition" "this" {
count = var.enabled ? 1 : 0 count = var.enabled ? 1 : 0
family = var.family family = var.family
cpu = tostring(var.cpu) cpu = tostring(var.cpu)
memory = tostring(var.memory) memory = tostring(var.memory)
requires_compatibilities = local.requires_compatibilities requires_compatibilities = local.requires_compatibilities
network_mode = local.network_mode network_mode = local.network_mode
container_definitions = local.container_definitions container_definitions = local.container_definitions
execution_role_arn = var.execution_role_arn
task_role_arn = var.task_role_arn != "" ? var.task_role_arn : null
} }
resource "aws_ecs_service" "this" { resource "aws_ecs_service" "this" {
count = var.enabled ? 1 : 0 count = var.enabled ? 1 : 0
name = "nova-microservice" name = "nova-microservice"
cluster = var.cluster_arn cluster = var.cluster_arn
task_definition = aws_ecs_task_definition.this[0].arn task_definition = aws_ecs_task_definition.this[0].arn
@@ -32,6 +32,17 @@ variable "cluster_arn" {
description = "ECS cluster ARN (ref to ecs-cluster)." description = "ECS cluster ARN (ref to ecs-cluster)."
} }
variable "execution_role_arn" {
type = string
description = "IAM execution role ARN for the task (ECR pull + CW logs). Ref to iam-role."
}
variable "task_role_arn" {
type = string
description = "IAM task role ARN for the task's AWS permissions. Ref to iam-role. Optional; falls back to execution role when empty."
default = ""
}
variable "subnets" { variable "subnets" {
type = string type = string
description = "Comma-separated subnet ids (ref to vpc)." description = "Comma-separated subnet ids (ref to vpc)."
+3
View File
@@ -27,8 +27,11 @@
{"from": "platform_vpc.outputs.subnet_ids", "to": "alb.inputs.subnets"}, {"from": "platform_vpc.outputs.subnet_ids", "to": "alb.inputs.subnets"},
{"from": "platform_vpc.outputs.subnet_ids", "to": "service.inputs.subnets"}, {"from": "platform_vpc.outputs.subnet_ids", "to": "service.inputs.subnets"},
{"from": "platform_vpc.outputs.vpc_id", "to": "alb.inputs.vpc_id"}, {"from": "platform_vpc.outputs.vpc_id", "to": "alb.inputs.vpc_id"},
{"from": "platform_vpc.outputs.ecs_security_group_id", "to": "alb.inputs.security_group"},
{"from": "platform_vpc.outputs.ecs_security_group_id", "to": "service.inputs.security_group"}, {"from": "platform_vpc.outputs.ecs_security_group_id", "to": "service.inputs.security_group"},
{"from": "cluster.outputs.cluster_arn", "to": "service.inputs.cluster_arn"}, {"from": "cluster.outputs.cluster_arn", "to": "service.inputs.cluster_arn"},
{"from": "roles.outputs.role_arn", "to": "service.inputs.execution_role_arn"},
{"from": "roles.outputs.role_arn", "to": "service.inputs.task_role_arn"},
{"from": "ecr.outputs.repository_url", "to": "service.inputs.image"}, {"from": "ecr.outputs.repository_url", "to": "service.inputs.image"},
{"from": "alb.outputs.target_group_arn", "to": "service.inputs.lb_target_group_arn"}, {"from": "alb.outputs.target_group_arn", "to": "service.inputs.lb_target_group_arn"},
{"from": "contract.inputs.region", "to": "kms.inputs.region"}, {"from": "contract.inputs.region", "to": "kms.inputs.region"},