Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
77 commits
Select commit Hold shift + click to select a range
c3d07de
chore(analysis): add scale/context Phase 0-1 baseline runner
eybersjp Oct 7, 2026
6dba6bb
ci(analysis): run scale/context Phase 0-1 baseline
eybersjp Oct 7, 2026
dfb4c3e
docs(analysis): document Phase 0-1 baseline runner
eybersjp Oct 7, 2026
18f2009
docs(analysis): index Phase 0-1 baseline runner
eybersjp Oct 7, 2026
968ce78
docs(analysis): record Scale Context Iteration Phase 0-1 baseline
eybersjp Oct 7, 2026
7f9aba1
docs(analysis): index Scale Context Iteration baseline
eybersjp Oct 7, 2026
6f0ea76
docs(analysis): record Phase 0-1 findings in project memory
eybersjp Oct 7, 2026
d17a32c
docs(phase2): add reconciled v0.12 Scale Context Iteration specification
eybersjp Oct 7, 2026
f6c0199
docs(phase2): add v0.12 Scale Context Iteration technical design
eybersjp Oct 7, 2026
28efe48
docs(phase2): add deterministic v0.12 PLAN model
eybersjp Oct 7, 2026
cfbfbcf
docs(phase2): add v0.12 Scale Context Iteration implementation PLAN
eybersjp Oct 7, 2026
3fc3c60
chore(phase2): add deterministic v0.12 PLAN validator
eybersjp Oct 7, 2026
574c660
docs(phase2): document v0.12 PLAN validator
eybersjp Oct 7, 2026
411edf1
docs(phase2): index v0.12 specification design and PLAN
eybersjp Oct 7, 2026
21267e9
ci(phase2): validate deterministic v0.12 PLAN
eybersjp Oct 7, 2026
870670d
docs(phase2): record validated v0.12 PLAN evidence
eybersjp Oct 7, 2026
0814033
docs(phase2): index Phase 2 validation evidence
eybersjp Oct 7, 2026
2c26a65
docs(phase2): lock v0.12 PLAN in project memory
eybersjp Oct 7, 2026
604b465
feat(v0.12): add generic Cost Observatory runtime
eybersjp Oct 7, 2026
9ef419e
feat(v0.12): add Cost Observatory record schema
eybersjp Oct 7, 2026
f57920f
feat(v0.12): add T01 Development Contract generator
eybersjp Oct 7, 2026
ef7c1dc
test(v0.12): cover Cost Observatory acceptance criteria
eybersjp Oct 7, 2026
3827ce4
feat(v0.12): export Cost Observatory API
eybersjp Oct 7, 2026
a79c534
docs(v0.12): document T01 Development Contract generator
eybersjp Oct 7, 2026
61ef2df
docs(v0.12): index T01 Development Contract generator
eybersjp Oct 7, 2026
49b8b2b
chore(v0.12): ignore Cost Observatory runtime telemetry
eybersjp Oct 7, 2026
433163c
test(v0.12): add Cost Observatory validation command
eybersjp Oct 7, 2026
1d02733
ci(v0.12): validate Cost Observatory increment
eybersjp Oct 7, 2026
869bde4
test(v0.12): compare acceptance semantics independent of timestamp
eybersjp Oct 7, 2026
3b6164d
fix(v0.12): align T01 derived gates with validated PLAN
eybersjp Oct 7, 2026
5f09d04
docs(v0.12): record T01 code and architecture review
eybersjp Oct 7, 2026
4339ea1
docs(v0.12): record Phase 3 T01 validation and acceptance
eybersjp Oct 7, 2026
2a4d7c1
docs(v0.12): index Phase 3 T01 evidence
eybersjp Oct 7, 2026
d1cf199
docs(v0.12): record accepted T01 in project memory
eybersjp Oct 7, 2026
2087aa6
feat(v0.12): add T02 Development Contract generator
eybersjp Oct 7, 2026
c230ee6
feat(v0.12): add generic Workspace Target Engine
eybersjp Oct 7, 2026
a501266
feat(v0.12): add Workspace Target Registry schema
eybersjp Oct 7, 2026
7976417
feat(v0.12): bind Development Contracts to workspace targets
eybersjp Oct 7, 2026
8494433
feat(v0.12): extend Development Contract schema for target bindings
eybersjp Oct 7, 2026
3ccaa78
feat(v0.12): export Workspace Target Engine API
eybersjp Oct 7, 2026
83728d6
chore(v0.12): register DKF workspace target
eybersjp Oct 7, 2026
1f38032
test(v0.12): cover Workspace Target Engine acceptance criteria
eybersjp Oct 7, 2026
1033ac1
test(v0.12): add Workspace Target Engine validation command
eybersjp Oct 7, 2026
2175bdb
ci(v0.12): validate Workspace Target Engine increment
eybersjp Oct 7, 2026
10e2f6b
test(v0.12): follow canonical Development Contract schema version
eybersjp Oct 7, 2026
f03c4c1
docs(v0.12): document T02 Development Contract generator
eybersjp Oct 7, 2026
74a0f56
docs(v0.12): index T02 Development Contract generator
eybersjp Oct 7, 2026
a472a7a
test(v0.12): keep configuration readiness schema expectation current
eybersjp Oct 7, 2026
94a10a7
test(v0.12): prove target registry drift blocks acceptance
eybersjp Oct 7, 2026
d285fc2
docs(v0.12): record T02 Workspace Target Engine review
eybersjp Oct 7, 2026
2638622
docs(v0.12): record Phase 4 T02 validation and acceptance
eybersjp Oct 7, 2026
7037a81
docs(v0.12): index T02 review and validation evidence
eybersjp Oct 7, 2026
279d6b3
docs(v0.12): record accepted T02 in project memory
eybersjp Oct 7, 2026
cef34fa
feat(v0.12): add T03 Development Contract generator
eybersjp Oct 7, 2026
17012ca
feat(v0.12): add deterministic repository context cache
eybersjp Oct 7, 2026
559a79e
feat(v0.12): add deterministic Execution Capsule runtime
eybersjp Oct 7, 2026
4f1c814
feat(v0.12): feed fresh Execution Capsules into role contexts
eybersjp Oct 7, 2026
52d1a6b
feat(v0.12): expose capsule-aware context APIs
eybersjp Oct 7, 2026
5a454a0
fix(v0.12): make context cache fingerprints timestamp-independent
eybersjp Oct 7, 2026
8f37198
feat(v0.12): add Execution Capsule schema
eybersjp Oct 7, 2026
bf969a4
feat(v0.12): add context cache entry schema
eybersjp Oct 7, 2026
843f631
test(v0.12): verify deterministic context cache invalidation
eybersjp Oct 7, 2026
2d8fd4e
test(v0.12): cover Execution Capsules and context economy
eybersjp Oct 7, 2026
a3f0ea7
docs(v0.12): document T03 Development Contract generator
eybersjp Oct 7, 2026
b4a70fa
docs(v0.12): index T03 Development Contract generator
eybersjp Oct 7, 2026
99f2ff8
test(v0.12): add Execution Capsule validation command
eybersjp Oct 7, 2026
23ea0ae
ci(v0.12): validate Execution Capsules and context cache
eybersjp Oct 7, 2026
09a63ff
fix(v0.12): stabilize context cache configuration invalidation
eybersjp Oct 7, 2026
54291b8
fix(v0.12): require runtime fact identities
eybersjp Oct 7, 2026
f24003b
fix(v0.12): confine context cache IO to project cache root
eybersjp Oct 7, 2026
8b7acae
fix(v0.12): harden capsule cache trust and changed-file invalidation
eybersjp Oct 7, 2026
eac116b
test(v0.12): harden cache path and configuration invalidation coverage
eybersjp Oct 7, 2026
765a64a
test(v0.12): harden capsule trust and emit cost evidence
eybersjp Oct 7, 2026
cfab333
docs(v0.12): record T03 architecture code and security review
eybersjp Oct 7, 2026
c7d6079
docs(v0.12): record Phase 5 T03 validation and acceptance
eybersjp Oct 7, 2026
91b7e6f
docs(v0.12): index T03 review and validation evidence
eybersjp Oct 7, 2026
b0d848b
docs(v0.12): record accepted T03 in project memory
eybersjp Oct 7, 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
24 changes: 24 additions & 0 deletions .development-kit/workspace.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
{
"schemaVersion": 1,
"targets": {
"dkf-framework": {
"path": ".",
"kind": "development-framework",
"dependencies": [],
"commands": {
"test": "npm run release:validate",
"test:orchestration": "npm run orchestration-core:validate"
},
"capabilities": [
"dkf-control-plane",
"node-runtime",
"release-validation"
],
"verification": [
"test",
"test:orchestration"
],
"adapter": null
}
}
}
15 changes: 15 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,21 @@ jobs:
npm run token-efficiency:test
npm run token:audit:check

