e3416f8e77
---ci---
phase: 0
milestone: v1.0
status: specify
decisions:
- id: D-001
decision: Use Gitea org continuous-intelligence for all ACDL repos
rationale: User-specified target org; already exists at git.cloudinit.dev
confidence: 0.95
alternatives: [new dedicated demo org]
- id: D-002
decision: Map "GitHub Actions" to Gitea Actions (act_runner) using same workflow YAML
rationale: Environment is Gitea; syntax-compatible with act_runner
confidence: 0.85
alternatives: [migrate to GitHub.com, raw shell scripts]
- id: D-003
decision: Collapse acdl-platform into the existing empty acdl repo
rationale: acdl already exists at org root; avoids a 4th repo
confidence: 0.90
alternatives: [create separate acdl-platform repo]
- id: D-004
decision: Use Gitea environment blocks + required reviewers for QA/Prod; fallback to manual workflow_dispatch with approval input
rationale: Spec mandates approval gates; forge supports environment protection
confidence: 0.80
alternatives: [external approval bot, no approval gates]
- id: D-005
decision: Hash-chained ledger (prev_hash + own hash via SHA-256 of canonical JSON) for evidence; declared demonstrative not adversarially secure
rationale: Spec asks for simple JSON; chain gives visible tamper-evidence
confidence: 0.85
alternatives: [signed commits only, full Merkle tree]
- id: D-006
decision: Confidence gate threshold = 0.50 exactly (base 0.90, fail drops to 0.40)
rationale: Explicit in spec
confidence: 0.99
alternatives: []
- id: D-007
decision: Each mock_apply.sh echoes "[L1: <name>] applying..." + "OK", sleeps 1s, exits 0
rationale: Spec literal; uniformity aids timeline parsing
confidence: 0.95
alternatives: [randomized sleep durations]
- id: D-008
decision: L3B keyword->stack mapping: gas/price/ingest/data-lake->commodity-price-feed; invoice/billing->invoice-service; analytics/historical/query->energy-analytics-api; regulatory/compliance/reporting/trading->regulatory-reporting; fallback->invoice-service
rationale: Mirrors the 4 L2 modules + Act 3 example issue text
confidence: 0.85
alternatives: [single default stack, ML classifier (forbidden by no-AI constraint)]
- id: D-009
decision: Init milestone = v1.0, branch milestone/v1.0-initial
rationale: init.md Step 5 mandates milestone/v1.0-initial
confidence: 0.99
alternatives: []
- id: D-010
decision: Single-project mode for the acdl checkout; ---ci--- blocks omit project field
rationale: User chose standalone single-project; no other projects in this checkout
confidence: 0.90
alternatives: [register acdl in /root multi-project config]
---/ci---
Specification: 30-minute executive demo of the Agentic Cloud Delivery Platform proving automatic, safe, audited infra delivery via local stubs on Gitea Actions (no cloud, no AI APIs).
Requirements: [3 repos under continuous-intelligence org, 8 L1 stub modules, 4 L2 composed modules mirroring S&P Global Energy use cases, 5 core scripts (mock_executor.sh, policy_checker.py, confidence_signal.py, evidence_writer.py, l3b_agent_stub.py), reusable Dev->QA->Prod pipeline with approval gates, issue-triggered L3B agent, Pages evidence timeline UI, 4 scripted demo acts]
Constraints: [local Linux OS, Gitea Actions + Environments, no AWS/GCP/Azure, no external LLM APIs, state in flat JSON/artifacts, EKS Fargate + serverless primitives (no VPC module), L1 single-purpose substrate-agnostic max-depth-1, L2 max-depth-5]
Out of scope: [real cloud provisioning, real LLM inference, production-grade infrastructure, adversarial tamper-proofing of evidence]
5.5 KiB
5.5 KiB
ACDL — Architecture (initial)
Initial architecture for the ACDL demo. May be incomplete; refined at phase boundaries.
Overview
The demo is a three-repo, stub-driven system that simulates an autonomous cloud delivery platform. No real cloud or AI is used; every "infrastructure" action is a bash/Python stub that emits structured evidence. The platform is driven by either a developer-supplied contract.yaml (L3A) or a natural-language GitHub Issue parsed by a keyword script (L3B), then flows through an autonomous Dev stage, manual QA and Prod approval gates, and finally publishes a hash-chained audit trail to a Pages site.
┌──────────────── acdl-contracts ─────────────────┐
Developer ───▶ │ commit contract.yaml Issue (NL intent) │
└────────────┬───────────────────┬────────────────┘
│ (push) │ (issue opened)
▼ ▼
┌─────────────────┐ ┌──────────────────────┐
│ reusable │ │ issue workflow → │
│ pipeline │ │ l3b_agent_stub.py → │
│ (acdl repo) │ │ contract.yaml → push │
└────────┬────────┘ └──────────────────────┘
│
┌────────────────────┼────────────────────┐
▼ ▼ ▼
Dev (autonomous) QA (approval) Prod (approval)
mock_executor.sh environment gate environment gate
policy_checker.py
confidence_signal.py
│
▼
evidence_writer.py ──▶ audit.json (hash-chained) ──▶ acdl-evidence
│
▼
index.html (Pages)
timeline UI
Components
| Name | Description | Boundaries | Depends On |
|---|---|---|---|
acdl repo |
Platform meta repo: reusable workflows, L1/L2 stub modules, core scripts | Owns workflows + stubs; does not hold contracts or evidence | — |
| L1 modules | Single-purpose infra primitives (EKS Fargate, IAM, Lambda, API Gateway, EventBridge, SQS, S3, CloudWatch) | One folder per L1; manifest.yaml + mock_apply.sh; do not compose with other L1s |
acdl repo |
| L2 modules | Composed stacks (invoice, commodity-price-feed, energy-analytics-api, regulatory-reporting) | Reference L1s by name; max depth 5; expressed as a composition manifest | L1 modules |
mock_executor.sh |
Reads an L2 composition, invokes each L1 mock_apply.sh, writes state.json |
Bash; reads L2 manifest + L1 manifests | L1/L2 modules |
policy_checker.py |
Reads contract.yaml; fails on forbidden keys (e.g. public-ingress: true) |
Python; emits POLICY_VIOLATION:<REASON> or pass |
contract.yaml |
confidence_signal.py |
Base 0.90; on policy failure drops to 0.40 and echoes reason | Python; calls policy_checker | policy_checker.py |
evidence_writer.py |
Appends an event to audit.json, links to previous event via SHA-256 chain |
Python; canonical-JSON hashing | audit.json |
l3b_agent_stub.py |
Parses Issue text by keywords, emits contract.yaml |
Python keyword map; no external APIs | contract.yaml schema |
acdl-contracts repo |
Developer + agentic entry surface; holds contracts + issue workflow | Triggers main pipeline on push | acdl reusable workflow |
acdl-evidence repo |
Pages host for audit.json + index.html timeline |
Read-only for the pipeline; written at finalize stage | evidence_writer.py output |
| Reusable pipeline workflow | Dev → QA → Prod → Finalize stages with environment gates | Gitea Actions; calls core scripts | All core scripts |
Data Flow
- A
contract.yamlarrives either by direct push (L3A) or by the issue workflow runningl3b_agent_stub.py(L3B). - Push to
acdl-contractstriggers the reusable pipeline in theacdlrepo. - Dev stage:
policy_checker.pyvalidates the contract;mock_executor.shapplies the L2 composition's L1s;confidence_signal.pycomputes the score;evidence_writer.pyrecords each step. If score < 0.50, the stage fails and evidence records the rejection. - QA stage: the workflow pauses on the
qaenvironment; a human approves. - Prod stage: same gate on the
prodenvironment. - Finalize: the workflow commits the updated
audit.jsontoacdl-evidence; Pages republishesindex.html, which fetches and renders the timeline.
Build Order
- Repo scaffolding: create
acdl-contractsandacdl-evidencein the org; seedacdldirectory layout. - L1 modules (8 stubs).
- L2 modules (4 compositions).
- Core scripts (
mock_executor.sh,policy_checker.py,confidence_signal.py,evidence_writer.py,l3b_agent_stub.py). - Reusable pipeline workflow (Dev → QA → Prod → Finalize) + environment gates.
- Issue-triggered L3B workflow in
acdl-contracts. - Evidence UI (
index.html+ Pages config). - Demo dry-run + the four scripted acts.