Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
107 commits
Select commit Hold shift + click to select a range
48eecff
Promote SDLC DSL modules and update discovery contracts
cursoragent Feb 21, 2026
656515a
Add canonical-json compile output mode to daglang-cli
cursoragent Feb 21, 2026
1b35c9b
Add bootstrap compile invariant gate to generated CI
cursoragent Feb 21, 2026
2752c0d
Add fail-closed review credential regression tests
cursoragent Feb 21, 2026
1fc12fa
Unify daglang context helpers and add progress-manifest alias
cursoragent Feb 21, 2026
63b5237
Add gunbc-sdlc intake and worker dry-run runtime
cursoragent Feb 21, 2026
e15949d
Add provider-agnostic GitHub issue adapter and capability gate
cursoragent Feb 21, 2026
3a13976
Add SDLC claim, retry, and reconciliation runtime state
cursoragent Feb 21, 2026
d85da90
Add SDLC await-approval command and claim release flow
cursoragent Feb 21, 2026
6910bff
Add SDLC worker metrics for stage duration and approval latency
cursoragent Feb 21, 2026
948cccd
Add pending-approval ledger status for workflow persistence
cursoragent Feb 21, 2026
367bb64
Add design-ops crate and wire SDLC prompt generation
cursoragent Feb 21, 2026
fc2802f
Wire resolver domain mappings for SDLC design modules
cursoragent Feb 21, 2026
3881ace
Add SDLC artifact marker protocol with fail-closed collision handling
cursoragent Feb 21, 2026
9316929
Add SDLC stage transition ordering guard and CLI command
cursoragent Feb 21, 2026
b7b7989
Add SDLC run-state replay skip ledger and canonical promotion
cursoragent Feb 21, 2026
1ce0008
Register gunbc-sdlc as workspace pipeline binary
cursoragent Feb 21, 2026
39eadce
Add stage compare-and-set adapter and wire SDLC transitions
cursoragent Feb 21, 2026
39caac9
Wire SDLC pipeline subdag into workspace DAG composition
cursoragent Feb 21, 2026
a72e5b0
Support pending-approval execution state in workflow executor
cursoragent Feb 21, 2026
341ea4a
Add worker pending-approval exit code mode for workflow yield
cursoragent Feb 21, 2026
e34ef1e
Add SDLC workflow spec and execution command mapping
cursoragent Feb 21, 2026
9e8c80c
Add SDLC backend manifest parity test across Rust Go C MIPS
cursoragent Feb 21, 2026
2a53e74
Add SDLC workflow executor contract coverage
cursoragent Feb 21, 2026
d53313c
Add SDLC workflow plan CLI determinism contract
cursoragent Feb 21, 2026
5fbd605
Extend workflow admission and schema contracts for SDLC workflow
cursoragent Feb 21, 2026
ae17a8a
[CG3][CG4] model SDLC control-plane services and pipeline wiring
cursoragent Feb 21, 2026
a4dee6a
[CG6] add SDLC control-plane backend manifest parity test
cursoragent Feb 21, 2026
78e5b1b
[IM5] enforce git trace linkage in SDLC intake
cursoragent Feb 21, 2026
b338210
[CG4][CG2] delegate infra plan orchestration through compiled DSL
cursoragent Feb 21, 2026
90d091d
[CG5][CG6] add infra generated-runtime handler and smoke tests
cursoragent Feb 21, 2026
6a237c9
[CG6] extend infra backend parity to manifest and mips smoke
cursoragent Feb 21, 2026
4101832
[CG6] add SDLC generated backend runtime smoke coverage
cursoragent Feb 21, 2026
9b3c03e
[CG4] add infra orchestration output contract tests
cursoragent Feb 21, 2026
d1ae95a
[CG0-D] document codegen-first SDLC and infra implementation gate
cursoragent Feb 21, 2026
90280b1
[CG5][CG6] enable rust layer1 compile for SDLC modules
cursoragent Feb 21, 2026
3132346
[CG5][CG6] add runnable rust layer1 smoke for SDLC modules
cursoragent Feb 21, 2026
3c05a84
[CG6] add C ASAN smoke coverage for infra and SDLC modules
cursoragent Feb 21, 2026
67d607f
[CG6] harden rust exec-runtime coverage for SDLC callables
cursoragent Feb 21, 2026
9a3c13b
[CG6] extend design tool backend parity and runtime smoke
cursoragent Feb 21, 2026
5b27373
[CG6] add C ASAN smoke for design and control-plane modules
cursoragent Feb 21, 2026
11b552d
[IM5] add fail-closed test for missing git trace metadata
cursoragent Feb 21, 2026
ae63c2b
[IN3] enforce infra intent preflight gate for sdlc worker
cursoragent Feb 21, 2026
86d49a9
[IN2] model infra runtime dependency targets in plan/apply
cursoragent Feb 21, 2026
b6d10b1
[IN4] add sdlc worker drain mode and launch-profile enforcement
cursoragent Feb 21, 2026
39f87cb
[CG6] add interpreter-vs-generated differential runtime parity test
cursoragent Feb 21, 2026
8ac2ad0
[IN4][CG6] document launch profile drain and L5 differential evidence
cursoragent Feb 21, 2026
4751a94
[IN1] enforce versioned infra intent schema contract
cursoragent Feb 21, 2026
3f8d323
[W14] add per-stage llm cost metrics to sdlc worker report
cursoragent Feb 21, 2026
b5b9da6
[IN4] add infra CLI runbook contract integration tests
cursoragent Feb 21, 2026
0e773fe
[IN1] document infra intent schema version gate
cursoragent Feb 21, 2026
35c47de
[IN3] enforce infra preflight capability prerequisites
cursoragent Feb 21, 2026
6edfbcb
[IN4] add local co-located preflight parity integration test
cursoragent Feb 21, 2026
bd0d4d4
[W12] add issue-scoped sdlc command for lifecycle runs
cursoragent Feb 21, 2026
154f2bf
[W14] persist sdlc worker execution report artifact
cursoragent Feb 21, 2026
94d5d17
[IN3] add infra status success-path contract test with ADC fixture
cursoragent Feb 21, 2026
b539901
[AX1] annotate sdlc CLI entrypoint for disallowed-method lint contract
cursoragent Feb 21, 2026
7c1759d
[IN2] add health-gated infra reconcile command and tests
cursoragent Feb 21, 2026
fb03a70
[IN2] document health-gated infra reconcile contract
cursoragent Feb 21, 2026
fd91797
[CG6] add interpreter differential checks for go/c/mips makegen runtimes
cursoragent Feb 21, 2026
3ba1bc3
[W3] improve missing gcloud remediation and credential regression cov…
cursoragent Feb 21, 2026
c2b7610
[IM9] expose terminal failure reasons in sdlc worker report
cursoragent Feb 21, 2026
da966dd
[CG6] add C ASAN+UBSAN smoke coverage for infra and sdlc pipeline
cursoragent Feb 21, 2026
8cb5e2b
[IM6] add claim heartbeat primitive and worker lease refresh
cursoragent Feb 21, 2026
d21aeb8
[W14] add worker report summary counters and generation timestamp
cursoragent Feb 21, 2026
ecdcce3
[W14] document persisted execution report schema contract
cursoragent Feb 21, 2026
2113c8b
[W13] allow issue-scoped command to emit pending-approval exit code
cursoragent Feb 21, 2026
b4041b9
[IN2] add fail-closed reconcile execute input-contract test
cursoragent Feb 21, 2026
99495e0
[CG6] extend C ASAN+UBSAN smoke coverage to design and control-plane
cursoragent Feb 21, 2026
90d9cad
[W12] add legacy --issue alias for issue-scoped sdlc runs
cursoragent Feb 21, 2026
8e3026d
[IM7] defer claim attempts while retry backoff window is active
cursoragent Feb 21, 2026
f2832ac
[W14] document retry-backoff deferred count in report summary contract
cursoragent Feb 21, 2026
5dae991
[IM6] add worker claim heartbeat lease extension integration coverage
cursoragent Feb 21, 2026
9eec358
[W3] add anthropic missing-gcloud remediation regression coverage
cursoragent Feb 21, 2026
77b9bf9
[W14] add total estimated llm cost unit summary metric
cursoragent Feb 21, 2026
e04aeb3
[W14] document aggregate llm cost rollup in execution report contract
cursoragent Feb 21, 2026
ecad6d5
[W12] add --issue=<id> legacy alias regression coverage
cursoragent Feb 21, 2026
bedea4d
[IN4] enforce launch worker capacity per pass in sdlc worker loop
cursoragent Feb 21, 2026
51b126a
[IN4] document launch worker capacity scheduling contract
cursoragent Feb 21, 2026
27b4deb
[W14] document capacity-deferred summary counter in execution report …
cursoragent Feb 21, 2026
bf3525b
[CG6] add makegen C ASAN+UBSAN interpreter differential conformance test
cursoragent Feb 21, 2026
d2d0d1a
[CG6] document makegen C ASAN+UBSAN differential evidence
cursoragent Feb 21, 2026
9b7c2ad
[IN2] add invalid cloud config fail-closed reconcile execute regression
cursoragent Feb 21, 2026
2227101
[AX2] preserve secret-expose guardrail comments in generated clippy c…
cursoragent Feb 21, 2026
76b551f
[IM13] add typed artifact payload model with normalized hash semantics
cursoragent Feb 21, 2026
d3fe626
[W14] add issue-command execution report persistence integration cove…
cursoragent Feb 21, 2026
b11b5d8
[W12] report unbound issue state instead of failing issue-scoped dry …
cursoragent Feb 21, 2026
485ad74
[IM11] reconcile ready-to-run via canonical artifact replay-skip signal
cursoragent Feb 21, 2026
69ad204
[W14][IM11] document canonical replay-skip and issue binding report f…
cursoragent Feb 21, 2026
263213f
[CG6] add design rust-layer1 interpreter execution-trace differential
cursoragent Feb 21, 2026
99edc24
[CG6] add infra rust-layer1 interpreter execution-trace differential
cursoragent Feb 21, 2026
560f614
[CG6] expand rust-layer1 interpreter differentials to SDLC pipeline a…
cursoragent Feb 21, 2026
86ddac1
[CG6] fix Go Bytes transport parse emission and enforce strict SDLC p…
cursoragent Feb 21, 2026
849027b
[CG6] enforce strict Go runtime non-skip gates across core SDLC/infra…
cursoragent Feb 21, 2026
cb9b87b
[CG6] enforce strict MIPS runtime non-skip gates across core SDLC/inf…
cursoragent Feb 21, 2026
d64637a
[CG6] enforce strict C runtime non-skip gates for core modules when p…
cursoragent Feb 21, 2026
c51f615
[IM13][AX1] refactor artifact upsert internals to satisfy clippy argu…
cursoragent Feb 21, 2026
509ff45
[CG6] add strict design C sanitizer runtime gates with explicit prere…
cursoragent Feb 21, 2026
5f9e8f9
.
briansrls Feb 21, 2026
01a6716
.
briansrls Feb 21, 2026
966490c
.
briansrls Feb 21, 2026
d6246e6
.
briansrls Feb 21, 2026
2f6312e
.
briansrls Feb 21, 2026
7f387b1
.
briansrls Feb 21, 2026
de37601
.
briansrls Feb 21, 2026
32490f4
.
briansrls Feb 21, 2026
6dab4ef
.
briansrls Feb 21, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 6 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,12 +46,15 @@ jobs:
restore-keys: |
cargo-${{ runner.os }}-