- name: Run Scale/Context Phase 0-1 baseline
run: node scripts/phase01-scale-context-baseline.mjs

- name: Validate Scale/Context v0.12 Phase 2 PLAN
run: node scripts/phase02-scale-context-plan-validate.mjs

- name: Validate v0.12 Cost Observatory increment
run: npm run cost-observatory:test

- name: Validate v0.12 Workspace Target Engine increment
run: npm run workspace-targets:test

- name: Validate v0.12 Execution Capsules & Context Cache increment
run: npm run execution-capsule:test

- name: Validate Design Authority governance
run: npm run design-authority:validate

Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -30,5 +30,6 @@ desktop.ini
.development-kit/runs/
.development-kit/decisions/
.development-kit/secrets/
.development-kit/telemetry/
freebuff-chat-*.md

51 changes: 51 additions & 0 deletions docs/03-reference/scripts/phase01-scale-context-baseline.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
# phase01-scale-context-baseline.mjs

## Purpose

`scripts/phase01-scale-context-baseline.mjs` is an analysis-only baseline runner for the Development Kit Scale, Context & Iteration initiative.

It measures the current framework before implementation changes are made. The script does not modify DKF production runtime behaviour, change package versions, publish releases, or mutate repository state outside temporary test fixtures.

## What it measures

The runner records:

- repository, test, and canonical instruction-file inventory;
- the existing deterministic token/context audit;
- representative single-package context packaging;
- representative multi-package context packaging;
- representative calculation-heavy context packaging;
- Autopilot state-file growth across 26 immutable revisions;
- current observability gaps for provider token usage, repository reads/scans, agent invocations, and host tool calls.

## Representative fixtures

The fixtures are synthetic and deterministic. They exercise the existing DKF runtime APIs rather than claiming to reproduce provider billing or a specific production repository exactly.

The multi-package fixture contains web, mobile, shared, calculation, and database-style paths. The calculation-heavy fixture establishes a baseline before domain/numerical gate profiles exist.

## Usage

Print JSON to standard output:

```bash
node scripts/phase01-scale-context-baseline.mjs
```

Optionally persist the JSON output:

```bash
node scripts/phase01-scale-context-baseline.mjs --out=path/to/baseline.json
```

## Measurement rules

The runner reuses `scripts/token-audit.mjs` and the existing `runtime/orchestration/token-efficiency.mjs` estimator.

Estimated token values therefore remain deterministic `ceil(characters / 4)` approximations and must not be represented as provider billing-token counts.

Metrics that the current runtime cannot observe are emitted as unavailable with a reason instead of being estimated or fabricated.

## Scope

This script belongs to Phase 0/1 evidence gathering only. Later Cost Observatory work may extend or replace parts of this runner after the baseline has been preserved.
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
# phase02-scale-context-plan-validate.mjs

## Purpose

`scripts/phase02-scale-context-plan-validate.mjs` validates the machine-readable Development Kit v0.12.0 Scale, Context & Iteration PLAN using the existing deterministic `runtime/orchestration/plan-validator.mjs`.

It is a Phase 2 planning validator. It does not implement v0.12 runtime functionality.

## Authoritative PLAN model

```text
docs/04-architecture/dkf-scale-context-iteration-v0.12-plan-model.json
```

## Validation performed

The script checks:

- declared task count;
- dependency references;
- dependency cycles;
- declared dependency graph versus computed graph;
- required logical resource ownership;
- duplicate resource ownership;
- acceptance-criterion coverage;
- configuration dependency validity.

The acceptance-criterion authority comes from the reconciled v0.12 specification.

## Usage

```bash
node scripts/phase02-scale-context-plan-validate.mjs
```

The command prints the complete deterministic validation report as JSON and exits non-zero when the PLAN is invalid.

## Scope

This validator intentionally reuses the existing DKF PLAN validation engine instead of creating a second planning model.

A green result proves structural PLAN consistency. It does not replace specification review, architecture review, implementation verification, or Product Owner release approval.
47 changes: 47 additions & 0 deletions docs/03-reference/scripts/phase03-cost-observatory-contract.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
# phase03-cost-observatory-contract.mjs

## Purpose

`scripts/phase03-cost-observatory-contract.mjs` creates or reuses the Development Contract for **DKF120-T01 — Cost Observatory**.

The contract is normal DKF runtime state and is persisted under:

```text
.development-kit/contracts/INC-DKF120-T01/
```