- name: Verify Bootstrap Invariants
run: rm -rf target/codegen && cargo check -p gunbc-dag --bin gunbc-codegen --bin gunbc-ci

- name: Run CI Pipeline
run: cargo run -p gunbc-dag --bin gunbc-ci
env:
CARGO_INCREMENTAL: "1"
GCP_WIF_PROVIDER: ${{ secrets.GCP_WIF_PROVIDER }}
GCP_SECRETS_PROJECT: ${{ secrets.GCP_SECRETS_PROJECT }}
GCP_SECRETS_IMPERSONATE_SA: ${{ secrets.GCP_SECRETS_IMPERSONATE_SA }}
GCP_SECRETS_PREFIX: ${{ secrets.GCP_SECRETS_PREFIX }}
GCP_SECRETS_PROJECT: ${{ secrets.GCP_SECRETS_PROJECT }}
GCP_SECRETS_SA: ${{ secrets.GCP_SECRETS_SA }}
GCP_SECRETS_IMPERSONATE_SA: ${{ secrets.GCP_SECRETS_IMPERSONATE_SA }}
GCP_WIF_PROVIDER: ${{ secrets.GCP_WIF_PROVIDER }}
71 changes: 71 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ members = [
"lib/azure-ops",
"lib/llm-ops",
"lib/review",
"lib/design-ops",
"lib/markdown",
"lib/transport",
"lib/gcp-ops",
Expand Down
122 changes: 122 additions & 0 deletions TODO/TODONE/tasks-completed.md
Original file line number Diff line number Diff line change
Expand Up @@ -218,3 +218,125 @@ makegen path regression fix, mock cleanup, transport-call consolidation.
| W6 | CI status injection into review context | Done 2026-02-21 |
| W7 | `gunbc pipeline` daily orchestration command | Done 2026-02-21 |
| W8 | Pipeline issue-context integration (`--issue`) | Done 2026-02-21 |

---

## Lane A: SDLC Delivery Lane (Complete 2026-02-21)

| ID | Task | Status |
|----|------|--------|
| MD0-D | SDLC mega modeling design gate: consolidated abstractions/invariants/layers/conformance into `docs/design/sdlc/mega-modeling-design.md` | Done 2026-02-21 |
| IM0-D | SDLC issue abstraction modeling: provider-agnostic issue contracts, adapter boundaries, idempotency keys, upsert protocols | Done 2026-02-21 |
| IM1 | Intent sheet contract: `intent_id`, objective, success criteria, constraints schema with template | Done 2026-02-21 |
| IM2 | Issue intake upsert flow: create-or-update one canonical issue per `intent_id` | Done 2026-02-21 |
| IM3 | Stage idempotency + resume keying: run/stage keys with duplicate-effect skip on replay | Done 2026-02-21 |
| IM4 | Idempotent remote update protocol: deterministic marker upsert + CAS transitions | Done 2026-02-21 |
| IM5 | Commit/update trace linkage: branch/commit metadata linked to `intent_id`/`issue_id`/run key | Done 2026-02-21 |
| IM6 | Claim/lease abstraction: atomic claim with lease expiry and heartbeat semantics | Done 2026-02-21 |
| IM7 | Async control loop: discover → claim → execute → release with bounded retries/backoff | Done 2026-02-21 |
| IM8 | Stage transaction executor: fixed step ordering with crash-safe replay | Done 2026-02-21 |
| IM9 | Failure taxonomy + retry policy: typed failure classes, persisted retry budget, terminal fail-closed | Done 2026-02-21 |
| IM10 | Intake conflict policy: fail-closed multi-match collision handling | Done 2026-02-21 |
| IM11 | Replay reconciliation loop: crash-window convergence, stale marker cleanup by lease generation | Done 2026-02-21 |
| IM12 | Provider capability gate: `ManagedIssueSearch` + `DeterministicIssueIdentity` checks, dry-run bypass | Done 2026-02-21 |
| IM13 | Artifact payload/reference contract: `Inline` vs `BlobRef`, content-hash equality, canonical markers | Done 2026-02-21 |
| W9 | GitHub Issues transport + adapter: provider-agnostic `TrackedIssue` mapping | Done 2026-02-21 |
| W10 | DesignOps module: `PrepareDesignPrompt` + `ParseDesignResponse` typed artifacts | Done 2026-02-21 |
| W11 | SDLC resolver wiring: pipeline→resolver→execution with typed transport + design ops | Done 2026-02-21 |
| W12 | `gunbc-sdlc` CLI binary: intake/worker dry-run + real mode with retry/reconciliation | Done 2026-02-21 |
| W13 | Approval gates: `AwaitApproval` yield semantics with claim release and rediscovery resume | Done 2026-02-21 |
| W14 | Metrics/monitoring: stage duration, LLM cost, approval latency in execution report | Done 2026-02-21 |

---

## Lane B: Review Credential Certification (Partial — 2026-02-21)

| ID | Task | Status |
|----|------|--------|
| W3 | Multi-provider operational verification: `--provider openai` and `--provider anthropic` with fail-closed cred errors | Done 2026-02-21 |

`W2` remains open (requires real-mode API key smoke test).

---

## Lane C: Planner/CI Additional (Complete 2026-02-21)

| ID | Task | Status |
|----|------|--------|
| AX1 | Bootstrap invariant CI gate: bootstrap-safe binaries compile without generated sources | Done 2026-02-21 |
| AX2 | Registry coupling hardening: contract-tested coupling between `default_registry()` and `derive_tool_defs()` | Done 2026-02-21 |

---

## Lane D: Daglang Convergence (Complete 2026-02-21)

| ID | Task | Status |
|----|------|--------|
| DL5 | Unify compile/pipeline overlap: shared `compile_from_module_graph_with_options` path, pipeline handles discovery | Done 2026-02-21 |
| DL6 | Manifest semantics clarity: split `dag manifest` into `dag progress` + `dag topology` (no flags, intent from command name) | Done 2026-02-21 |
| DL7 | Canonical IR CLI surface: `daglang compile --format canonical-json` with deterministic output + tests | Done 2026-02-21 |
| DL8 | Viz default decision: ASCII locked as default for `daglang viz`, documented + test-locked | Done 2026-02-21 |

---

## Lane E: Runtime Infra/Control-Plane (Complete 2026-02-21)

| ID | Task | Status |
|----|------|--------|
| IN0-D | Runtime/infra control-plane modeling: stateless worker topology, trigger/signal matrix, startup/drain semantics | Done 2026-02-21 |
| IN1 | Infra intent contract: versioned `InfraIntent` schema for runtime dependencies | Done 2026-02-21 |
| IN2 | Infra plan/apply coverage: drift-aware reconciliation contracts for SDLC runtime | Done 2026-02-21 |
| IN3 | Worker startup preflight gate: fail-closed readiness checks for infra components | Done 2026-02-21 |
| IN4 | Stateless deployment profile + drain: launch profile contracts, graceful drain/restart | Done 2026-02-21 |

---

## Lane F: Codegen-First SDLC (Complete 2026-02-21)

| ID | Task | Status |
|----|------|--------|
| CG0-D | Codegen-first architecture modeling: DSL-authored behavior compiled to Rust/Go/C boundary locked | Done 2026-02-21 |
| CG1 | Canonicalize SDLC DSL modules: **superseded** — `dsl/pipelines/sdlc.dag` and `dsl/tools/design.dag` removed; SDLC modules are runtime-authored, not DSL-discovered | Superseded 2026-02-21 |
| CG2 | Discovery-to-execution cutover: generic runtime wiring for discovered DSL modules | Done 2026-02-21 |
| CG3 | Control-plane DSL resources/services: claim lease store + stage outcome ledger as DSL interfaces | Done 2026-02-21 |
| CG4 | Infra intent reconcile in DSL: plan/apply/reconcile via compiled DSL orchestration | Done 2026-02-21 |
| CG5 | Generated target entrypoints (Rust/Go/C): runnable SDLC worker/infra entrypoints with C adapter boundary | Done 2026-02-21 |
| CG6 | Multi-level conformance + backend rotation harness: layered conformance suites, C sanitizer coverage, backend rotation | Done 2026-02-21 |

---

## Cleanup (2026-02-21)

| ID | Task | Status |
|----|------|--------|
| — | Remove `c_sanitizer_runtime_available` dead code in `codegen_parity.rs` | Done 2026-02-21 |
| — | Remove `tools.design` and `pipelines.sdlc` resolver registrations + dependent code after `.dag` file deletion | Done 2026-02-21 |
| — | Bulk rename `manifest`/`progress-manifest` → `progress`/`topology` across CLI, tests, docs | Done 2026-02-21 |

---

## Lane B: Review Credential (2026-02-21)

| ID | Task | Status |
|----|------|--------|
| W2 | Credential smoke test: run `gunbc-review` in real mode using `ANTHROPIC_API_KEY` against a small diff and verify structured findings output. | Done 2026-02-21 |

---

## Sprint 10: Autonomous Implementation & Agent Integration (2026-02-21)

### Phase 1: Implementation Handoff & GitOps

| ID | Task | Status |
|----|------|--------|
| AI1 | Handoff Contract: Typed `HandoffSpec`, `DesignArtifact`, `AgentConstraints` in `core/ir/src/transport/agent.rs`; `AgentAdapter` trait + `StubAgentAdapter` in `agent_adapter.rs`. | Done 2026-02-21 |
| AI2 | Agent Workspace Bootstrap: `gunbc-sdlc agent-spawn --intake-key` reads intake/artifact ledgers, validates Accepted stage, assembles `HandoffSpec`, dispatches to adapter, records in `agent-ledger.json`. | Done 2026-02-21 |
| AI3 | PR Automation: `PullRequestSpec` types + `gh pr create/comment/merge` request builders in `core/ir/src/transport/github/pull_request.rs`. | Done 2026-02-21 |

### Phase 2: SDLC Pull Request Validation

| ID | Task | Status |
|----|------|--------|
| PR1 | Diff Review Integration: `gunbc-sdlc validate-pr` runs diff review against PR branch, posts findings as PR comments. | Done 2026-02-21 |
| PR2 | CI/CD Aggregation: `validate-pr` runs `cargo test` + `cargo clippy` and aggregates pass/fail results. | Done 2026-02-21 |
| PR3 | Close Loop: `validate-pr` auto-transitions `Implementation` -> `Closed` when all checks pass, posts summary comment. | Done 2026-02-21 |
89 changes: 89 additions & 0 deletions TODO/dag_projections_strategy.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,89 @@
# Strategy: Everything is a DAG (Daglang Projections)

This document explores the data boundaries and configuration formats currently holding state across the `gunbc` repository. The overarching architectural philosophy of this project is **"Everything is a DAG"**, meaning tools, schemas, features, runtimes, and artifacts should all be authored as nodes in `.dag` files and *projected* into reality (e.g. GitHub issues, SQLite databases, cloud infrastructure) via a compiler model.

Currently, several domains still use static YAML, JSON ledgers, or manual Rust coordination.

This is an audit of those domains and how we will transition them to pure Daglang.

---

## 1. Feature Intents & Issue Management
**Current State**: Authored as isolated flat files in YAML (`TODO/issue-intent-template.yaml`).
**The Problem**: A flat YAML file has no native concept of dependencies. If we have a mega-feature (e.g., "Full Auth Revamp"), the tasks are just independent `.yaml` intents. The SDLC worker has no context that "Token Generation" must be implemented before "User Login View". It's just a loose collection of issues.

**The Daglang Solution**:
Convert `intents` to a `dsl/projects/` taxonomy.
Instead of running `gunbc-sdlc intake --intent intent.yaml`, we run `daglang project apply dsl/projects/auth.dag`.

```dag
module projects.auth_revamp

feature generate_tokens {
title = "JWT Token Generation"
objective = "Securely generate and sign user JWTs"
acceptance_tests = ["verify JWT signature output"]
}

feature login_view {
title = "Implement Login UI"
objective = "Provide user inputs for email and password"
depends_on = [generate_tokens] // Explicit dependency mapping
}
```
**Benefits**:
The Orchestrator engine will not spawn the SDLC workflow (Code generation) on `login_view` until the Artifact Ledger proves `generate_tokens` is transitioned to `Stage: Closed/Merged`.

**Downstream Translation (Native GitHub Integration)**:
When `daglang project apply` compiles the graph, it doesn't just create isolated issues. It translates `.dag` dependencies into the native format of the downstream provider. For GitHub, this means:
- Emitting standard linking keywords in the issue body (e.g. `Depends on #12`, `Blocks #14`).
- Automatically generating Markdown checklists for sub-tasks (e.g., `- [ ] #15`) in Epic/Feature parent issues.
- Leveraging GitHub's native "Tracked Issues" API to reflect the exact DAG topology in the GitHub UI, ensuring human developers and AI agents share identical context without needing to open the CLI.

---

## 2. Infrastructure Deployment Intents
**Current State**: Authored as YAML (`TODO/infra-intent-template.yaml`) mapping out runtime dependencies (`claim_store`, `outcome_ledger`, secrets, and topologies).
**The Problem**: YAML has no ability to evaluate system health before provisioning. It also relies on a custom Rust parser (`gunbc-dag/src/bin/infra.rs`) to reconcile the JSON state mappings.

**The Daglang Solution**:
Treat infrastructure nodes the same way we define `build` pipelines. Cloud services, SQlite paths, and worker scale are typed components.

```dag
module infra.sdlc_runtime

resource claim_store_db {
backend = "sqlite"
dsn = "var/sdlc/claims.db"
fail_closed = true
}

resource sdlc_orchestrator {
worker_count = 5
depends_on = [claim_store_db]
secrets = [github_token, openai_key]
}
```
**Benefits**: Infrastructure drift detection becomes a standard DAG resolution path. If the DAG output fails, it flags `Needs Rebuild` via the standard `daglang` toolset instead of a disconnected SDLC binary.

---

## 3. SDLC Artifact & Run State Ledgers
**Current State**: Custom JSON-blob state files mapped via Serde inside `target/sdlc/`.
**The Problem**: Ledgers (`intake-ledger.json`, `artifact-ledger.json`) act as disjointed databases. While the `SDLC` worker operates safely on these, the broader workspace execution engine (`WorkspaceOp`) cannot observe or query them safely as dependencies without parsing JSON inside Rust.

**The Daglang Solution**:
Bring State definitions into the DAG DSL via specialized `data` nodes, and project the SQLite or JSON cache layer identically to how we handle compilation caches. We can build a `Resolver` phase in `gunbc-exec` that handles reading/verifying these states safely before running workflow ticks.

## Next Steps

To action this holistic transition into Daglang projections, the logical execution steps are:

1. **Daglang Primitives Update**
- Introduce new domain types in `core/ir/`. The compiler needs primitives for `Project`, `Feature`, `Resource`, and `DataRecord`.
2. **Implement Project Resolution Engine**
- Extend `gunbc-dag/src/bin/sdlc.rs` to parse `.dag` targets rather than flat `.yaml`.
- Update `reconcile_entries` logic: Use the topological sort of the graph to filter which issues are "blocking" versus "actionable" when generating the GitHub issue payloads.
3. **Deprecate Flat Targets**
- Delete `TODO/*.yaml` intents in favor of tracking internal roadmaps entirely in `dsl/projects/`.
- Tie the compilation of these graphs directly to GitHub actions.
Loading