That directory remains git-ignored. The script itself is committed so contract construction is reproducible from the authoritative v0.12 sources.

## Authoritative sources

The contract binds:

- the v0.12 Scale, Context & Iteration specification;
- the v0.12 technical design;
- the validated v0.12 implementation PLAN;
- the Phase 0/1 baseline evidence.

Whole-file fingerprints remain authoritative even when the contract requests selected sections for context delivery.

## Acceptance criteria

The T01 contract owns:

- `DKF-120-AC-001`
- `DKF-120-AC-002`
- `DKF-120-AC-003`
- `DKF-120-AC-033`

## Usage

```bash
node scripts/phase03-cost-observatory-contract.mjs
```

The script validates the resulting contract and immediately verifies that it is not stale.

If an existing contract has become stale, normal DKF stale-contract handling applies; the script does not silently overwrite it.

## Boundary

This script authorises only T01 Cost Observatory work. It does not authorise T02 or later v0.12 increments.
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
# phase04-workspace-target-engine-contract.mjs

## Purpose

`scripts/phase04-workspace-target-engine-contract.mjs` creates or reuses the Development Contract for **DKF120-T02 — Workspace Target Engine**.

The contract is persisted through the normal DKF runtime contract store under:

```text
.development-kit/contracts/INC-DKF120-T02/
```

That runtime directory remains git-ignored.

## Bootstrap note

T02 introduces Workspace Target Engine support itself.

Therefore the T02 Development Contract is created **without** a workspace target binding. This is intentional bootstrap behaviour: target binding cannot be mandatory for the increment that first creates the target engine.

After T02 acceptance, target-aware Development Contracts may bind:

- primary target;
- affected targets;
- verification targets;
- the exact workspace-registry fingerprint.

A later change to that registry then makes the target-aware contract stale.

## Authoritative sources

The contract binds:

- the v0.12 Scale, Context & Iteration specification;
- the v0.12 technical design;
- the validated v0.12 implementation PLAN;
- accepted T01 evidence;
- the Phase 0/1 multi-package baseline.

## Acceptance criteria

The T02 contract owns:

- `DKF-120-AC-004`
- `DKF-120-AC-005`
- `DKF-120-AC-006`
- `DKF-120-AC-007`
- `DKF-120-AC-039`

## Usage

```bash
node scripts/phase04-workspace-target-engine-contract.mjs
```

The script validates the contract, confirms its derived gates, and verifies that it is not stale.

## Boundary

This script authorises only T02 Workspace Target Engine work. It does not authorise T03 or later v0.12 increments.
77 changes: 77 additions & 0 deletions docs/03-reference/scripts/phase05-execution-capsule-contract.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,77 @@
# phase05-execution-capsule-contract.mjs

## Purpose

`scripts/phase05-execution-capsule-contract.mjs` creates or reuses the Development Contract for **DKF120-T03 — Execution Capsules & Context Cache**.

The contract is persisted through the normal DKF contract store under:

```text
.development-kit/contracts/INC-DKF120-T03/
```

The runtime contract directory remains git-ignored.

## Target binding

T03 is the first Scale, Context & Iteration increment that is created after the Workspace Target Engine is available.

Its Development Contract therefore binds:

```text
primary: dkf-framework
affected: dkf-framework
verification: dkf-framework
```

and stores the exact fingerprint of:

```text
.development-kit/workspace.json
```

If that registry changes after contract creation, the T03 contract becomes stale.

## Risk and derived gates

The validated PLAN classifies T03 as **High risk** because an incorrect cache hit could feed stale repository context into implementation or independent verification.

Under the current DKF gate selector, risk level 3 derives:

- specification verification;
- tests;
- code review;
- architecture review;
- security review;
- security control-domain review.

No human consequential-action approval is derived at risk level 3.

## Acceptance criteria

The T03 contract owns:

- `DKF-120-AC-008`
- `DKF-120-AC-009`
- `DKF-120-AC-010`
- `DKF-120-AC-011`
- `DKF-120-AC-035`

## Usage

```bash
node scripts/phase05-execution-capsule-contract.mjs
```

The script validates:

- the Development Contract;
- target binding;
- derived gates;
- contract staleness.

## Boundary

This script authorises only T03.

It does not authorise State Engine V2, Lifecycle Instances, discovery/re-entry, Gate Profiles, the Verification Extension SDK, Complexity Delta Guard, Control Center v0.12 integration, release publication, or a package-version change.
Loading
Loading