@devtrack-solution/codesdd 1.2.3 → 1.2.4-rc3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (139) hide show
  1. package/.sdd/skills/curated/devtrack-api/SKILL.md +12 -5
  2. package/.sdd/skills/curated/devtrack-api/agents/claude-code.yaml +8 -0
  3. package/.sdd/skills/curated/devtrack-api/agents/codex.yaml +8 -0
  4. package/.sdd/skills/curated/devtrack-api/agents/cursor.yaml +8 -0
  5. package/.sdd/skills/curated/devtrack-api/agents/gemini.yaml +8 -0
  6. package/.sdd/skills/curated/devtrack-api/agents/kimi.yaml +8 -0
  7. package/.sdd/skills/curated/devtrack-api/agents/openai.yaml +4 -2
  8. package/.sdd/skills/curated/devtrack-api/agents/opencode.yaml +10 -0
  9. package/.sdd/skills/curated/devtrack-api/references/application-presentation.md +2 -2
  10. package/.sdd/skills/curated/devtrack-api/references/contract-pack.yaml +55 -0
  11. package/.sdd/skills/curated/devtrack-api/references/domain-modeling.md +13 -13
  12. package/.sdd/skills/curated/devtrack-api/references/foundation-layout.md +2 -3
  13. package/.sdd/skills/curated/devtrack-api/references/implementation-checklist.md +1 -1
  14. package/.sdd/skills/curated/devtrack-api/references/portable-agent-contract.md +41 -0
  15. package/.sdd/skills/curated/devtrack-api/references/typeorm-infrastructure.md +7 -9
  16. package/README.md +159 -5
  17. package/dist/applications/sdd/index.d.ts +16 -0
  18. package/dist/applications/sdd/index.js +16 -0
  19. package/dist/commands/config.js +171 -10
  20. package/dist/commands/sdd/execution.js +345 -15
  21. package/dist/commands/sdd/plugin.js +5 -0
  22. package/dist/commands/sdd/shared.d.ts +1 -0
  23. package/dist/commands/sdd/shared.js +10 -0
  24. package/dist/commands/sdd.js +38 -3
  25. package/dist/core/cli/command-matrix.js +9 -0
  26. package/dist/core/cli-command-quality.js +9 -0
  27. package/dist/core/completions/command-registry.js +45 -0
  28. package/dist/core/config-schema.d.ts +18 -1
  29. package/dist/core/config-schema.js +48 -5
  30. package/dist/core/global-config.d.ts +16 -0
  31. package/dist/core/sdd/agent-binding.d.ts +10 -10
  32. package/dist/core/sdd/agent-runtime-contract.d.ts +204 -0
  33. package/dist/core/sdd/agent-runtime-contract.js +200 -0
  34. package/dist/core/sdd/check.d.ts +2 -0
  35. package/dist/core/sdd/check.js +40 -2
  36. package/dist/core/sdd/coordination/coordination-adapters.d.ts +15 -8
  37. package/dist/core/sdd/coordination/coordination-adapters.js +43 -15
  38. package/dist/core/sdd/coordination/index.d.ts +1 -0
  39. package/dist/core/sdd/coordination/index.js +1 -0
  40. package/dist/core/sdd/coordination/redis-runtime.d.ts +131 -0
  41. package/dist/core/sdd/coordination/redis-runtime.js +698 -0
  42. package/dist/core/sdd/deepagent-contracts.d.ts +98 -4
  43. package/dist/core/sdd/deepagent-contracts.js +62 -0
  44. package/dist/core/sdd/default-bootstrap-files.d.ts +2 -2
  45. package/dist/core/sdd/default-bootstrap-files.js +14 -8
  46. package/dist/core/sdd/default-skills.js +108 -4
  47. package/dist/core/sdd/devtrack-api-appliance.d.ts +8 -1
  48. package/dist/core/sdd/devtrack-api-appliance.js +46 -23
  49. package/dist/core/sdd/docs-sync.js +21 -15
  50. package/dist/core/sdd/domain/capability-diff.d.ts +63 -0
  51. package/dist/core/sdd/domain/capability-diff.js +200 -0
  52. package/dist/core/sdd/domain/change-safety-guardrails.d.ts +74 -0
  53. package/dist/core/sdd/domain/change-safety-guardrails.js +333 -0
  54. package/dist/core/sdd/domain/semantic-intent-classifier.d.ts +29 -0
  55. package/dist/core/sdd/domain/semantic-intent-classifier.js +117 -0
  56. package/dist/core/sdd/foundation-artifact-map-validator.d.ts +16 -0
  57. package/dist/core/sdd/foundation-artifact-map-validator.js +71 -0
  58. package/dist/core/sdd/foundation-layer-manifest.d.ts +24 -0
  59. package/dist/core/sdd/foundation-layer-manifest.js +117 -0
  60. package/dist/core/sdd/intent-guard.d.ts +22 -0
  61. package/dist/core/sdd/intent-guard.js +67 -0
  62. package/dist/core/sdd/json-schema.js +9 -1
  63. package/dist/core/sdd/legacy-operations.js +76 -1
  64. package/dist/core/sdd/migrate-workspace.js +39 -0
  65. package/dist/core/sdd/package-security-gates.d.ts +21 -0
  66. package/dist/core/sdd/package-security-gates.js +119 -0
  67. package/dist/core/sdd/package-structure-gate.js +3 -8
  68. package/dist/core/sdd/parallel-feat-automation.d.ts +181 -3
  69. package/dist/core/sdd/parallel-feat-automation.js +212 -0
  70. package/dist/core/sdd/plugin-broker.d.ts +223 -4
  71. package/dist/core/sdd/plugin-broker.js +10 -0
  72. package/dist/core/sdd/plugin-cli.d.ts +30 -0
  73. package/dist/core/sdd/plugin-cli.js +70 -3
  74. package/dist/core/sdd/plugin-evidence.d.ts +73 -0
  75. package/dist/core/sdd/plugin-manifest.d.ts +69 -1
  76. package/dist/core/sdd/plugin-manifest.js +10 -0
  77. package/dist/core/sdd/plugin-policy-pack.d.ts +1 -1
  78. package/dist/core/sdd/plugin-registry.d.ts +141 -5
  79. package/dist/core/sdd/plugin-sdk-contract.d.ts +363 -0
  80. package/dist/core/sdd/plugin-sdk-contract.js +268 -0
  81. package/dist/core/sdd/plugin-skill-binding.d.ts +1 -1
  82. package/dist/core/sdd/quality-validation.d.ts +84 -11
  83. package/dist/core/sdd/release-readiness.d.ts +19 -0
  84. package/dist/core/sdd/release-readiness.js +472 -0
  85. package/dist/core/sdd/runtime-boundary-contract.d.ts +45 -0
  86. package/dist/core/sdd/runtime-boundary-contract.js +90 -0
  87. package/dist/core/sdd/sdk-agent-plugin-quality-gates.d.ts +150 -0
  88. package/dist/core/sdd/sdk-agent-plugin-quality-gates.js +258 -0
  89. package/dist/core/sdd/services/agent-run.service.d.ts +38 -6
  90. package/dist/core/sdd/services/agent-run.service.js +73 -1
  91. package/dist/core/sdd/services/capability-diff.service.d.ts +18 -0
  92. package/dist/core/sdd/services/capability-diff.service.js +26 -0
  93. package/dist/core/sdd/services/change-safety-preflight.service.d.ts +17 -0
  94. package/dist/core/sdd/services/change-safety-preflight.service.js +17 -0
  95. package/dist/core/sdd/services/context.service.d.ts +43 -340
  96. package/dist/core/sdd/services/context.service.js +323 -9
  97. package/dist/core/sdd/services/finalize.service.d.ts +25 -0
  98. package/dist/core/sdd/services/finalize.service.js +178 -16
  99. package/dist/core/sdd/services/frontend-impact.service.d.ts +1 -1
  100. package/dist/core/sdd/services/semantic-intent-classifier.service.d.ts +6 -0
  101. package/dist/core/sdd/services/semantic-intent-classifier.service.js +7 -0
  102. package/dist/core/sdd/state.d.ts +1 -0
  103. package/dist/core/sdd/state.js +251 -29
  104. package/dist/core/sdd/store/sdd-stores.js +2 -2
  105. package/dist/core/sdd/structural-health.d.ts +13 -13
  106. package/dist/core/sdd/types.d.ts +27 -12
  107. package/dist/core/sdd/types.js +4 -0
  108. package/dist/core/sdd/views.js +17 -0
  109. package/dist/core/sdd/workspace-schemas.d.ts +387 -7
  110. package/dist/core/sdd/workspace-schemas.js +196 -64
  111. package/dist/domains/sdd/index.d.ts +6 -0
  112. package/dist/domains/sdd/index.js +6 -0
  113. package/dist/infrastructures/sdd/index.d.ts +7 -0
  114. package/dist/infrastructures/sdd/index.js +6 -0
  115. package/dist/presentations/cli/sdd/index.d.ts +3 -0
  116. package/dist/presentations/cli/sdd/index.js +3 -0
  117. package/dist/shared/sdd/index.d.ts +3 -0
  118. package/dist/shared/sdd/index.js +2 -0
  119. package/package.json +9 -6
  120. package/schemas/sdd/2-plan.schema.json +207 -2
  121. package/schemas/sdd/5-quality.schema.json +281 -25
  122. package/schemas/sdd/agent-runtime-command-plan.schema.json +212 -0
  123. package/schemas/sdd/agent-runtime-opencode-run-evidence.schema.json +270 -0
  124. package/schemas/sdd/codesdd-plugin.schema.json +171 -0
  125. package/schemas/sdd/deepagent-run-request.schema.json +316 -0
  126. package/schemas/sdd/parallel-feat-automation-plan.schema.json +89 -0
  127. package/schemas/sdd/parallel-feat-scheduler-request.schema.json +116 -0
  128. package/schemas/sdd/parallel-feat-scheduler-result.schema.json +404 -0
  129. package/schemas/sdd/plugin-artifact-manifest.schema.json +109 -0
  130. package/schemas/sdd/plugin-artifact-map.schema.json +223 -0
  131. package/schemas/sdd/plugin-evidence-manifest.schema.json +109 -0
  132. package/schemas/sdd/plugin-language-runtime.schema.json +103 -0
  133. package/schemas/sdd/plugin-package-governance.schema.json +74 -0
  134. package/schemas/sdd/plugin-registry.schema.json +171 -0
  135. package/schemas/sdd/plugin-runtime-invocation-plan.schema.json +109 -0
  136. package/schemas/sdd/quality-evidence-bundle.schema.json +109 -0
  137. package/schemas/sdd/sdk-agent-plugin-quality-gate-input.schema.json +168 -0
  138. package/schemas/sdd/sdk-agent-plugin-quality-gate-report.schema.json +160 -0
  139. package/schemas/sdd/workspace-catalog.schema.json +3776 -398
@@ -237,6 +237,205 @@
237
237
  "type": "string",
238
238
  "pattern": "^FEAT-\\d{4}$"
239
239
  },
240
+ "governance": {
241
+ "default": {
242
+ "state_boundary": "codesdd-canonical-sdd-state",
243
+ "planning_artifacts": [
244
+ ".sdd/state/backlog.yaml"
245
+ ],
246
+ "decision_refs": [],
247
+ "planned_state_writes": [],
248
+ "rollback_plan": "Review and revert only the scoped CodeSDD feature workspace and state changes if validation fails.",
249
+ "validation_gates": [
250
+ {
251
+ "name": "SDD check",
252
+ "command": "codesdd sdd check --render",
253
+ "expected": "CodeSDD state and generated views remain valid."
254
+ }
255
+ ]
256
+ },
257
+ "type": "object",
258
+ "properties": {
259
+ "state_boundary": {
260
+ "default": "codesdd-canonical-sdd-state",
261
+ "type": "string",
262
+ "const": "codesdd-canonical-sdd-state"
263
+ },
264
+ "planning_artifacts": {
265
+ "minItems": 1,
266
+ "type": "array",
267
+ "items": {
268
+ "type": "string",
269
+ "minLength": 1
270
+ }
271
+ },
272
+ "decision_refs": {
273
+ "default": [],
274
+ "type": "array",
275
+ "items": {
276
+ "type": "string",
277
+ "minLength": 1
278
+ }
279
+ },
280
+ "planned_state_writes": {
281
+ "default": [],
282
+ "type": "array",
283
+ "items": {
284
+ "type": "string",
285
+ "minLength": 1
286
+ }
287
+ },
288
+ "rollback_plan": {
289
+ "type": "string",
290
+ "minLength": 20
291
+ },
292
+ "validation_gates": {
293
+ "minItems": 1,
294
+ "type": "array",
295
+ "items": {
296
+ "type": "object",
297
+ "properties": {
298
+ "name": {
299
+ "type": "string",
300
+ "minLength": 1
301
+ },
302
+ "command": {
303
+ "type": "string",
304
+ "minLength": 1
305
+ },
306
+ "expected": {
307
+ "type": "string",
308
+ "minLength": 1
309
+ }
310
+ },
311
+ "required": [
312
+ "name",
313
+ "command",
314
+ "expected"
315
+ ],
316
+ "additionalProperties": false
317
+ }
318
+ }
319
+ },
320
+ "required": [
321
+ "state_boundary",
322
+ "planning_artifacts",
323
+ "decision_refs",
324
+ "planned_state_writes",
325
+ "rollback_plan",
326
+ "validation_gates"
327
+ ],
328
+ "additionalProperties": false
329
+ },
330
+ "execution_plan": {
331
+ "default": {
332
+ "mode": "single-feature",
333
+ "state_boundary_ref": "codesdd-canonical-sdd-state",
334
+ "command_sequence": [
335
+ {
336
+ "name": "SDD check",
337
+ "command": "codesdd sdd check --render",
338
+ "writes_state": false,
339
+ "expected_state_writes": []
340
+ }
341
+ ],
342
+ "allowed_state_writes": [],
343
+ "forbidden_state_writes": [
344
+ ".codesdd/**",
345
+ "external-context/**"
346
+ ],
347
+ "handoff_artifacts": []
348
+ },
349
+ "type": "object",
350
+ "properties": {
351
+ "mode": {
352
+ "default": "single-feature",
353
+ "type": "string",
354
+ "enum": [
355
+ "single-feature",
356
+ "parallel-wave",
357
+ "chained-features"
358
+ ]
359
+ },
360
+ "state_boundary_ref": {
361
+ "default": "codesdd-canonical-sdd-state",
362
+ "type": "string",
363
+ "const": "codesdd-canonical-sdd-state"
364
+ },
365
+ "command_sequence": {
366
+ "minItems": 1,
367
+ "type": "array",
368
+ "items": {
369
+ "type": "object",
370
+ "properties": {
371
+ "name": {
372
+ "type": "string",
373
+ "minLength": 1
374
+ },
375
+ "command": {
376
+ "type": "string",
377
+ "minLength": 1
378
+ },
379
+ "writes_state": {
380
+ "default": false,
381
+ "type": "boolean"
382
+ },
383
+ "expected_state_writes": {
384
+ "default": [],
385
+ "type": "array",
386
+ "items": {
387
+ "type": "string",
388
+ "minLength": 1
389
+ }
390
+ }
391
+ },
392
+ "required": [
393
+ "name",
394
+ "command",
395
+ "writes_state",
396
+ "expected_state_writes"
397
+ ],
398
+ "additionalProperties": false
399
+ }
400
+ },
401
+ "allowed_state_writes": {
402
+ "default": [],
403
+ "type": "array",
404
+ "items": {
405
+ "type": "string",
406
+ "minLength": 1
407
+ }
408
+ },
409
+ "forbidden_state_writes": {
410
+ "default": [
411
+ ".codesdd/**",
412
+ "external-context/**"
413
+ ],
414
+ "type": "array",
415
+ "items": {
416
+ "type": "string",
417
+ "minLength": 1
418
+ }
419
+ },
420
+ "handoff_artifacts": {
421
+ "default": [],
422
+ "type": "array",
423
+ "items": {
424
+ "type": "string",
425
+ "minLength": 1
426
+ }
427
+ }
428
+ },
429
+ "required": [
430
+ "mode",
431
+ "state_boundary_ref",
432
+ "command_sequence",
433
+ "allowed_state_writes",
434
+ "forbidden_state_writes",
435
+ "handoff_artifacts"
436
+ ],
437
+ "additionalProperties": false
438
+ },
240
439
  "architectural_impact": {
241
440
  "type": "object",
242
441
  "properties": {
@@ -300,10 +499,14 @@
300
499
  "type": "object",
301
500
  "properties": {
302
501
  "unit_target": {
303
- "type": "number"
502
+ "type": "number",
503
+ "minimum": 0,
504
+ "maximum": 100
304
505
  },
305
506
  "integration_target": {
306
- "type": "number"
507
+ "type": "number",
508
+ "minimum": 0,
509
+ "maximum": 100
307
510
  },
308
511
  "approach": {
309
512
  "type": "string"
@@ -486,6 +689,8 @@
486
689
  "required": [
487
690
  "schema_version",
488
691
  "feature_id",
692
+ "governance",
693
+ "execution_plan",
489
694
  "architectural_impact",
490
695
  "frontend_impact",
491
696
  "affected_contracts",
@@ -741,10 +946,14 @@
741
946
  "type": "object",
742
947
  "properties": {
743
948
  "unit": {
744
- "type": "number"
949
+ "type": "number",
950
+ "minimum": 0,
951
+ "maximum": 100
745
952
  },
746
953
  "integration": {
747
- "type": "number"
954
+ "type": "number",
955
+ "minimum": 0,
956
+ "maximum": 100
748
957
  },
749
958
  "modules": {
750
959
  "type": "object",
@@ -752,7 +961,9 @@
752
961
  "type": "string"
753
962
  },
754
963
  "additionalProperties": {
755
- "type": "number"
964
+ "type": "number",
965
+ "minimum": 0,
966
+ "maximum": 100
756
967
  }
757
968
  }
758
969
  },
@@ -1312,110 +1523,333 @@
1312
1523
  ],
1313
1524
  "additionalProperties": false
1314
1525
  },
1315
- "q95_ledger": {
1526
+ "token_budget_gates": {
1316
1527
  "default": {
1317
- "threshold": 95,
1318
- "score": 0,
1319
- "status": "pending",
1320
- "computed_at": "",
1321
- "weights": {
1322
- "coverage": 30,
1323
- "traceability": 20,
1324
- "integrity": 20,
1325
- "naming": 10,
1326
- "token": 20
1327
- },
1328
- "axes": {
1329
- "coverage": {
1330
- "raw_score": 0,
1331
- "weighted_score": 0,
1332
- "rationale": "Computed during finalize."
1333
- },
1334
- "traceability": {
1335
- "raw_score": 0,
1336
- "weighted_score": 0,
1337
- "rationale": "Computed during finalize."
1338
- },
1339
- "integrity": {
1340
- "raw_score": 0,
1341
- "weighted_score": 0,
1342
- "rationale": "Computed during finalize."
1343
- },
1344
- "naming": {
1345
- "raw_score": 0,
1346
- "weighted_score": 0,
1347
- "rationale": "Computed during finalize."
1348
- },
1349
- "token": {
1350
- "raw_score": 0,
1351
- "weighted_score": 0,
1352
- "rationale": "Computed during finalize."
1353
- }
1354
- },
1355
- "next_best_action": "Record missing evidence to raise the lowest weighted axis."
1528
+ "require_numeric_efficiency": true,
1529
+ "fail_below_percent": 95,
1530
+ "telemetry": []
1356
1531
  },
1357
1532
  "type": "object",
1358
1533
  "properties": {
1359
- "threshold": {
1360
- "default": 95,
1361
- "type": "number"
1362
- },
1363
- "score": {
1364
- "default": 0,
1365
- "type": "number"
1534
+ "max_context_chars": {
1535
+ "type": "integer",
1536
+ "exclusiveMinimum": 0,
1537
+ "maximum": 9007199254740991
1366
1538
  },
1367
- "status": {
1368
- "default": "pending",
1369
- "type": "string",
1370
- "enum": [
1371
- "pass",
1372
- "fail",
1373
- "pending"
1374
- ]
1539
+ "require_numeric_efficiency": {
1540
+ "default": true,
1541
+ "type": "boolean"
1375
1542
  },
1376
- "computed_at": {
1377
- "default": "",
1378
- "type": "string"
1543
+ "fail_below_percent": {
1544
+ "default": 95,
1545
+ "type": "number",
1546
+ "minimum": 0,
1547
+ "maximum": 100
1379
1548
  },
1380
- "weights": {
1381
- "default": {
1382
- "coverage": 30,
1383
- "traceability": 20,
1384
- "integrity": 20,
1385
- "naming": 10,
1386
- "token": 20
1387
- },
1388
- "type": "object",
1389
- "properties": {
1390
- "coverage": {
1391
- "default": 30,
1392
- "type": "number"
1393
- },
1394
- "traceability": {
1395
- "default": 20,
1396
- "type": "number"
1397
- },
1398
- "integrity": {
1399
- "default": 20,
1400
- "type": "number"
1401
- },
1402
- "naming": {
1403
- "default": 10,
1404
- "type": "number"
1405
- },
1406
- "token": {
1407
- "default": 20,
1408
- "type": "number"
1409
- }
1410
- },
1411
- "required": [
1412
- "coverage",
1413
- "traceability",
1414
- "integrity",
1415
- "naming",
1416
- "token"
1417
- ],
1418
- "additionalProperties": false
1549
+ "telemetry": {
1550
+ "default": [],
1551
+ "type": "array",
1552
+ "items": {
1553
+ "type": "object",
1554
+ "properties": {
1555
+ "mode": {
1556
+ "type": "string",
1557
+ "enum": [
1558
+ "compact",
1559
+ "standard",
1560
+ "full"
1561
+ ]
1562
+ },
1563
+ "budget_chars": {
1564
+ "type": "integer",
1565
+ "exclusiveMinimum": 0,
1566
+ "maximum": 9007199254740991
1567
+ },
1568
+ "actual_chars": {
1569
+ "type": "integer",
1570
+ "minimum": 0,
1571
+ "maximum": 9007199254740991
1572
+ },
1573
+ "efficiency_percent": {
1574
+ "type": "number",
1575
+ "minimum": 0,
1576
+ "maximum": 100
1577
+ },
1578
+ "gate": {
1579
+ "default": "pass",
1580
+ "type": "string",
1581
+ "enum": [
1582
+ "pass",
1583
+ "warn",
1584
+ "fail"
1585
+ ]
1586
+ },
1587
+ "evidence_ref": {
1588
+ "type": "string",
1589
+ "minLength": 1
1590
+ },
1591
+ "notes": {
1592
+ "type": "string"
1593
+ }
1594
+ },
1595
+ "required": [
1596
+ "gate"
1597
+ ],
1598
+ "additionalProperties": false
1599
+ }
1600
+ }
1601
+ },
1602
+ "required": [
1603
+ "require_numeric_efficiency",
1604
+ "fail_below_percent",
1605
+ "telemetry"
1606
+ ],
1607
+ "additionalProperties": false
1608
+ },
1609
+ "runtime_quality_gates": {
1610
+ "default": {
1611
+ "mode": "observe",
1612
+ "performance": [],
1613
+ "flakiness": []
1614
+ },
1615
+ "type": "object",
1616
+ "properties": {
1617
+ "mode": {
1618
+ "default": "observe",
1619
+ "type": "string",
1620
+ "enum": [
1621
+ "observe",
1622
+ "enforce"
1623
+ ]
1624
+ },
1625
+ "performance": {
1626
+ "default": [],
1627
+ "type": "array",
1628
+ "items": {
1629
+ "type": "object",
1630
+ "properties": {
1631
+ "command": {
1632
+ "type": "string",
1633
+ "minLength": 1
1634
+ },
1635
+ "metric": {
1636
+ "default": "duration_ms",
1637
+ "type": "string",
1638
+ "enum": [
1639
+ "duration_ms",
1640
+ "p95_ms",
1641
+ "memory_mb",
1642
+ "cpu_percent"
1643
+ ]
1644
+ },
1645
+ "threshold": {
1646
+ "type": "number",
1647
+ "minimum": 0
1648
+ },
1649
+ "actual": {
1650
+ "type": "number",
1651
+ "minimum": 0
1652
+ },
1653
+ "gate": {
1654
+ "default": "pass",
1655
+ "type": "string",
1656
+ "enum": [
1657
+ "pass",
1658
+ "warn",
1659
+ "fail"
1660
+ ]
1661
+ },
1662
+ "evidence_ref": {
1663
+ "type": "string",
1664
+ "minLength": 1
1665
+ },
1666
+ "notes": {
1667
+ "type": "string"
1668
+ }
1669
+ },
1670
+ "required": [
1671
+ "command",
1672
+ "metric",
1673
+ "gate"
1674
+ ],
1675
+ "additionalProperties": false
1676
+ }
1677
+ },
1678
+ "flakiness": {
1679
+ "default": [],
1680
+ "type": "array",
1681
+ "items": {
1682
+ "type": "object",
1683
+ "properties": {
1684
+ "command": {
1685
+ "type": "string",
1686
+ "minLength": 1
1687
+ },
1688
+ "attempts": {
1689
+ "type": "integer",
1690
+ "exclusiveMinimum": 0,
1691
+ "maximum": 9007199254740991
1692
+ },
1693
+ "failures": {
1694
+ "type": "integer",
1695
+ "minimum": 0,
1696
+ "maximum": 9007199254740991
1697
+ },
1698
+ "failure_rate_percent": {
1699
+ "type": "number",
1700
+ "minimum": 0,
1701
+ "maximum": 100
1702
+ },
1703
+ "gate": {
1704
+ "default": "pass",
1705
+ "type": "string",
1706
+ "enum": [
1707
+ "pass",
1708
+ "warn",
1709
+ "fail"
1710
+ ]
1711
+ },
1712
+ "evidence_ref": {
1713
+ "type": "string",
1714
+ "minLength": 1
1715
+ },
1716
+ "notes": {
1717
+ "type": "string"
1718
+ }
1719
+ },
1720
+ "required": [
1721
+ "command",
1722
+ "gate"
1723
+ ],
1724
+ "additionalProperties": false
1725
+ }
1726
+ }
1727
+ },
1728
+ "required": [
1729
+ "mode",
1730
+ "performance",
1731
+ "flakiness"
1732
+ ],
1733
+ "additionalProperties": false
1734
+ },
1735
+ "q95_ledger": {
1736
+ "default": {
1737
+ "threshold": 95,
1738
+ "score": 0,
1739
+ "status": "pending",
1740
+ "computed_at": "",
1741
+ "weights": {
1742
+ "coverage": 30,
1743
+ "traceability": 20,
1744
+ "integrity": 20,
1745
+ "naming": 10,
1746
+ "token": 20
1747
+ },
1748
+ "axes": {
1749
+ "coverage": {
1750
+ "raw_score": 0,
1751
+ "weighted_score": 0,
1752
+ "rationale": "Computed during finalize."
1753
+ },
1754
+ "traceability": {
1755
+ "raw_score": 0,
1756
+ "weighted_score": 0,
1757
+ "rationale": "Computed during finalize."
1758
+ },
1759
+ "integrity": {
1760
+ "raw_score": 0,
1761
+ "weighted_score": 0,
1762
+ "rationale": "Computed during finalize."
1763
+ },
1764
+ "naming": {
1765
+ "raw_score": 0,
1766
+ "weighted_score": 0,
1767
+ "rationale": "Computed during finalize."
1768
+ },
1769
+ "token": {
1770
+ "raw_score": 0,
1771
+ "weighted_score": 0,
1772
+ "rationale": "Computed during finalize."
1773
+ }
1774
+ },
1775
+ "next_best_action": "Record missing evidence to raise the lowest weighted axis."
1776
+ },
1777
+ "type": "object",
1778
+ "properties": {
1779
+ "threshold": {
1780
+ "default": 95,
1781
+ "type": "number",
1782
+ "minimum": 0,
1783
+ "maximum": 100
1784
+ },
1785
+ "score": {
1786
+ "default": 0,
1787
+ "type": "number",
1788
+ "minimum": 0,
1789
+ "maximum": 100
1790
+ },
1791
+ "status": {
1792
+ "default": "pending",
1793
+ "type": "string",
1794
+ "enum": [
1795
+ "pass",
1796
+ "fail",
1797
+ "pending"
1798
+ ]
1799
+ },
1800
+ "computed_at": {
1801
+ "default": "",
1802
+ "type": "string"
1803
+ },
1804
+ "weights": {
1805
+ "default": {
1806
+ "coverage": 30,
1807
+ "traceability": 20,
1808
+ "integrity": 20,
1809
+ "naming": 10,
1810
+ "token": 20
1811
+ },
1812
+ "type": "object",
1813
+ "properties": {
1814
+ "coverage": {
1815
+ "default": 30,
1816
+ "type": "number",
1817
+ "minimum": 0,
1818
+ "maximum": 100
1819
+ },
1820
+ "traceability": {
1821
+ "default": 20,
1822
+ "type": "number",
1823
+ "minimum": 0,
1824
+ "maximum": 100
1825
+ },
1826
+ "integrity": {
1827
+ "default": 20,
1828
+ "type": "number",
1829
+ "minimum": 0,
1830
+ "maximum": 100
1831
+ },
1832
+ "naming": {
1833
+ "default": 10,
1834
+ "type": "number",
1835
+ "minimum": 0,
1836
+ "maximum": 100
1837
+ },
1838
+ "token": {
1839
+ "default": 20,
1840
+ "type": "number",
1841
+ "minimum": 0,
1842
+ "maximum": 100
1843
+ }
1844
+ },
1845
+ "required": [
1846
+ "coverage",
1847
+ "traceability",
1848
+ "integrity",
1849
+ "naming",
1850
+ "token"
1851
+ ],
1852
+ "additionalProperties": false
1419
1853
  },
1420
1854
  "axes": {
1421
1855
  "default": {
@@ -1451,13 +1885,18 @@
1451
1885
  "type": "object",
1452
1886
  "properties": {
1453
1887
  "raw_score": {
1454
- "type": "number"
1888
+ "type": "number",
1889
+ "minimum": 0,
1890
+ "maximum": 100
1455
1891
  },
1456
1892
  "weighted_score": {
1457
- "type": "number"
1893
+ "type": "number",
1894
+ "minimum": 0,
1895
+ "maximum": 100
1458
1896
  },
1459
1897
  "rationale": {
1460
- "type": "string"
1898
+ "type": "string",
1899
+ "minLength": 1
1461
1900
  }
1462
1901
  },
1463
1902
  "required": [
@@ -1471,13 +1910,18 @@
1471
1910
  "type": "object",
1472
1911
  "properties": {
1473
1912
  "raw_score": {
1474
- "type": "number"
1913
+ "type": "number",
1914
+ "minimum": 0,
1915
+ "maximum": 100
1475
1916
  },
1476
1917
  "weighted_score": {
1477
- "type": "number"
1918
+ "type": "number",
1919
+ "minimum": 0,
1920
+ "maximum": 100
1478
1921
  },
1479
1922
  "rationale": {
1480
- "type": "string"
1923
+ "type": "string",
1924
+ "minLength": 1
1481
1925
  }
1482
1926
  },
1483
1927
  "required": [
@@ -1491,13 +1935,18 @@
1491
1935
  "type": "object",
1492
1936
  "properties": {
1493
1937
  "raw_score": {
1494
- "type": "number"
1938
+ "type": "number",
1939
+ "minimum": 0,
1940
+ "maximum": 100
1495
1941
  },
1496
1942
  "weighted_score": {
1497
- "type": "number"
1943
+ "type": "number",
1944
+ "minimum": 0,
1945
+ "maximum": 100
1498
1946
  },
1499
1947
  "rationale": {
1500
- "type": "string"
1948
+ "type": "string",
1949
+ "minLength": 1
1501
1950
  }
1502
1951
  },
1503
1952
  "required": [
@@ -1511,13 +1960,18 @@
1511
1960
  "type": "object",
1512
1961
  "properties": {
1513
1962
  "raw_score": {
1514
- "type": "number"
1963
+ "type": "number",
1964
+ "minimum": 0,
1965
+ "maximum": 100
1515
1966
  },
1516
1967
  "weighted_score": {
1517
- "type": "number"
1968
+ "type": "number",
1969
+ "minimum": 0,
1970
+ "maximum": 100
1518
1971
  },
1519
1972
  "rationale": {
1520
- "type": "string"
1973
+ "type": "string",
1974
+ "minLength": 1
1521
1975
  }
1522
1976
  },
1523
1977
  "required": [
@@ -1531,13 +1985,18 @@
1531
1985
  "type": "object",
1532
1986
  "properties": {
1533
1987
  "raw_score": {
1534
- "type": "number"
1988
+ "type": "number",
1989
+ "minimum": 0,
1990
+ "maximum": 100
1535
1991
  },
1536
1992
  "weighted_score": {
1537
- "type": "number"
1993
+ "type": "number",
1994
+ "minimum": 0,
1995
+ "maximum": 100
1538
1996
  },
1539
1997
  "rationale": {
1540
- "type": "string"
1998
+ "type": "string",
1999
+ "minLength": 1
1541
2000
  }
1542
2001
  },
1543
2002
  "required": [
@@ -1586,6 +2045,8 @@
1586
2045
  "exceptions",
1587
2046
  "remediation_policy",
1588
2047
  "traceability",
2048
+ "token_budget_gates",
2049
+ "runtime_quality_gates",
1589
2050
  "q95_ledger"
1590
2051
  ],
1591
2052
  "additionalProperties": false,
@@ -1674,6 +2135,177 @@
1674
2135
  ],
1675
2136
  "additionalProperties": false
1676
2137
  },
2138
+ "package_governance": {
2139
+ "type": "object",
2140
+ "properties": {
2141
+ "package_name": {
2142
+ "type": "string",
2143
+ "pattern": "^@devtrack-solution\\/codesdd-plugin-[a-z0-9][a-z0-9-]*$"
2144
+ },
2145
+ "sdk_package": {
2146
+ "default": "@devtrack-solution/codesdd-plugin-sdk",
2147
+ "type": "string",
2148
+ "pattern": "^@devtrack-solution\\/codesdd-plugin-sdk$"
2149
+ },
2150
+ "sdk_version": {
2151
+ "default": "*",
2152
+ "type": "string",
2153
+ "pattern": "^(?:[~^]?\\d+\\.\\d+\\.\\d+(?:[-+][0-9A-Za-z.-]+)?|[<>]=?\\d+\\.\\d+\\.\\d+(?:\\s+<\\d+\\.\\d+\\.\\d+)?|\\*)$"
2154
+ },
2155
+ "package_kind": {
2156
+ "type": "string",
2157
+ "enum": [
2158
+ "frontend",
2159
+ "backend",
2160
+ "full-stack",
2161
+ "generator",
2162
+ "validator",
2163
+ "evidence",
2164
+ "agent-adapter",
2165
+ "policy-pack"
2166
+ ]
2167
+ },
2168
+ "versioning": {
2169
+ "default": "semver",
2170
+ "type": "string",
2171
+ "const": "semver"
2172
+ },
2173
+ "registry": {
2174
+ "default": "workspace",
2175
+ "type": "string",
2176
+ "enum": [
2177
+ "workspace",
2178
+ "npm",
2179
+ "private-npm",
2180
+ "artifact-registry",
2181
+ "custom"
2182
+ ]
2183
+ },
2184
+ "keywords": {
2185
+ "default": [],
2186
+ "type": "array",
2187
+ "items": {
2188
+ "type": "string",
2189
+ "minLength": 1
2190
+ }
2191
+ },
2192
+ "internal_package": {
2193
+ "default": false,
2194
+ "type": "boolean"
2195
+ }
2196
+ },
2197
+ "required": [
2198
+ "package_name",
2199
+ "sdk_package",
2200
+ "sdk_version",
2201
+ "package_kind",
2202
+ "versioning",
2203
+ "registry",
2204
+ "keywords",
2205
+ "internal_package"
2206
+ ],
2207
+ "additionalProperties": false
2208
+ },
2209
+ "language_runtime": {
2210
+ "type": "object",
2211
+ "properties": {
2212
+ "language": {
2213
+ "type": "string",
2214
+ "enum": [
2215
+ "typescript",
2216
+ "javascript",
2217
+ "python",
2218
+ "java",
2219
+ "go",
2220
+ "rust",
2221
+ "csharp",
2222
+ "php",
2223
+ "ruby",
2224
+ "shell",
2225
+ "other"
2226
+ ]
2227
+ },
2228
+ "runtime": {
2229
+ "type": "string",
2230
+ "minLength": 1
2231
+ },
2232
+ "bridge": {
2233
+ "type": "string",
2234
+ "enum": [
2235
+ "node-library",
2236
+ "stdio-json",
2237
+ "process-cli",
2238
+ "http-local",
2239
+ "container",
2240
+ "wasm"
2241
+ ]
2242
+ },
2243
+ "input_transport": {
2244
+ "type": "string",
2245
+ "enum": [
2246
+ "sdk-call",
2247
+ "stdin-json",
2248
+ "stdout-json",
2249
+ "file-envelope",
2250
+ "http-json"
2251
+ ]
2252
+ },
2253
+ "output_transport": {
2254
+ "type": "string",
2255
+ "enum": [
2256
+ "sdk-call",
2257
+ "stdin-json",
2258
+ "stdout-json",
2259
+ "file-envelope",
2260
+ "http-json"
2261
+ ]
2262
+ },
2263
+ "command": {
2264
+ "type": "string",
2265
+ "minLength": 1
2266
+ },
2267
+ "args": {
2268
+ "default": [],
2269
+ "type": "array",
2270
+ "items": {
2271
+ "type": "string"
2272
+ }
2273
+ },
2274
+ "package_manager": {
2275
+ "type": "string",
2276
+ "minLength": 1
2277
+ },
2278
+ "min_versions": {
2279
+ "default": {},
2280
+ "type": "object",
2281
+ "propertyNames": {
2282
+ "type": "string"
2283
+ },
2284
+ "additionalProperties": {
2285
+ "type": "string"
2286
+ }
2287
+ },
2288
+ "env_allowlist": {
2289
+ "default": [],
2290
+ "type": "array",
2291
+ "items": {
2292
+ "type": "string",
2293
+ "pattern": "^[A-Z_][A-Z0-9_]*$"
2294
+ }
2295
+ }
2296
+ },
2297
+ "required": [
2298
+ "language",
2299
+ "runtime",
2300
+ "bridge",
2301
+ "input_transport",
2302
+ "output_transport",
2303
+ "args",
2304
+ "min_versions",
2305
+ "env_allowlist"
2306
+ ],
2307
+ "additionalProperties": false
2308
+ },
1677
2309
  "capabilities": {
1678
2310
  "minItems": 1,
1679
2311
  "type": "array",
@@ -2069,8 +2701,185 @@
2069
2701
  "description": "Machine-readable contract for a CodeSDD enterprise plugin manifest."
2070
2702
  }
2071
2703
  },
2072
- "plugin_registries": {
2073
- "plugin-registry.yaml": {
2704
+ "plugin_sdk_contracts": {
2705
+ "plugin-package-governance.yaml": {
2706
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
2707
+ "type": "object",
2708
+ "properties": {
2709
+ "package_name": {
2710
+ "type": "string",
2711
+ "pattern": "^@devtrack-solution\\/codesdd-plugin-[a-z0-9][a-z0-9-]*$"
2712
+ },
2713
+ "sdk_package": {
2714
+ "default": "@devtrack-solution/codesdd-plugin-sdk",
2715
+ "type": "string",
2716
+ "pattern": "^@devtrack-solution\\/codesdd-plugin-sdk$"
2717
+ },
2718
+ "sdk_version": {
2719
+ "default": "*",
2720
+ "type": "string",
2721
+ "pattern": "^(?:[~^]?\\d+\\.\\d+\\.\\d+(?:[-+][0-9A-Za-z.-]+)?|[<>]=?\\d+\\.\\d+\\.\\d+(?:\\s+<\\d+\\.\\d+\\.\\d+)?|\\*)$"
2722
+ },
2723
+ "package_kind": {
2724
+ "type": "string",
2725
+ "enum": [
2726
+ "frontend",
2727
+ "backend",
2728
+ "full-stack",
2729
+ "generator",
2730
+ "validator",
2731
+ "evidence",
2732
+ "agent-adapter",
2733
+ "policy-pack"
2734
+ ]
2735
+ },
2736
+ "versioning": {
2737
+ "default": "semver",
2738
+ "type": "string",
2739
+ "const": "semver"
2740
+ },
2741
+ "registry": {
2742
+ "default": "workspace",
2743
+ "type": "string",
2744
+ "enum": [
2745
+ "workspace",
2746
+ "npm",
2747
+ "private-npm",
2748
+ "artifact-registry",
2749
+ "custom"
2750
+ ]
2751
+ },
2752
+ "keywords": {
2753
+ "default": [],
2754
+ "type": "array",
2755
+ "items": {
2756
+ "type": "string",
2757
+ "minLength": 1
2758
+ }
2759
+ },
2760
+ "internal_package": {
2761
+ "default": false,
2762
+ "type": "boolean"
2763
+ }
2764
+ },
2765
+ "required": [
2766
+ "package_name",
2767
+ "sdk_package",
2768
+ "sdk_version",
2769
+ "package_kind",
2770
+ "versioning",
2771
+ "registry",
2772
+ "keywords",
2773
+ "internal_package"
2774
+ ],
2775
+ "additionalProperties": false,
2776
+ "title": "CodeSDD Plugin SDK Package Governance",
2777
+ "description": "Package naming, versioning, registry, and keyword contract for @devtrack-solution/codesdd-plugin-sdk plugin packages."
2778
+ },
2779
+ "plugin-language-runtime.yaml": {
2780
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
2781
+ "type": "object",
2782
+ "properties": {
2783
+ "language": {
2784
+ "type": "string",
2785
+ "enum": [
2786
+ "typescript",
2787
+ "javascript",
2788
+ "python",
2789
+ "java",
2790
+ "go",
2791
+ "rust",
2792
+ "csharp",
2793
+ "php",
2794
+ "ruby",
2795
+ "shell",
2796
+ "other"
2797
+ ]
2798
+ },
2799
+ "runtime": {
2800
+ "type": "string",
2801
+ "minLength": 1
2802
+ },
2803
+ "bridge": {
2804
+ "type": "string",
2805
+ "enum": [
2806
+ "node-library",
2807
+ "stdio-json",
2808
+ "process-cli",
2809
+ "http-local",
2810
+ "container",
2811
+ "wasm"
2812
+ ]
2813
+ },
2814
+ "input_transport": {
2815
+ "type": "string",
2816
+ "enum": [
2817
+ "sdk-call",
2818
+ "stdin-json",
2819
+ "stdout-json",
2820
+ "file-envelope",
2821
+ "http-json"
2822
+ ]
2823
+ },
2824
+ "output_transport": {
2825
+ "type": "string",
2826
+ "enum": [
2827
+ "sdk-call",
2828
+ "stdin-json",
2829
+ "stdout-json",
2830
+ "file-envelope",
2831
+ "http-json"
2832
+ ]
2833
+ },
2834
+ "command": {
2835
+ "type": "string",
2836
+ "minLength": 1
2837
+ },
2838
+ "args": {
2839
+ "default": [],
2840
+ "type": "array",
2841
+ "items": {
2842
+ "type": "string"
2843
+ }
2844
+ },
2845
+ "package_manager": {
2846
+ "type": "string",
2847
+ "minLength": 1
2848
+ },
2849
+ "min_versions": {
2850
+ "default": {},
2851
+ "type": "object",
2852
+ "propertyNames": {
2853
+ "type": "string"
2854
+ },
2855
+ "additionalProperties": {
2856
+ "type": "string"
2857
+ }
2858
+ },
2859
+ "env_allowlist": {
2860
+ "default": [],
2861
+ "type": "array",
2862
+ "items": {
2863
+ "type": "string",
2864
+ "pattern": "^[A-Z_][A-Z0-9_]*$"
2865
+ }
2866
+ }
2867
+ },
2868
+ "required": [
2869
+ "language",
2870
+ "runtime",
2871
+ "bridge",
2872
+ "input_transport",
2873
+ "output_transport",
2874
+ "args",
2875
+ "min_versions",
2876
+ "env_allowlist"
2877
+ ],
2878
+ "additionalProperties": false,
2879
+ "title": "CodeSDD Plugin SDK Language Runtime",
2880
+ "description": "Language-agnostic runtime bridge contract for TypeScript, JavaScript, Python, Java, Go, Rust, C#, shell, and custom plugin implementations."
2881
+ },
2882
+ "plugin-artifact-map.yaml": {
2074
2883
  "$schema": "https://json-schema.org/draft/2020-12/schema",
2075
2884
  "type": "object",
2076
2885
  "properties": {
@@ -2078,29 +2887,254 @@
2078
2887
  "type": "number",
2079
2888
  "const": 1
2080
2889
  },
2890
+ "sdk_package": {
2891
+ "default": "@devtrack-solution/codesdd-plugin-sdk",
2892
+ "type": "string",
2893
+ "const": "@devtrack-solution/codesdd-plugin-sdk"
2894
+ },
2895
+ "feature_ref": {
2896
+ "type": "string",
2897
+ "pattern": "^FEAT-\\d{4}$"
2898
+ },
2899
+ "operation_id": {
2900
+ "type": "string",
2901
+ "pattern": "^[a-z0-9][a-z0-9-]*$"
2902
+ },
2903
+ "plugin_ref": {
2904
+ "type": "object",
2905
+ "properties": {
2906
+ "id": {
2907
+ "type": "string",
2908
+ "minLength": 1
2909
+ },
2910
+ "version": {
2911
+ "type": "string",
2912
+ "pattern": "^\\d+\\.\\d+\\.\\d+(?:[-+][0-9A-Za-z.-]+)?$"
2913
+ }
2914
+ },
2915
+ "required": [
2916
+ "id",
2917
+ "version"
2918
+ ],
2919
+ "additionalProperties": false
2920
+ },
2081
2921
  "generated_at": {
2082
2922
  "type": "string",
2083
2923
  "format": "date-time",
2084
2924
  "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
2085
2925
  },
2086
- "entries": {
2926
+ "artifacts": {
2087
2927
  "default": [],
2088
2928
  "type": "array",
2089
2929
  "items": {
2090
2930
  "type": "object",
2091
2931
  "properties": {
2092
- "manifest": {
2093
- "type": "object",
2094
- "properties": {
2095
- "id": {
2096
- "type": "string",
2097
- "pattern": "^codesdd-plugin-[a-z0-9][a-z0-9-]*$"
2098
- },
2099
- "name": {
2100
- "type": "string",
2101
- "minLength": 3
2102
- },
2103
- "version": {
2932
+ "path": {
2933
+ "type": "string",
2934
+ "pattern": "^(?!\\/)(?![A-Za-z]:[\\\\/])(?!.*(?:^|[\\\\/])\\.\\.(?:[\\\\/]|$)).+$"
2935
+ },
2936
+ "operation": {
2937
+ "type": "string",
2938
+ "enum": [
2939
+ "planned",
2940
+ "created",
2941
+ "modified",
2942
+ "deleted",
2943
+ "unchanged",
2944
+ "validated"
2945
+ ]
2946
+ },
2947
+ "artifact_kind": {
2948
+ "type": "string",
2949
+ "enum": [
2950
+ "source",
2951
+ "test",
2952
+ "documentation",
2953
+ "configuration",
2954
+ "schema",
2955
+ "evidence",
2956
+ "migration",
2957
+ "asset",
2958
+ "package-metadata"
2959
+ ]
2960
+ },
2961
+ "role": {
2962
+ "type": "string",
2963
+ "enum": [
2964
+ "interface",
2965
+ "type",
2966
+ "implementation",
2967
+ "abstraction",
2968
+ "business-object",
2969
+ "value-object",
2970
+ "entity",
2971
+ "repository-port",
2972
+ "use-case",
2973
+ "service",
2974
+ "handler",
2975
+ "adapter",
2976
+ "mapper",
2977
+ "module",
2978
+ "controller",
2979
+ "dto",
2980
+ "validator",
2981
+ "policy",
2982
+ "manifest",
2983
+ "fixture",
2984
+ "test",
2985
+ "documentation",
2986
+ "evidence"
2987
+ ]
2988
+ },
2989
+ "layer": {
2990
+ "type": "string",
2991
+ "enum": [
2992
+ "root",
2993
+ "domain",
2994
+ "application",
2995
+ "infrastructure",
2996
+ "presentation",
2997
+ "shared",
2998
+ "tests",
2999
+ "docs",
3000
+ "sdd",
3001
+ "config",
3002
+ "assets"
3003
+ ]
3004
+ },
3005
+ "content_type": {
3006
+ "type": "string",
3007
+ "minLength": 1
3008
+ },
3009
+ "reason": {
3010
+ "type": "string",
3011
+ "minLength": 1
3012
+ },
3013
+ "language": {
3014
+ "type": "string",
3015
+ "enum": [
3016
+ "typescript",
3017
+ "javascript",
3018
+ "python",
3019
+ "java",
3020
+ "go",
3021
+ "rust",
3022
+ "csharp",
3023
+ "php",
3024
+ "ruby",
3025
+ "shell",
3026
+ "other"
3027
+ ]
3028
+ },
3029
+ "context": {
3030
+ "type": "string",
3031
+ "minLength": 1
3032
+ },
3033
+ "implementation": {
3034
+ "default": "manual",
3035
+ "type": "string",
3036
+ "enum": [
3037
+ "concrete",
3038
+ "abstract",
3039
+ "contract",
3040
+ "generated",
3041
+ "manual"
3042
+ ]
3043
+ },
3044
+ "decision_refs": {
3045
+ "default": [],
3046
+ "type": "array",
3047
+ "items": {
3048
+ "type": "string",
3049
+ "pattern": "^(?:ADR|DEB|EPIC|FEAT|INS)-\\d{4}$"
3050
+ }
3051
+ },
3052
+ "source_refs": {
3053
+ "default": [],
3054
+ "type": "array",
3055
+ "items": {
3056
+ "type": "string",
3057
+ "minLength": 1
3058
+ }
3059
+ },
3060
+ "tags": {
3061
+ "default": [],
3062
+ "type": "array",
3063
+ "items": {
3064
+ "type": "string",
3065
+ "minLength": 1
3066
+ }
3067
+ },
3068
+ "metadata": {
3069
+ "default": {},
3070
+ "type": "object",
3071
+ "propertyNames": {
3072
+ "type": "string"
3073
+ },
3074
+ "additionalProperties": {}
3075
+ }
3076
+ },
3077
+ "required": [
3078
+ "path",
3079
+ "operation",
3080
+ "artifact_kind",
3081
+ "role",
3082
+ "layer",
3083
+ "content_type",
3084
+ "reason",
3085
+ "implementation",
3086
+ "decision_refs",
3087
+ "source_refs",
3088
+ "tags",
3089
+ "metadata"
3090
+ ],
3091
+ "additionalProperties": false
3092
+ }
3093
+ }
3094
+ },
3095
+ "required": [
3096
+ "schema_version",
3097
+ "sdk_package",
3098
+ "generated_at",
3099
+ "artifacts"
3100
+ ],
3101
+ "additionalProperties": false,
3102
+ "title": "CodeSDD Plugin SDK Artifact Map",
3103
+ "description": "Typed file map for plugin-planned artifacts with layer, role, kind, operation, decision refs, and source refs."
3104
+ }
3105
+ },
3106
+ "plugin_registries": {
3107
+ "plugin-registry.yaml": {
3108
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3109
+ "type": "object",
3110
+ "properties": {
3111
+ "schema_version": {
3112
+ "type": "number",
3113
+ "const": 1
3114
+ },
3115
+ "generated_at": {
3116
+ "type": "string",
3117
+ "format": "date-time",
3118
+ "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
3119
+ },
3120
+ "entries": {
3121
+ "default": [],
3122
+ "type": "array",
3123
+ "items": {
3124
+ "type": "object",
3125
+ "properties": {
3126
+ "manifest": {
3127
+ "type": "object",
3128
+ "properties": {
3129
+ "id": {
3130
+ "type": "string",
3131
+ "pattern": "^codesdd-plugin-[a-z0-9][a-z0-9-]*$"
3132
+ },
3133
+ "name": {
3134
+ "type": "string",
3135
+ "minLength": 3
3136
+ },
3137
+ "version": {
2104
3138
  "type": "string",
2105
3139
  "pattern": "^\\d+\\.\\d+\\.\\d+(?:[-+][0-9A-Za-z.-]+)?$"
2106
3140
  },
@@ -2168,6 +3202,177 @@
2168
3202
  ],
2169
3203
  "additionalProperties": false
2170
3204
  },
3205
+ "package_governance": {
3206
+ "type": "object",
3207
+ "properties": {
3208
+ "package_name": {
3209
+ "type": "string",
3210
+ "pattern": "^@devtrack-solution\\/codesdd-plugin-[a-z0-9][a-z0-9-]*$"
3211
+ },
3212
+ "sdk_package": {
3213
+ "default": "@devtrack-solution/codesdd-plugin-sdk",
3214
+ "type": "string",
3215
+ "pattern": "^@devtrack-solution\\/codesdd-plugin-sdk$"
3216
+ },
3217
+ "sdk_version": {
3218
+ "default": "*",
3219
+ "type": "string",
3220
+ "pattern": "^(?:[~^]?\\d+\\.\\d+\\.\\d+(?:[-+][0-9A-Za-z.-]+)?|[<>]=?\\d+\\.\\d+\\.\\d+(?:\\s+<\\d+\\.\\d+\\.\\d+)?|\\*)$"
3221
+ },
3222
+ "package_kind": {
3223
+ "type": "string",
3224
+ "enum": [
3225
+ "frontend",
3226
+ "backend",
3227
+ "full-stack",
3228
+ "generator",
3229
+ "validator",
3230
+ "evidence",
3231
+ "agent-adapter",
3232
+ "policy-pack"
3233
+ ]
3234
+ },
3235
+ "versioning": {
3236
+ "default": "semver",
3237
+ "type": "string",
3238
+ "const": "semver"
3239
+ },
3240
+ "registry": {
3241
+ "default": "workspace",
3242
+ "type": "string",
3243
+ "enum": [
3244
+ "workspace",
3245
+ "npm",
3246
+ "private-npm",
3247
+ "artifact-registry",
3248
+ "custom"
3249
+ ]
3250
+ },
3251
+ "keywords": {
3252
+ "default": [],
3253
+ "type": "array",
3254
+ "items": {
3255
+ "type": "string",
3256
+ "minLength": 1
3257
+ }
3258
+ },
3259
+ "internal_package": {
3260
+ "default": false,
3261
+ "type": "boolean"
3262
+ }
3263
+ },
3264
+ "required": [
3265
+ "package_name",
3266
+ "sdk_package",
3267
+ "sdk_version",
3268
+ "package_kind",
3269
+ "versioning",
3270
+ "registry",
3271
+ "keywords",
3272
+ "internal_package"
3273
+ ],
3274
+ "additionalProperties": false
3275
+ },
3276
+ "language_runtime": {
3277
+ "type": "object",
3278
+ "properties": {
3279
+ "language": {
3280
+ "type": "string",
3281
+ "enum": [
3282
+ "typescript",
3283
+ "javascript",
3284
+ "python",
3285
+ "java",
3286
+ "go",
3287
+ "rust",
3288
+ "csharp",
3289
+ "php",
3290
+ "ruby",
3291
+ "shell",
3292
+ "other"
3293
+ ]
3294
+ },
3295
+ "runtime": {
3296
+ "type": "string",
3297
+ "minLength": 1
3298
+ },
3299
+ "bridge": {
3300
+ "type": "string",
3301
+ "enum": [
3302
+ "node-library",
3303
+ "stdio-json",
3304
+ "process-cli",
3305
+ "http-local",
3306
+ "container",
3307
+ "wasm"
3308
+ ]
3309
+ },
3310
+ "input_transport": {
3311
+ "type": "string",
3312
+ "enum": [
3313
+ "sdk-call",
3314
+ "stdin-json",
3315
+ "stdout-json",
3316
+ "file-envelope",
3317
+ "http-json"
3318
+ ]
3319
+ },
3320
+ "output_transport": {
3321
+ "type": "string",
3322
+ "enum": [
3323
+ "sdk-call",
3324
+ "stdin-json",
3325
+ "stdout-json",
3326
+ "file-envelope",
3327
+ "http-json"
3328
+ ]
3329
+ },
3330
+ "command": {
3331
+ "type": "string",
3332
+ "minLength": 1
3333
+ },
3334
+ "args": {
3335
+ "default": [],
3336
+ "type": "array",
3337
+ "items": {
3338
+ "type": "string"
3339
+ }
3340
+ },
3341
+ "package_manager": {
3342
+ "type": "string",
3343
+ "minLength": 1
3344
+ },
3345
+ "min_versions": {
3346
+ "default": {},
3347
+ "type": "object",
3348
+ "propertyNames": {
3349
+ "type": "string"
3350
+ },
3351
+ "additionalProperties": {
3352
+ "type": "string"
3353
+ }
3354
+ },
3355
+ "env_allowlist": {
3356
+ "default": [],
3357
+ "type": "array",
3358
+ "items": {
3359
+ "type": "string",
3360
+ "pattern": "^[A-Z_][A-Z0-9_]*$"
3361
+ }
3362
+ }
3363
+ },
3364
+ "required": [
3365
+ "language",
3366
+ "runtime",
3367
+ "bridge",
3368
+ "input_transport",
3369
+ "output_transport",
3370
+ "args",
3371
+ "min_versions",
3372
+ "env_allowlist"
3373
+ ],
3374
+ "additionalProperties": false
3375
+ },
2171
3376
  "capabilities": {
2172
3377
  "minItems": 1,
2173
3378
  "type": "array",
@@ -3680,40 +4885,149 @@
3680
4885
  },
3681
4886
  "content_type": {
3682
4887
  "type": "string"
3683
- }
3684
- },
3685
- "required": [
3686
- "path",
3687
- "operation",
3688
- "reason"
3689
- ],
3690
- "additionalProperties": false
3691
- }
3692
- },
3693
- "validation_evidence": {
3694
- "default": [],
3695
- "type": "array",
3696
- "items": {
3697
- "type": "object",
3698
- "properties": {
3699
- "command": {
4888
+ },
4889
+ "artifact_kind": {
3700
4890
  "type": "string",
3701
- "minLength": 1
4891
+ "enum": [
4892
+ "source",
4893
+ "test",
4894
+ "documentation",
4895
+ "configuration",
4896
+ "schema",
4897
+ "evidence",
4898
+ "migration",
4899
+ "asset",
4900
+ "package-metadata"
4901
+ ]
3702
4902
  },
3703
- "status": {
4903
+ "role": {
3704
4904
  "type": "string",
3705
4905
  "enum": [
3706
- "pending",
3707
- "passed",
3708
- "failed",
3709
- "skipped"
4906
+ "interface",
4907
+ "type",
4908
+ "implementation",
4909
+ "abstraction",
4910
+ "business-object",
4911
+ "value-object",
4912
+ "entity",
4913
+ "repository-port",
4914
+ "use-case",
4915
+ "service",
4916
+ "handler",
4917
+ "adapter",
4918
+ "mapper",
4919
+ "module",
4920
+ "controller",
4921
+ "dto",
4922
+ "validator",
4923
+ "policy",
4924
+ "manifest",
4925
+ "fixture",
4926
+ "test",
4927
+ "documentation",
4928
+ "evidence"
3710
4929
  ]
3711
4930
  },
3712
- "evidence_ref": {
3713
- "type": "string"
3714
- }
3715
- },
3716
- "required": [
4931
+ "layer": {
4932
+ "type": "string",
4933
+ "enum": [
4934
+ "root",
4935
+ "domain",
4936
+ "application",
4937
+ "infrastructure",
4938
+ "presentation",
4939
+ "shared",
4940
+ "tests",
4941
+ "docs",
4942
+ "sdd",
4943
+ "config",
4944
+ "assets"
4945
+ ]
4946
+ },
4947
+ "language": {
4948
+ "type": "string",
4949
+ "enum": [
4950
+ "typescript",
4951
+ "javascript",
4952
+ "python",
4953
+ "java",
4954
+ "go",
4955
+ "rust",
4956
+ "csharp",
4957
+ "php",
4958
+ "ruby",
4959
+ "shell",
4960
+ "other"
4961
+ ]
4962
+ },
4963
+ "context": {
4964
+ "type": "string",
4965
+ "minLength": 1
4966
+ },
4967
+ "implementation": {
4968
+ "type": "string",
4969
+ "enum": [
4970
+ "concrete",
4971
+ "abstract",
4972
+ "contract",
4973
+ "generated",
4974
+ "manual"
4975
+ ]
4976
+ },
4977
+ "decision_refs": {
4978
+ "type": "array",
4979
+ "items": {
4980
+ "type": "string",
4981
+ "pattern": "^(?:ADR|DEB|EPIC|FEAT|INS)-\\d{4}$"
4982
+ }
4983
+ },
4984
+ "source_refs": {
4985
+ "type": "array",
4986
+ "items": {
4987
+ "type": "string",
4988
+ "minLength": 1
4989
+ }
4990
+ },
4991
+ "tags": {
4992
+ "type": "array",
4993
+ "items": {
4994
+ "type": "string",
4995
+ "minLength": 1
4996
+ }
4997
+ }
4998
+ },
4999
+ "required": [
5000
+ "path",
5001
+ "operation",
5002
+ "reason"
5003
+ ],
5004
+ "additionalProperties": false
5005
+ }
5006
+ },
5007
+ "validation_evidence": {
5008
+ "default": [],
5009
+ "type": "array",
5010
+ "items": {
5011
+ "type": "object",
5012
+ "properties": {
5013
+ "command": {
5014
+ "type": "string",
5015
+ "minLength": 1
5016
+ },
5017
+ "status": {
5018
+ "type": "string",
5019
+ "enum": [
5020
+ "pending",
5021
+ "passed",
5022
+ "failed",
5023
+ "skipped"
5024
+ ]
5025
+ },
5026
+ "evidence_ref": {
5027
+ "type": "string"
5028
+ }
5029
+ },
5030
+ "required": [
3717
5031
  "command",
3718
5032
  "status"
3719
5033
  ],
@@ -3926,6 +5240,115 @@
3926
5240
  },
3927
5241
  "content_type": {
3928
5242
  "type": "string"
5243
+ },
5244
+ "artifact_kind": {
5245
+ "type": "string",
5246
+ "enum": [
5247
+ "source",
5248
+ "test",
5249
+ "documentation",
5250
+ "configuration",
5251
+ "schema",
5252
+ "evidence",
5253
+ "migration",
5254
+ "asset",
5255
+ "package-metadata"
5256
+ ]
5257
+ },
5258
+ "role": {
5259
+ "type": "string",
5260
+ "enum": [
5261
+ "interface",
5262
+ "type",
5263
+ "implementation",
5264
+ "abstraction",
5265
+ "business-object",
5266
+ "value-object",
5267
+ "entity",
5268
+ "repository-port",
5269
+ "use-case",
5270
+ "service",
5271
+ "handler",
5272
+ "adapter",
5273
+ "mapper",
5274
+ "module",
5275
+ "controller",
5276
+ "dto",
5277
+ "validator",
5278
+ "policy",
5279
+ "manifest",
5280
+ "fixture",
5281
+ "test",
5282
+ "documentation",
5283
+ "evidence"
5284
+ ]
5285
+ },
5286
+ "layer": {
5287
+ "type": "string",
5288
+ "enum": [
5289
+ "root",
5290
+ "domain",
5291
+ "application",
5292
+ "infrastructure",
5293
+ "presentation",
5294
+ "shared",
5295
+ "tests",
5296
+ "docs",
5297
+ "sdd",
5298
+ "config",
5299
+ "assets"
5300
+ ]
5301
+ },
5302
+ "language": {
5303
+ "type": "string",
5304
+ "enum": [
5305
+ "typescript",
5306
+ "javascript",
5307
+ "python",
5308
+ "java",
5309
+ "go",
5310
+ "rust",
5311
+ "csharp",
5312
+ "php",
5313
+ "ruby",
5314
+ "shell",
5315
+ "other"
5316
+ ]
5317
+ },
5318
+ "context": {
5319
+ "type": "string",
5320
+ "minLength": 1
5321
+ },
5322
+ "implementation": {
5323
+ "type": "string",
5324
+ "enum": [
5325
+ "concrete",
5326
+ "abstract",
5327
+ "contract",
5328
+ "generated",
5329
+ "manual"
5330
+ ]
5331
+ },
5332
+ "decision_refs": {
5333
+ "type": "array",
5334
+ "items": {
5335
+ "type": "string",
5336
+ "pattern": "^(?:ADR|DEB|EPIC|FEAT|INS)-\\d{4}$"
5337
+ }
5338
+ },
5339
+ "source_refs": {
5340
+ "type": "array",
5341
+ "items": {
5342
+ "type": "string",
5343
+ "minLength": 1
5344
+ }
5345
+ },
5346
+ "tags": {
5347
+ "type": "array",
5348
+ "items": {
5349
+ "type": "string",
5350
+ "minLength": 1
5351
+ }
3929
5352
  }
3930
5353
  },
3931
5354
  "required": [
@@ -4503,6 +5926,115 @@
4503
5926
  },
4504
5927
  "content_type": {
4505
5928
  "type": "string"
5929
+ },
5930
+ "artifact_kind": {
5931
+ "type": "string",
5932
+ "enum": [
5933
+ "source",
5934
+ "test",
5935
+ "documentation",
5936
+ "configuration",
5937
+ "schema",
5938
+ "evidence",
5939
+ "migration",
5940
+ "asset",
5941
+ "package-metadata"
5942
+ ]
5943
+ },
5944
+ "role": {
5945
+ "type": "string",
5946
+ "enum": [
5947
+ "interface",
5948
+ "type",
5949
+ "implementation",
5950
+ "abstraction",
5951
+ "business-object",
5952
+ "value-object",
5953
+ "entity",
5954
+ "repository-port",
5955
+ "use-case",
5956
+ "service",
5957
+ "handler",
5958
+ "adapter",
5959
+ "mapper",
5960
+ "module",
5961
+ "controller",
5962
+ "dto",
5963
+ "validator",
5964
+ "policy",
5965
+ "manifest",
5966
+ "fixture",
5967
+ "test",
5968
+ "documentation",
5969
+ "evidence"
5970
+ ]
5971
+ },
5972
+ "layer": {
5973
+ "type": "string",
5974
+ "enum": [
5975
+ "root",
5976
+ "domain",
5977
+ "application",
5978
+ "infrastructure",
5979
+ "presentation",
5980
+ "shared",
5981
+ "tests",
5982
+ "docs",
5983
+ "sdd",
5984
+ "config",
5985
+ "assets"
5986
+ ]
5987
+ },
5988
+ "language": {
5989
+ "type": "string",
5990
+ "enum": [
5991
+ "typescript",
5992
+ "javascript",
5993
+ "python",
5994
+ "java",
5995
+ "go",
5996
+ "rust",
5997
+ "csharp",
5998
+ "php",
5999
+ "ruby",
6000
+ "shell",
6001
+ "other"
6002
+ ]
6003
+ },
6004
+ "context": {
6005
+ "type": "string",
6006
+ "minLength": 1
6007
+ },
6008
+ "implementation": {
6009
+ "type": "string",
6010
+ "enum": [
6011
+ "concrete",
6012
+ "abstract",
6013
+ "contract",
6014
+ "generated",
6015
+ "manual"
6016
+ ]
6017
+ },
6018
+ "decision_refs": {
6019
+ "type": "array",
6020
+ "items": {
6021
+ "type": "string",
6022
+ "pattern": "^(?:ADR|DEB|EPIC|FEAT|INS)-\\d{4}$"
6023
+ }
6024
+ },
6025
+ "source_refs": {
6026
+ "type": "array",
6027
+ "items": {
6028
+ "type": "string",
6029
+ "minLength": 1
6030
+ }
6031
+ },
6032
+ "tags": {
6033
+ "type": "array",
6034
+ "items": {
6035
+ "type": "string",
6036
+ "minLength": 1
6037
+ }
4506
6038
  }
4507
6039
  },
4508
6040
  "required": [
@@ -6059,99 +7591,996 @@
6059
7591
  "fake"
6060
7592
  ]
6061
7593
  },
6062
- "label": {
6063
- "type": "string",
6064
- "minLength": 2
6065
- }
6066
- },
6067
- "required": [
6068
- "id",
6069
- "provider",
6070
- "label"
6071
- ],
6072
- "additionalProperties": false
6073
- },
6074
- "task_kind": {
6075
- "type": "string",
6076
- "enum": [
6077
- "planning",
6078
- "review",
6079
- "validation",
6080
- "implementation",
6081
- "reverse-engineering",
6082
- "plugin-execution",
6083
- "adr-governance",
6084
- "quality-witness",
6085
- "documentation-sync"
6086
- ]
6087
- },
6088
- "rank": {
6089
- "type": "integer",
6090
- "minimum": 0,
6091
- "maximum": 9007199254740991
6092
- },
6093
- "reasons": {
6094
- "default": [],
6095
- "type": "array",
6096
- "items": {
6097
- "type": "string"
7594
+ "label": {
7595
+ "type": "string",
7596
+ "minLength": 2
7597
+ }
7598
+ },
7599
+ "required": [
7600
+ "id",
7601
+ "provider",
7602
+ "label"
7603
+ ],
7604
+ "additionalProperties": false
7605
+ },
7606
+ "task_kind": {
7607
+ "type": "string",
7608
+ "enum": [
7609
+ "planning",
7610
+ "review",
7611
+ "validation",
7612
+ "implementation",
7613
+ "reverse-engineering",
7614
+ "plugin-execution",
7615
+ "adr-governance",
7616
+ "quality-witness",
7617
+ "documentation-sync"
7618
+ ]
7619
+ },
7620
+ "rank": {
7621
+ "type": "integer",
7622
+ "minimum": 0,
7623
+ "maximum": 9007199254740991
7624
+ },
7625
+ "reasons": {
7626
+ "default": [],
7627
+ "type": "array",
7628
+ "items": {
7629
+ "type": "string"
7630
+ }
7631
+ }
7632
+ },
7633
+ "required": [
7634
+ "adapter_ref",
7635
+ "task_kind",
7636
+ "rank",
7637
+ "reasons"
7638
+ ],
7639
+ "additionalProperties": false
7640
+ }
7641
+ },
7642
+ "reasons": {
7643
+ "default": [],
7644
+ "type": "array",
7645
+ "items": {
7646
+ "type": "string"
7647
+ }
7648
+ },
7649
+ "fallback": {
7650
+ "type": "object",
7651
+ "properties": {
7652
+ "strategy": {
7653
+ "type": "string",
7654
+ "enum": [
7655
+ "manual-agent-selection",
7656
+ "local-human-execution",
7657
+ "no-compatible-agent"
7658
+ ]
7659
+ },
7660
+ "message": {
7661
+ "type": "string",
7662
+ "minLength": 1
7663
+ }
7664
+ },
7665
+ "required": [
7666
+ "strategy",
7667
+ "message"
7668
+ ],
7669
+ "additionalProperties": false
7670
+ }
7671
+ },
7672
+ "required": [
7673
+ "schema_version",
7674
+ "created_at",
7675
+ "status",
7676
+ "request",
7677
+ "candidates",
7678
+ "reasons"
7679
+ ],
7680
+ "additionalProperties": false,
7681
+ "title": "CodeSDD Agent Binding Resolution",
7682
+ "description": "Machine-readable resolution result for selecting a compatible coding-agent adapter for a FEAT task."
7683
+ }
7684
+ },
7685
+ "agent_runtime_contracts": {
7686
+ "agent-runtime-command-plan.yaml": {
7687
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
7688
+ "type": "object",
7689
+ "properties": {
7690
+ "schema_version": {
7691
+ "type": "number",
7692
+ "const": 1
7693
+ },
7694
+ "created_at": {
7695
+ "type": "string",
7696
+ "format": "date-time",
7697
+ "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
7698
+ },
7699
+ "status": {
7700
+ "type": "string",
7701
+ "enum": [
7702
+ "planned",
7703
+ "blocked"
7704
+ ]
7705
+ },
7706
+ "request": {
7707
+ "type": "object",
7708
+ "properties": {
7709
+ "schema_version": {
7710
+ "default": 1,
7711
+ "type": "number",
7712
+ "const": 1
7713
+ },
7714
+ "feature_ref": {
7715
+ "type": "string",
7716
+ "pattern": "^FEAT-\\d{4}$"
7717
+ },
7718
+ "provider": {
7719
+ "type": "string",
7720
+ "enum": [
7721
+ "deepagents",
7722
+ "codex",
7723
+ "opencode"
7724
+ ]
7725
+ },
7726
+ "mode": {
7727
+ "default": "plan",
7728
+ "type": "string",
7729
+ "enum": [
7730
+ "read-only",
7731
+ "plan",
7732
+ "validate",
7733
+ "apply-sandbox",
7734
+ "apply-approved"
7735
+ ]
7736
+ },
7737
+ "instruction": {
7738
+ "type": "string",
7739
+ "minLength": 1
7740
+ },
7741
+ "cwd": {
7742
+ "default": ".",
7743
+ "type": "string",
7744
+ "minLength": 1
7745
+ },
7746
+ "model": {
7747
+ "type": "string",
7748
+ "minLength": 1
7749
+ },
7750
+ "sandbox": {
7751
+ "default": "read-only",
7752
+ "type": "string",
7753
+ "enum": [
7754
+ "read-only",
7755
+ "workspace-write",
7756
+ "danger-full-access"
7757
+ ]
7758
+ },
7759
+ "output_schema": {
7760
+ "type": "string",
7761
+ "minLength": 1
7762
+ },
7763
+ "output_last_message": {
7764
+ "type": "string",
7765
+ "minLength": 1
7766
+ },
7767
+ "agent": {
7768
+ "type": "string",
7769
+ "minLength": 1
7770
+ },
7771
+ "session": {
7772
+ "type": "string",
7773
+ "minLength": 1
7774
+ },
7775
+ "files": {
7776
+ "default": [],
7777
+ "type": "array",
7778
+ "items": {
7779
+ "type": "string",
7780
+ "minLength": 1
7781
+ }
7782
+ },
7783
+ "approval_grants": {
7784
+ "default": [],
7785
+ "type": "array",
7786
+ "items": {
7787
+ "type": "string",
7788
+ "enum": [
7789
+ "maintainer",
7790
+ "architecture-board",
7791
+ "security"
7792
+ ]
7793
+ }
7794
+ }
7795
+ },
7796
+ "required": [
7797
+ "schema_version",
7798
+ "feature_ref",
7799
+ "provider",
7800
+ "mode",
7801
+ "instruction",
7802
+ "cwd",
7803
+ "sandbox",
7804
+ "files",
7805
+ "approval_grants"
7806
+ ],
7807
+ "additionalProperties": false
7808
+ },
7809
+ "provider": {
7810
+ "type": "string",
7811
+ "enum": [
7812
+ "deepagents",
7813
+ "codex",
7814
+ "opencode"
7815
+ ]
7816
+ },
7817
+ "command": {
7818
+ "type": "object",
7819
+ "properties": {
7820
+ "executable": {
7821
+ "type": "string",
7822
+ "minLength": 1
7823
+ },
7824
+ "args": {
7825
+ "default": [],
7826
+ "type": "array",
7827
+ "items": {
7828
+ "type": "string"
7829
+ }
7830
+ },
7831
+ "stdin": {
7832
+ "type": "string"
7833
+ }
7834
+ },
7835
+ "required": [
7836
+ "executable",
7837
+ "args"
7838
+ ],
7839
+ "additionalProperties": false
7840
+ },
7841
+ "evidence_contract": {
7842
+ "type": "string",
7843
+ "enum": [
7844
+ "agent-runtime-v2/deepagents",
7845
+ "agent-runtime-v2/codex-exec",
7846
+ "agent-runtime-v2/opencode-run"
7847
+ ]
7848
+ },
7849
+ "structured_output": {
7850
+ "type": "boolean"
7851
+ },
7852
+ "reasons": {
7853
+ "default": [],
7854
+ "type": "array",
7855
+ "items": {
7856
+ "type": "string"
7857
+ }
7858
+ },
7859
+ "policy": {
7860
+ "type": "object",
7861
+ "properties": {
7862
+ "direct_state_write_allowed": {
7863
+ "type": "boolean",
7864
+ "const": false
7865
+ },
7866
+ "requires_codesdd_finalize": {
7867
+ "type": "boolean",
7868
+ "const": true
7869
+ },
7870
+ "mutating_modes_require_approval": {
7871
+ "type": "boolean",
7872
+ "const": true
7873
+ }
7874
+ },
7875
+ "required": [
7876
+ "direct_state_write_allowed",
7877
+ "requires_codesdd_finalize",
7878
+ "mutating_modes_require_approval"
7879
+ ],
7880
+ "additionalProperties": false
7881
+ }
7882
+ },
7883
+ "required": [
7884
+ "schema_version",
7885
+ "created_at",
7886
+ "status",
7887
+ "request",
7888
+ "provider",
7889
+ "evidence_contract",
7890
+ "structured_output",
7891
+ "reasons",
7892
+ "policy"
7893
+ ],
7894
+ "additionalProperties": false,
7895
+ "title": "CodeSDD Agent Runtime Command Plan",
7896
+ "description": "Provider-normalized command plan for DeepAgents, Codex exec, and OpenCode run agent runtimes."
7897
+ },
7898
+ "agent-runtime-opencode-run-evidence.yaml": {
7899
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
7900
+ "type": "object",
7901
+ "properties": {
7902
+ "schema_version": {
7903
+ "type": "number",
7904
+ "const": 1
7905
+ },
7906
+ "contract": {
7907
+ "type": "string",
7908
+ "const": "agent-runtime-v2/opencode-run"
7909
+ },
7910
+ "provider": {
7911
+ "type": "string",
7912
+ "const": "opencode"
7913
+ },
7914
+ "feature_ref": {
7915
+ "type": "string",
7916
+ "pattern": "^FEAT-\\d{4}$"
7917
+ },
7918
+ "run_id": {
7919
+ "type": "string",
7920
+ "minLength": 1
7921
+ },
7922
+ "created_at": {
7923
+ "type": "string",
7924
+ "format": "date-time",
7925
+ "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
7926
+ },
7927
+ "mode": {
7928
+ "type": "string",
7929
+ "enum": [
7930
+ "read-only",
7931
+ "plan",
7932
+ "validate",
7933
+ "apply-sandbox",
7934
+ "apply-approved"
7935
+ ]
7936
+ },
7937
+ "status": {
7938
+ "type": "string",
7939
+ "enum": [
7940
+ "planned",
7941
+ "skipped",
7942
+ "blocked",
7943
+ "running",
7944
+ "completed",
7945
+ "failed"
7946
+ ]
7947
+ },
7948
+ "command": {
7949
+ "type": "object",
7950
+ "properties": {
7951
+ "executable": {
7952
+ "type": "string",
7953
+ "const": "opencode"
7954
+ },
7955
+ "args": {
7956
+ "default": [],
7957
+ "type": "array",
7958
+ "items": {
7959
+ "type": "string"
7960
+ }
7961
+ },
7962
+ "stdin": {
7963
+ "type": "string"
7964
+ }
7965
+ },
7966
+ "required": [
7967
+ "executable",
7968
+ "args"
7969
+ ],
7970
+ "additionalProperties": false
7971
+ },
7972
+ "command_plan_ref": {
7973
+ "type": "string",
7974
+ "minLength": 1
7975
+ },
7976
+ "cwd": {
7977
+ "default": ".",
7978
+ "type": "string",
7979
+ "minLength": 1
7980
+ },
7981
+ "exit_code": {
7982
+ "default": null,
7983
+ "anyOf": [
7984
+ {
7985
+ "type": "integer",
7986
+ "minimum": -9007199254740991,
7987
+ "maximum": 9007199254740991
7988
+ },
7989
+ {
7990
+ "type": "null"
7991
+ }
7992
+ ]
7993
+ },
7994
+ "started_at": {
7995
+ "type": "string",
7996
+ "format": "date-time",
7997
+ "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
7998
+ },
7999
+ "completed_at": {
8000
+ "type": "string",
8001
+ "format": "date-time",
8002
+ "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
8003
+ },
8004
+ "duration_ms": {
8005
+ "type": "integer",
8006
+ "minimum": 0,
8007
+ "maximum": 9007199254740991
8008
+ },
8009
+ "structured_output": {
8010
+ "default": {},
8011
+ "type": "object",
8012
+ "propertyNames": {
8013
+ "type": "string"
8014
+ },
8015
+ "additionalProperties": {}
8016
+ },
8017
+ "stdout_excerpt": {
8018
+ "type": "string",
8019
+ "maxLength": 8000
8020
+ },
8021
+ "stderr_excerpt": {
8022
+ "type": "string",
8023
+ "maxLength": 8000
8024
+ },
8025
+ "artifacts": {
8026
+ "default": [],
8027
+ "type": "array",
8028
+ "items": {
8029
+ "type": "object",
8030
+ "properties": {
8031
+ "kind": {
8032
+ "type": "string",
8033
+ "minLength": 1
8034
+ },
8035
+ "ref": {
8036
+ "type": "string",
8037
+ "minLength": 1
8038
+ },
8039
+ "path": {
8040
+ "type": "string",
8041
+ "minLength": 1
8042
+ },
8043
+ "sha256": {
8044
+ "type": "string",
8045
+ "minLength": 1
8046
+ }
8047
+ },
8048
+ "required": [
8049
+ "kind",
8050
+ "ref"
8051
+ ],
8052
+ "additionalProperties": false
8053
+ }
8054
+ },
8055
+ "validations": {
8056
+ "default": [],
8057
+ "type": "array",
8058
+ "items": {
8059
+ "type": "string",
8060
+ "minLength": 1
8061
+ }
8062
+ },
8063
+ "redactions": {
8064
+ "default": [],
8065
+ "type": "array",
8066
+ "items": {
8067
+ "type": "string",
8068
+ "minLength": 1
8069
+ }
8070
+ },
8071
+ "risks": {
8072
+ "default": [],
8073
+ "type": "array",
8074
+ "items": {
8075
+ "type": "object",
8076
+ "properties": {
8077
+ "id": {
8078
+ "type": "string",
8079
+ "minLength": 1
8080
+ },
8081
+ "severity": {
8082
+ "type": "string",
8083
+ "enum": [
8084
+ "low",
8085
+ "medium",
8086
+ "high",
8087
+ "critical"
8088
+ ]
8089
+ },
8090
+ "summary": {
8091
+ "type": "string",
8092
+ "minLength": 1
8093
+ },
8094
+ "mitigation": {
8095
+ "type": "string",
8096
+ "minLength": 1
8097
+ }
8098
+ },
8099
+ "required": [
8100
+ "id",
8101
+ "severity",
8102
+ "summary"
8103
+ ],
8104
+ "additionalProperties": false
8105
+ }
8106
+ },
8107
+ "policy": {
8108
+ "type": "object",
8109
+ "properties": {
8110
+ "direct_state_write_allowed": {
8111
+ "type": "boolean",
8112
+ "const": false
8113
+ },
8114
+ "requires_codesdd_finalize": {
8115
+ "type": "boolean",
8116
+ "const": true
8117
+ },
8118
+ "raw_secret_output_allowed": {
8119
+ "type": "boolean",
8120
+ "const": false
8121
+ },
8122
+ "transcript_storage": {
8123
+ "default": "redacted-excerpts-only",
8124
+ "type": "string",
8125
+ "enum": [
8126
+ "forbidden",
8127
+ "redacted-excerpts-only"
8128
+ ]
8129
+ }
8130
+ },
8131
+ "required": [
8132
+ "direct_state_write_allowed",
8133
+ "requires_codesdd_finalize",
8134
+ "raw_secret_output_allowed",
8135
+ "transcript_storage"
8136
+ ],
8137
+ "additionalProperties": false
8138
+ },
8139
+ "finalize_intent": {
8140
+ "default": false,
8141
+ "type": "boolean"
8142
+ }
8143
+ },
8144
+ "required": [
8145
+ "schema_version",
8146
+ "contract",
8147
+ "provider",
8148
+ "feature_ref",
8149
+ "run_id",
8150
+ "created_at",
8151
+ "mode",
8152
+ "status",
8153
+ "command",
8154
+ "cwd",
8155
+ "exit_code",
8156
+ "structured_output",
8157
+ "artifacts",
8158
+ "validations",
8159
+ "redactions",
8160
+ "risks",
8161
+ "policy",
8162
+ "finalize_intent"
8163
+ ],
8164
+ "additionalProperties": false,
8165
+ "title": "CodeSDD Agent Runtime OpenCode Run Evidence",
8166
+ "description": "Machine-readable OpenCode run evidence with redacted excerpts, artifacts, validations, and finalize policy."
8167
+ }
8168
+ },
8169
+ "parallel_feat_automation": {
8170
+ "parallel-feat-automation-request.yaml": {
8171
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
8172
+ "type": "object",
8173
+ "properties": {
8174
+ "schema_version": {
8175
+ "default": 1,
8176
+ "type": "number",
8177
+ "const": 1
8178
+ },
8179
+ "generated_at": {
8180
+ "type": "string",
8181
+ "format": "date-time",
8182
+ "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
8183
+ },
8184
+ "max_agents": {
8185
+ "default": 5,
8186
+ "type": "integer",
8187
+ "minimum": 1,
8188
+ "maximum": 10
8189
+ },
8190
+ "require_clean_worktree": {
8191
+ "default": true,
8192
+ "type": "boolean"
8193
+ },
8194
+ "require_commit_per_feature": {
8195
+ "default": true,
8196
+ "type": "boolean"
8197
+ },
8198
+ "require_finalize_before_commit": {
8199
+ "default": true,
8200
+ "type": "boolean"
8201
+ },
8202
+ "agent_provider": {
8203
+ "type": "string",
8204
+ "enum": [
8205
+ "codex",
8206
+ "opencode",
8207
+ "claude-code",
8208
+ "cloudcode",
8209
+ "deepagents",
8210
+ "fake"
8211
+ ]
8212
+ },
8213
+ "features": {
8214
+ "default": [],
8215
+ "type": "array",
8216
+ "items": {
8217
+ "type": "object",
8218
+ "properties": {
8219
+ "feature_ref": {
8220
+ "type": "string",
8221
+ "pattern": "^FEAT-\\d{4}$"
8222
+ },
8223
+ "title": {
8224
+ "type": "string",
8225
+ "minLength": 3
8226
+ },
8227
+ "recommended_skills": {
8228
+ "default": [],
8229
+ "type": "array",
8230
+ "items": {
8231
+ "type": "string",
8232
+ "minLength": 1
8233
+ }
8234
+ },
8235
+ "lock_domains": {
8236
+ "default": [],
8237
+ "type": "array",
8238
+ "items": {
8239
+ "type": "string",
8240
+ "minLength": 1
8241
+ }
8242
+ }
8243
+ },
8244
+ "required": [
8245
+ "feature_ref",
8246
+ "title",
8247
+ "recommended_skills",
8248
+ "lock_domains"
8249
+ ],
8250
+ "additionalProperties": false
8251
+ }
8252
+ },
8253
+ "waves": {
8254
+ "default": [],
8255
+ "type": "array",
8256
+ "items": {
8257
+ "minItems": 1,
8258
+ "type": "array",
8259
+ "items": {
8260
+ "type": "string",
8261
+ "pattern": "^FEAT-\\d{4}$"
8262
+ }
8263
+ }
8264
+ }
8265
+ },
8266
+ "required": [
8267
+ "schema_version",
8268
+ "max_agents",
8269
+ "require_clean_worktree",
8270
+ "require_commit_per_feature",
8271
+ "require_finalize_before_commit",
8272
+ "features",
8273
+ "waves"
8274
+ ],
8275
+ "additionalProperties": false,
8276
+ "title": "CodeSDD Parallel FEAT Automation Request",
8277
+ "description": "Machine-readable input contract for planning safe parallel FEAT execution waves."
8278
+ },
8279
+ "parallel-feat-automation-plan.yaml": {
8280
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
8281
+ "type": "object",
8282
+ "properties": {
8283
+ "schema_version": {
8284
+ "type": "number",
8285
+ "const": 1
8286
+ },
8287
+ "generated_at": {
8288
+ "type": "string",
8289
+ "format": "date-time",
8290
+ "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
8291
+ },
8292
+ "status": {
8293
+ "type": "string",
8294
+ "enum": [
8295
+ "ready",
8296
+ "blocked",
8297
+ "empty"
8298
+ ]
8299
+ },
8300
+ "max_agents": {
8301
+ "type": "integer",
8302
+ "exclusiveMinimum": 0,
8303
+ "maximum": 9007199254740991
8304
+ },
8305
+ "state_boundary": {
8306
+ "type": "object",
8307
+ "properties": {
8308
+ "id": {
8309
+ "type": "string",
8310
+ "const": "codesdd-canonical-sdd-state"
8311
+ },
8312
+ "canonical_state_glob": {
8313
+ "type": "string",
8314
+ "const": ".sdd/state/*.yaml"
8315
+ },
8316
+ "project_state_root": {
8317
+ "type": "string",
8318
+ "const": ".sdd"
8319
+ },
8320
+ "hidden_state_allowed": {
8321
+ "type": "boolean",
8322
+ "const": false
8323
+ },
8324
+ "external_state_allowed": {
8325
+ "type": "boolean",
8326
+ "const": false
8327
+ }
8328
+ },
8329
+ "required": [
8330
+ "id",
8331
+ "canonical_state_glob",
8332
+ "project_state_root",
8333
+ "hidden_state_allowed",
8334
+ "external_state_allowed"
8335
+ ],
8336
+ "additionalProperties": false
8337
+ },
8338
+ "write_policy": {
8339
+ "type": "object",
8340
+ "properties": {
8341
+ "allowed_root": {
8342
+ "type": "string",
8343
+ "const": ".sdd"
8344
+ },
8345
+ "canonical_state_glob": {
8346
+ "type": "string",
8347
+ "const": ".sdd/state/*.yaml"
8348
+ },
8349
+ "hidden_state_allowed": {
8350
+ "type": "boolean",
8351
+ "const": false
8352
+ },
8353
+ "external_state_allowed": {
8354
+ "type": "boolean",
8355
+ "const": false
8356
+ }
8357
+ },
8358
+ "required": [
8359
+ "allowed_root",
8360
+ "canonical_state_glob",
8361
+ "hidden_state_allowed",
8362
+ "external_state_allowed"
8363
+ ],
8364
+ "additionalProperties": false
8365
+ },
8366
+ "rules": {
8367
+ "default": [],
8368
+ "type": "array",
8369
+ "items": {
8370
+ "type": "string",
8371
+ "minLength": 1
8372
+ }
8373
+ },
8374
+ "waves": {
8375
+ "default": [],
8376
+ "type": "array",
8377
+ "items": {
8378
+ "type": "object",
8379
+ "properties": {
8380
+ "wave_index": {
8381
+ "type": "integer",
8382
+ "exclusiveMinimum": 0,
8383
+ "maximum": 9007199254740991
8384
+ },
8385
+ "max_parallel": {
8386
+ "type": "integer",
8387
+ "exclusiveMinimum": 0,
8388
+ "maximum": 9007199254740991
8389
+ },
8390
+ "status": {
8391
+ "type": "string",
8392
+ "enum": [
8393
+ "ready",
8394
+ "blocked"
8395
+ ]
8396
+ },
8397
+ "conflicts": {
8398
+ "default": [],
8399
+ "type": "array",
8400
+ "items": {
8401
+ "type": "string"
8402
+ }
8403
+ },
8404
+ "steps": {
8405
+ "default": [],
8406
+ "type": "array",
8407
+ "items": {
8408
+ "type": "object",
8409
+ "properties": {
8410
+ "feature_ref": {
8411
+ "type": "string",
8412
+ "pattern": "^FEAT-\\d{4}$"
8413
+ },
8414
+ "title": {
8415
+ "type": "string",
8416
+ "minLength": 3
8417
+ },
8418
+ "sequence": {
8419
+ "type": "integer",
8420
+ "exclusiveMinimum": 0,
8421
+ "maximum": 9007199254740991
8422
+ },
8423
+ "delegation": {
8424
+ "type": "object",
8425
+ "properties": {
8426
+ "mode": {
8427
+ "type": "string",
8428
+ "enum": [
8429
+ "local-codex",
8430
+ "agent-adapter"
8431
+ ]
8432
+ },
8433
+ "provider": {
8434
+ "type": "string",
8435
+ "enum": [
8436
+ "codex",
8437
+ "opencode",
8438
+ "claude-code",
8439
+ "cloudcode",
8440
+ "deepagents",
8441
+ "fake"
8442
+ ]
8443
+ }
8444
+ },
8445
+ "required": [
8446
+ "mode"
8447
+ ],
8448
+ "additionalProperties": false
8449
+ },
8450
+ "commands": {
8451
+ "minItems": 1,
8452
+ "type": "array",
8453
+ "items": {
8454
+ "type": "string",
8455
+ "minLength": 1
8456
+ }
8457
+ },
8458
+ "commit_boundary": {
8459
+ "type": "object",
8460
+ "properties": {
8461
+ "clean_worktree_required": {
8462
+ "type": "boolean"
8463
+ },
8464
+ "finalize_before_commit": {
8465
+ "type": "boolean"
8466
+ },
8467
+ "commit_per_feature": {
8468
+ "type": "boolean"
8469
+ },
8470
+ "commit_message": {
8471
+ "type": "string",
8472
+ "minLength": 1
8473
+ }
8474
+ },
8475
+ "required": [
8476
+ "clean_worktree_required",
8477
+ "finalize_before_commit",
8478
+ "commit_per_feature",
8479
+ "commit_message"
8480
+ ],
8481
+ "additionalProperties": false
8482
+ },
8483
+ "state_boundary_ref": {
8484
+ "type": "string",
8485
+ "const": "codesdd-canonical-sdd-state"
8486
+ },
8487
+ "allowed_state_writes": {
8488
+ "minItems": 1,
8489
+ "type": "array",
8490
+ "items": {
8491
+ "type": "string",
8492
+ "minLength": 1
8493
+ }
8494
+ },
8495
+ "forbidden_state_writes": {
8496
+ "default": [
8497
+ ".codesdd/**",
8498
+ "external-context/**"
8499
+ ],
8500
+ "type": "array",
8501
+ "items": {
8502
+ "type": "string",
8503
+ "minLength": 1
8504
+ }
8505
+ },
8506
+ "evidence_required": {
8507
+ "default": [],
8508
+ "type": "array",
8509
+ "items": {
8510
+ "type": "string",
8511
+ "minLength": 1
8512
+ }
8513
+ }
8514
+ },
8515
+ "required": [
8516
+ "feature_ref",
8517
+ "title",
8518
+ "sequence",
8519
+ "delegation",
8520
+ "commands",
8521
+ "commit_boundary",
8522
+ "state_boundary_ref",
8523
+ "allowed_state_writes",
8524
+ "forbidden_state_writes",
8525
+ "evidence_required"
8526
+ ],
8527
+ "additionalProperties": false
6098
8528
  }
6099
8529
  }
6100
8530
  },
6101
8531
  "required": [
6102
- "adapter_ref",
6103
- "task_kind",
6104
- "rank",
6105
- "reasons"
8532
+ "wave_index",
8533
+ "max_parallel",
8534
+ "status",
8535
+ "conflicts",
8536
+ "steps"
6106
8537
  ],
6107
8538
  "additionalProperties": false
6108
8539
  }
6109
8540
  },
6110
- "reasons": {
6111
- "default": [],
6112
- "type": "array",
6113
- "items": {
6114
- "type": "string"
6115
- }
6116
- },
6117
- "fallback": {
8541
+ "summary": {
6118
8542
  "type": "object",
6119
8543
  "properties": {
6120
- "strategy": {
6121
- "type": "string",
6122
- "enum": [
6123
- "manual-agent-selection",
6124
- "local-human-execution",
6125
- "no-compatible-agent"
6126
- ]
8544
+ "feature_count": {
8545
+ "type": "integer",
8546
+ "minimum": 0,
8547
+ "maximum": 9007199254740991
6127
8548
  },
6128
- "message": {
6129
- "type": "string",
6130
- "minLength": 1
8549
+ "wave_count": {
8550
+ "type": "integer",
8551
+ "minimum": 0,
8552
+ "maximum": 9007199254740991
8553
+ },
8554
+ "blocked_wave_count": {
8555
+ "type": "integer",
8556
+ "minimum": 0,
8557
+ "maximum": 9007199254740991
6131
8558
  }
6132
8559
  },
6133
8560
  "required": [
6134
- "strategy",
6135
- "message"
8561
+ "feature_count",
8562
+ "wave_count",
8563
+ "blocked_wave_count"
6136
8564
  ],
6137
8565
  "additionalProperties": false
6138
8566
  }
6139
8567
  },
6140
8568
  "required": [
6141
8569
  "schema_version",
6142
- "created_at",
8570
+ "generated_at",
6143
8571
  "status",
6144
- "request",
6145
- "candidates",
6146
- "reasons"
8572
+ "max_agents",
8573
+ "state_boundary",
8574
+ "write_policy",
8575
+ "rules",
8576
+ "waves",
8577
+ "summary"
6147
8578
  ],
6148
8579
  "additionalProperties": false,
6149
- "title": "CodeSDD Agent Binding Resolution",
6150
- "description": "Machine-readable resolution result for selecting a compatible coding-agent adapter for a FEAT task."
6151
- }
6152
- },
6153
- "parallel_feat_automation": {
6154
- "parallel-feat-automation-request.yaml": {
8580
+ "title": "CodeSDD Parallel FEAT Automation Plan",
8581
+ "description": "Machine-readable execution plan for safe parallel FEAT waves, quality gates, and commit boundaries."
8582
+ },
8583
+ "parallel-feat-scheduler-request.yaml": {
6155
8584
  "$schema": "https://json-schema.org/draft/2020-12/schema",
6156
8585
  "type": "object",
6157
8586
  "properties": {
@@ -6223,28 +8652,36 @@
6223
8652
  "type": "string",
6224
8653
  "minLength": 1
6225
8654
  }
8655
+ },
8656
+ "blocked_by": {
8657
+ "default": [],
8658
+ "type": "array",
8659
+ "items": {
8660
+ "type": "string",
8661
+ "pattern": "^FEAT-\\d{4}$"
8662
+ }
8663
+ },
8664
+ "status": {
8665
+ "default": "READY",
8666
+ "type": "string",
8667
+ "enum": [
8668
+ "READY",
8669
+ "IN_PROGRESS",
8670
+ "BLOCKED",
8671
+ "DONE"
8672
+ ]
6226
8673
  }
6227
8674
  },
6228
8675
  "required": [
6229
8676
  "feature_ref",
6230
8677
  "title",
6231
8678
  "recommended_skills",
6232
- "lock_domains"
8679
+ "lock_domains",
8680
+ "blocked_by",
8681
+ "status"
6233
8682
  ],
6234
8683
  "additionalProperties": false
6235
8684
  }
6236
- },
6237
- "waves": {
6238
- "default": [],
6239
- "type": "array",
6240
- "items": {
6241
- "minItems": 1,
6242
- "type": "array",
6243
- "items": {
6244
- "type": "string",
6245
- "pattern": "^FEAT-\\d{4}$"
6246
- }
6247
- }
6248
8685
  }
6249
8686
  },
6250
8687
  "required": [
@@ -6253,14 +8690,13 @@
6253
8690
  "require_clean_worktree",
6254
8691
  "require_commit_per_feature",
6255
8692
  "require_finalize_before_commit",
6256
- "features",
6257
- "waves"
8693
+ "features"
6258
8694
  ],
6259
8695
  "additionalProperties": false,
6260
- "title": "CodeSDD Parallel FEAT Automation Request",
6261
- "description": "Machine-readable input contract for planning safe parallel FEAT execution waves."
8696
+ "title": "CodeSDD Parallel FEAT Scheduler Request",
8697
+ "description": "Machine-readable input contract for dependency-aware chained FEAT wave scheduling."
6262
8698
  },
6263
- "parallel-feat-automation-plan.yaml": {
8699
+ "parallel-feat-scheduler-result.yaml": {
6264
8700
  "$schema": "https://json-schema.org/draft/2020-12/schema",
6265
8701
  "type": "object",
6266
8702
  "properties": {
@@ -6281,156 +8717,334 @@
6281
8717
  "empty"
6282
8718
  ]
6283
8719
  },
6284
- "max_agents": {
6285
- "type": "integer",
6286
- "exclusiveMinimum": 0,
6287
- "maximum": 9007199254740991
6288
- },
6289
- "rules": {
6290
- "default": [],
6291
- "type": "array",
6292
- "items": {
6293
- "type": "string",
6294
- "minLength": 1
6295
- }
6296
- },
6297
- "waves": {
6298
- "default": [],
6299
- "type": "array",
6300
- "items": {
6301
- "type": "object",
6302
- "properties": {
6303
- "wave_index": {
6304
- "type": "integer",
6305
- "exclusiveMinimum": 0,
6306
- "maximum": 9007199254740991
6307
- },
6308
- "max_parallel": {
6309
- "type": "integer",
6310
- "exclusiveMinimum": 0,
6311
- "maximum": 9007199254740991
6312
- },
6313
- "status": {
6314
- "type": "string",
6315
- "enum": [
6316
- "ready",
6317
- "blocked"
6318
- ]
6319
- },
6320
- "conflicts": {
6321
- "default": [],
6322
- "type": "array",
6323
- "items": {
6324
- "type": "string"
8720
+ "plan": {
8721
+ "type": "object",
8722
+ "properties": {
8723
+ "schema_version": {
8724
+ "type": "number",
8725
+ "const": 1
8726
+ },
8727
+ "generated_at": {
8728
+ "type": "string",
8729
+ "format": "date-time",
8730
+ "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
8731
+ },
8732
+ "status": {
8733
+ "type": "string",
8734
+ "enum": [
8735
+ "ready",
8736
+ "blocked",
8737
+ "empty"
8738
+ ]
8739
+ },
8740
+ "max_agents": {
8741
+ "type": "integer",
8742
+ "exclusiveMinimum": 0,
8743
+ "maximum": 9007199254740991
8744
+ },
8745
+ "state_boundary": {
8746
+ "type": "object",
8747
+ "properties": {
8748
+ "id": {
8749
+ "type": "string",
8750
+ "const": "codesdd-canonical-sdd-state"
8751
+ },
8752
+ "canonical_state_glob": {
8753
+ "type": "string",
8754
+ "const": ".sdd/state/*.yaml"
8755
+ },
8756
+ "project_state_root": {
8757
+ "type": "string",
8758
+ "const": ".sdd"
8759
+ },
8760
+ "hidden_state_allowed": {
8761
+ "type": "boolean",
8762
+ "const": false
8763
+ },
8764
+ "external_state_allowed": {
8765
+ "type": "boolean",
8766
+ "const": false
6325
8767
  }
6326
8768
  },
6327
- "steps": {
6328
- "default": [],
6329
- "type": "array",
6330
- "items": {
6331
- "type": "object",
6332
- "properties": {
6333
- "feature_ref": {
6334
- "type": "string",
6335
- "pattern": "^FEAT-\\d{4}$"
6336
- },
6337
- "title": {
6338
- "type": "string",
6339
- "minLength": 3
6340
- },
6341
- "sequence": {
6342
- "type": "integer",
6343
- "exclusiveMinimum": 0,
6344
- "maximum": 9007199254740991
6345
- },
6346
- "delegation": {
8769
+ "required": [
8770
+ "id",
8771
+ "canonical_state_glob",
8772
+ "project_state_root",
8773
+ "hidden_state_allowed",
8774
+ "external_state_allowed"
8775
+ ],
8776
+ "additionalProperties": false
8777
+ },
8778
+ "write_policy": {
8779
+ "type": "object",
8780
+ "properties": {
8781
+ "allowed_root": {
8782
+ "type": "string",
8783
+ "const": ".sdd"
8784
+ },
8785
+ "canonical_state_glob": {
8786
+ "type": "string",
8787
+ "const": ".sdd/state/*.yaml"
8788
+ },
8789
+ "hidden_state_allowed": {
8790
+ "type": "boolean",
8791
+ "const": false
8792
+ },
8793
+ "external_state_allowed": {
8794
+ "type": "boolean",
8795
+ "const": false
8796
+ }
8797
+ },
8798
+ "required": [
8799
+ "allowed_root",
8800
+ "canonical_state_glob",
8801
+ "hidden_state_allowed",
8802
+ "external_state_allowed"
8803
+ ],
8804
+ "additionalProperties": false
8805
+ },
8806
+ "rules": {
8807
+ "default": [],
8808
+ "type": "array",
8809
+ "items": {
8810
+ "type": "string",
8811
+ "minLength": 1
8812
+ }
8813
+ },
8814
+ "waves": {
8815
+ "default": [],
8816
+ "type": "array",
8817
+ "items": {
8818
+ "type": "object",
8819
+ "properties": {
8820
+ "wave_index": {
8821
+ "type": "integer",
8822
+ "exclusiveMinimum": 0,
8823
+ "maximum": 9007199254740991
8824
+ },
8825
+ "max_parallel": {
8826
+ "type": "integer",
8827
+ "exclusiveMinimum": 0,
8828
+ "maximum": 9007199254740991
8829
+ },
8830
+ "status": {
8831
+ "type": "string",
8832
+ "enum": [
8833
+ "ready",
8834
+ "blocked"
8835
+ ]
8836
+ },
8837
+ "conflicts": {
8838
+ "default": [],
8839
+ "type": "array",
8840
+ "items": {
8841
+ "type": "string"
8842
+ }
8843
+ },
8844
+ "steps": {
8845
+ "default": [],
8846
+ "type": "array",
8847
+ "items": {
6347
8848
  "type": "object",
6348
8849
  "properties": {
6349
- "mode": {
8850
+ "feature_ref": {
6350
8851
  "type": "string",
6351
- "enum": [
6352
- "local-codex",
6353
- "agent-adapter"
6354
- ]
8852
+ "pattern": "^FEAT-\\d{4}$"
6355
8853
  },
6356
- "provider": {
8854
+ "title": {
6357
8855
  "type": "string",
6358
- "enum": [
6359
- "codex",
6360
- "opencode",
6361
- "claude-code",
6362
- "cloudcode",
6363
- "deepagents",
6364
- "fake"
6365
- ]
6366
- }
6367
- },
6368
- "required": [
6369
- "mode"
6370
- ],
6371
- "additionalProperties": false
6372
- },
6373
- "commands": {
6374
- "minItems": 1,
6375
- "type": "array",
6376
- "items": {
6377
- "type": "string",
6378
- "minLength": 1
6379
- }
6380
- },
6381
- "commit_boundary": {
6382
- "type": "object",
6383
- "properties": {
6384
- "clean_worktree_required": {
6385
- "type": "boolean"
8856
+ "minLength": 3
6386
8857
  },
6387
- "finalize_before_commit": {
6388
- "type": "boolean"
8858
+ "sequence": {
8859
+ "type": "integer",
8860
+ "exclusiveMinimum": 0,
8861
+ "maximum": 9007199254740991
6389
8862
  },
6390
- "commit_per_feature": {
6391
- "type": "boolean"
8863
+ "delegation": {
8864
+ "type": "object",
8865
+ "properties": {
8866
+ "mode": {
8867
+ "type": "string",
8868
+ "enum": [
8869
+ "local-codex",
8870
+ "agent-adapter"
8871
+ ]
8872
+ },
8873
+ "provider": {
8874
+ "type": "string",
8875
+ "enum": [
8876
+ "codex",
8877
+ "opencode",
8878
+ "claude-code",
8879
+ "cloudcode",
8880
+ "deepagents",
8881
+ "fake"
8882
+ ]
8883
+ }
8884
+ },
8885
+ "required": [
8886
+ "mode"
8887
+ ],
8888
+ "additionalProperties": false
6392
8889
  },
6393
- "commit_message": {
8890
+ "commands": {
8891
+ "minItems": 1,
8892
+ "type": "array",
8893
+ "items": {
8894
+ "type": "string",
8895
+ "minLength": 1
8896
+ }
8897
+ },
8898
+ "commit_boundary": {
8899
+ "type": "object",
8900
+ "properties": {
8901
+ "clean_worktree_required": {
8902
+ "type": "boolean"
8903
+ },
8904
+ "finalize_before_commit": {
8905
+ "type": "boolean"
8906
+ },
8907
+ "commit_per_feature": {
8908
+ "type": "boolean"
8909
+ },
8910
+ "commit_message": {
8911
+ "type": "string",
8912
+ "minLength": 1
8913
+ }
8914
+ },
8915
+ "required": [
8916
+ "clean_worktree_required",
8917
+ "finalize_before_commit",
8918
+ "commit_per_feature",
8919
+ "commit_message"
8920
+ ],
8921
+ "additionalProperties": false
8922
+ },
8923
+ "state_boundary_ref": {
6394
8924
  "type": "string",
6395
- "minLength": 1
8925
+ "const": "codesdd-canonical-sdd-state"
8926
+ },
8927
+ "allowed_state_writes": {
8928
+ "minItems": 1,
8929
+ "type": "array",
8930
+ "items": {
8931
+ "type": "string",
8932
+ "minLength": 1
8933
+ }
8934
+ },
8935
+ "forbidden_state_writes": {
8936
+ "default": [
8937
+ ".codesdd/**",
8938
+ "external-context/**"
8939
+ ],
8940
+ "type": "array",
8941
+ "items": {
8942
+ "type": "string",
8943
+ "minLength": 1
8944
+ }
8945
+ },
8946
+ "evidence_required": {
8947
+ "default": [],
8948
+ "type": "array",
8949
+ "items": {
8950
+ "type": "string",
8951
+ "minLength": 1
8952
+ }
6396
8953
  }
6397
8954
  },
6398
8955
  "required": [
6399
- "clean_worktree_required",
6400
- "finalize_before_commit",
6401
- "commit_per_feature",
6402
- "commit_message"
8956
+ "feature_ref",
8957
+ "title",
8958
+ "sequence",
8959
+ "delegation",
8960
+ "commands",
8961
+ "commit_boundary",
8962
+ "state_boundary_ref",
8963
+ "allowed_state_writes",
8964
+ "forbidden_state_writes",
8965
+ "evidence_required"
6403
8966
  ],
6404
8967
  "additionalProperties": false
6405
- },
6406
- "evidence_required": {
6407
- "default": [],
6408
- "type": "array",
6409
- "items": {
6410
- "type": "string",
6411
- "minLength": 1
6412
- }
6413
8968
  }
6414
- },
6415
- "required": [
6416
- "feature_ref",
6417
- "title",
6418
- "sequence",
6419
- "delegation",
6420
- "commands",
6421
- "commit_boundary",
6422
- "evidence_required"
6423
- ],
6424
- "additionalProperties": false
8969
+ }
8970
+ },
8971
+ "required": [
8972
+ "wave_index",
8973
+ "max_parallel",
8974
+ "status",
8975
+ "conflicts",
8976
+ "steps"
8977
+ ],
8978
+ "additionalProperties": false
8979
+ }
8980
+ },
8981
+ "summary": {
8982
+ "type": "object",
8983
+ "properties": {
8984
+ "feature_count": {
8985
+ "type": "integer",
8986
+ "minimum": 0,
8987
+ "maximum": 9007199254740991
8988
+ },
8989
+ "wave_count": {
8990
+ "type": "integer",
8991
+ "minimum": 0,
8992
+ "maximum": 9007199254740991
8993
+ },
8994
+ "blocked_wave_count": {
8995
+ "type": "integer",
8996
+ "minimum": 0,
8997
+ "maximum": 9007199254740991
8998
+ }
8999
+ },
9000
+ "required": [
9001
+ "feature_count",
9002
+ "wave_count",
9003
+ "blocked_wave_count"
9004
+ ],
9005
+ "additionalProperties": false
9006
+ }
9007
+ },
9008
+ "required": [
9009
+ "schema_version",
9010
+ "generated_at",
9011
+ "status",
9012
+ "max_agents",
9013
+ "state_boundary",
9014
+ "write_policy",
9015
+ "rules",
9016
+ "waves",
9017
+ "summary"
9018
+ ],
9019
+ "additionalProperties": false
9020
+ },
9021
+ "blocked_features": {
9022
+ "default": [],
9023
+ "type": "array",
9024
+ "items": {
9025
+ "type": "object",
9026
+ "properties": {
9027
+ "feature_ref": {
9028
+ "type": "string",
9029
+ "pattern": "^FEAT-\\d{4}$"
9030
+ },
9031
+ "blocked_by": {
9032
+ "default": [],
9033
+ "type": "array",
9034
+ "items": {
9035
+ "type": "string",
9036
+ "pattern": "^FEAT-\\d{4}$"
6425
9037
  }
9038
+ },
9039
+ "reason": {
9040
+ "type": "string",
9041
+ "minLength": 1
6426
9042
  }
6427
9043
  },
6428
9044
  "required": [
6429
- "wave_index",
6430
- "max_parallel",
6431
- "status",
6432
- "conflicts",
6433
- "steps"
9045
+ "feature_ref",
9046
+ "blocked_by",
9047
+ "reason"
6434
9048
  ],
6435
9049
  "additionalProperties": false
6436
9050
  }
@@ -6443,12 +9057,22 @@
6443
9057
  "minimum": 0,
6444
9058
  "maximum": 9007199254740991
6445
9059
  },
6446
- "wave_count": {
9060
+ "scheduled_feature_count": {
6447
9061
  "type": "integer",
6448
9062
  "minimum": 0,
6449
9063
  "maximum": 9007199254740991
6450
9064
  },
6451
- "blocked_wave_count": {
9065
+ "done_feature_count": {
9066
+ "type": "integer",
9067
+ "minimum": 0,
9068
+ "maximum": 9007199254740991
9069
+ },
9070
+ "blocked_feature_count": {
9071
+ "type": "integer",
9072
+ "minimum": 0,
9073
+ "maximum": 9007199254740991
9074
+ },
9075
+ "wave_count": {
6452
9076
  "type": "integer",
6453
9077
  "minimum": 0,
6454
9078
  "maximum": 9007199254740991
@@ -6456,8 +9080,10 @@
6456
9080
  },
6457
9081
  "required": [
6458
9082
  "feature_count",
6459
- "wave_count",
6460
- "blocked_wave_count"
9083
+ "scheduled_feature_count",
9084
+ "done_feature_count",
9085
+ "blocked_feature_count",
9086
+ "wave_count"
6461
9087
  ],
6462
9088
  "additionalProperties": false
6463
9089
  }
@@ -6466,14 +9092,13 @@
6466
9092
  "schema_version",
6467
9093
  "generated_at",
6468
9094
  "status",
6469
- "max_agents",
6470
- "rules",
6471
- "waves",
9095
+ "plan",
9096
+ "blocked_features",
6472
9097
  "summary"
6473
9098
  ],
6474
9099
  "additionalProperties": false,
6475
- "title": "CodeSDD Parallel FEAT Automation Plan",
6476
- "description": "Machine-readable execution plan for safe parallel FEAT waves, quality gates, and commit boundaries."
9100
+ "title": "CodeSDD Parallel FEAT Scheduler Result",
9101
+ "description": "Machine-readable scheduler result linking chained FEAT waves, blocked dependencies, and the execution plan."
6477
9102
  }
6478
9103
  },
6479
9104
  "backlog_integrations": {
@@ -8338,8 +10963,117 @@
8338
10963
  "checksum_after": {
8339
10964
  "type": "string"
8340
10965
  },
8341
- "content_type": {
8342
- "type": "string"
10966
+ "content_type": {
10967
+ "type": "string"
10968
+ },
10969
+ "artifact_kind": {
10970
+ "type": "string",
10971
+ "enum": [
10972
+ "source",
10973
+ "test",
10974
+ "documentation",
10975
+ "configuration",
10976
+ "schema",
10977
+ "evidence",
10978
+ "migration",
10979
+ "asset",
10980
+ "package-metadata"
10981
+ ]
10982
+ },
10983
+ "role": {
10984
+ "type": "string",
10985
+ "enum": [
10986
+ "interface",
10987
+ "type",
10988
+ "implementation",
10989
+ "abstraction",
10990
+ "business-object",
10991
+ "value-object",
10992
+ "entity",
10993
+ "repository-port",
10994
+ "use-case",
10995
+ "service",
10996
+ "handler",
10997
+ "adapter",
10998
+ "mapper",
10999
+ "module",
11000
+ "controller",
11001
+ "dto",
11002
+ "validator",
11003
+ "policy",
11004
+ "manifest",
11005
+ "fixture",
11006
+ "test",
11007
+ "documentation",
11008
+ "evidence"
11009
+ ]
11010
+ },
11011
+ "layer": {
11012
+ "type": "string",
11013
+ "enum": [
11014
+ "root",
11015
+ "domain",
11016
+ "application",
11017
+ "infrastructure",
11018
+ "presentation",
11019
+ "shared",
11020
+ "tests",
11021
+ "docs",
11022
+ "sdd",
11023
+ "config",
11024
+ "assets"
11025
+ ]
11026
+ },
11027
+ "language": {
11028
+ "type": "string",
11029
+ "enum": [
11030
+ "typescript",
11031
+ "javascript",
11032
+ "python",
11033
+ "java",
11034
+ "go",
11035
+ "rust",
11036
+ "csharp",
11037
+ "php",
11038
+ "ruby",
11039
+ "shell",
11040
+ "other"
11041
+ ]
11042
+ },
11043
+ "context": {
11044
+ "type": "string",
11045
+ "minLength": 1
11046
+ },
11047
+ "implementation": {
11048
+ "type": "string",
11049
+ "enum": [
11050
+ "concrete",
11051
+ "abstract",
11052
+ "contract",
11053
+ "generated",
11054
+ "manual"
11055
+ ]
11056
+ },
11057
+ "decision_refs": {
11058
+ "type": "array",
11059
+ "items": {
11060
+ "type": "string",
11061
+ "pattern": "^(?:ADR|DEB|EPIC|FEAT|INS)-\\d{4}$"
11062
+ }
11063
+ },
11064
+ "source_refs": {
11065
+ "type": "array",
11066
+ "items": {
11067
+ "type": "string",
11068
+ "minLength": 1
11069
+ }
11070
+ },
11071
+ "tags": {
11072
+ "type": "array",
11073
+ "items": {
11074
+ "type": "string",
11075
+ "minLength": 1
11076
+ }
8343
11077
  }
8344
11078
  },
8345
11079
  "required": [
@@ -8792,8 +11526,338 @@
8792
11526
  }
8793
11527
  },
8794
11528
  "required": [
8795
- "path",
8796
- "sha256"
11529
+ "path",
11530
+ "sha256"
11531
+ ],
11532
+ "additionalProperties": false
11533
+ }
11534
+ }
11535
+ },
11536
+ "required": [
11537
+ "schema_version",
11538
+ "run",
11539
+ "scenario",
11540
+ "filesystem_snapshot",
11541
+ "import_graph",
11542
+ "exceptions",
11543
+ "checksums"
11544
+ ],
11545
+ "additionalProperties": false,
11546
+ "title": "CodeSDD Quality Evidence Bundle",
11547
+ "description": "Machine-readable evidence bundle contract tying scenario, run, artifacts, checksums, findings, and exceptions together."
11548
+ },
11549
+ "sdk-agent-plugin-quality-gate-input.yaml": {
11550
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
11551
+ "type": "object",
11552
+ "properties": {
11553
+ "schema_version": {
11554
+ "default": 1,
11555
+ "type": "number",
11556
+ "const": 1
11557
+ },
11558
+ "generated_at": {
11559
+ "type": "string",
11560
+ "format": "date-time",
11561
+ "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
11562
+ },
11563
+ "feature_ref": {
11564
+ "type": "string",
11565
+ "pattern": "^FEAT-\\d{4}$"
11566
+ },
11567
+ "package_governance": {},
11568
+ "language_runtime": {},
11569
+ "artifact_map": {},
11570
+ "agent_runtime_plans": {
11571
+ "default": [],
11572
+ "type": "array",
11573
+ "items": {}
11574
+ },
11575
+ "plugin_compliance_indexes": {
11576
+ "default": [],
11577
+ "type": "array",
11578
+ "items": {}
11579
+ },
11580
+ "coverage_scopes": {
11581
+ "default": [],
11582
+ "type": "array",
11583
+ "items": {
11584
+ "type": "object",
11585
+ "properties": {
11586
+ "id": {
11587
+ "type": "string",
11588
+ "minLength": 1
11589
+ },
11590
+ "label": {
11591
+ "type": "string",
11592
+ "minLength": 1
11593
+ },
11594
+ "metrics": {
11595
+ "type": "object",
11596
+ "properties": {
11597
+ "statements": {
11598
+ "type": "number",
11599
+ "minimum": 0,
11600
+ "maximum": 100
11601
+ },
11602
+ "branches": {
11603
+ "type": "number",
11604
+ "minimum": 0,
11605
+ "maximum": 100
11606
+ },
11607
+ "functions": {
11608
+ "type": "number",
11609
+ "minimum": 0,
11610
+ "maximum": 100
11611
+ },
11612
+ "lines": {
11613
+ "type": "number",
11614
+ "minimum": 0,
11615
+ "maximum": 100
11616
+ }
11617
+ },
11618
+ "additionalProperties": false
11619
+ },
11620
+ "target": {
11621
+ "type": "object",
11622
+ "properties": {
11623
+ "statements": {
11624
+ "type": "number",
11625
+ "minimum": 0,
11626
+ "maximum": 100
11627
+ },
11628
+ "branches": {
11629
+ "type": "number",
11630
+ "minimum": 0,
11631
+ "maximum": 100
11632
+ },
11633
+ "functions": {
11634
+ "type": "number",
11635
+ "minimum": 0,
11636
+ "maximum": 100
11637
+ },
11638
+ "lines": {
11639
+ "type": "number",
11640
+ "minimum": 0,
11641
+ "maximum": 100
11642
+ }
11643
+ },
11644
+ "additionalProperties": false
11645
+ }
11646
+ },
11647
+ "required": [
11648
+ "id",
11649
+ "label",
11650
+ "metrics"
11651
+ ],
11652
+ "additionalProperties": false
11653
+ }
11654
+ },
11655
+ "required_agent_providers": {
11656
+ "default": [
11657
+ "deepagents",
11658
+ "codex",
11659
+ "opencode"
11660
+ ],
11661
+ "type": "array",
11662
+ "items": {
11663
+ "type": "string",
11664
+ "enum": [
11665
+ "deepagents",
11666
+ "codex",
11667
+ "opencode"
11668
+ ]
11669
+ }
11670
+ },
11671
+ "coverage_target": {
11672
+ "default": {
11673
+ "statements": 95,
11674
+ "branches": 85,
11675
+ "functions": 95,
11676
+ "lines": 95
11677
+ },
11678
+ "type": "object",
11679
+ "properties": {
11680
+ "statements": {
11681
+ "type": "number",
11682
+ "minimum": 0,
11683
+ "maximum": 100
11684
+ },
11685
+ "branches": {
11686
+ "type": "number",
11687
+ "minimum": 0,
11688
+ "maximum": 100
11689
+ },
11690
+ "functions": {
11691
+ "type": "number",
11692
+ "minimum": 0,
11693
+ "maximum": 100
11694
+ },
11695
+ "lines": {
11696
+ "type": "number",
11697
+ "minimum": 0,
11698
+ "maximum": 100
11699
+ }
11700
+ },
11701
+ "additionalProperties": false
11702
+ }
11703
+ },
11704
+ "required": [
11705
+ "schema_version",
11706
+ "generated_at",
11707
+ "agent_runtime_plans",
11708
+ "plugin_compliance_indexes",
11709
+ "coverage_scopes",
11710
+ "required_agent_providers",
11711
+ "coverage_target"
11712
+ ],
11713
+ "additionalProperties": false,
11714
+ "title": "CodeSDD SDK Agent Plugin Quality Gate Input",
11715
+ "description": "Input contract for validating plugin SDK, agent runtime, plugin compliance, Foundation artifact map, and coverage evidence together."
11716
+ },
11717
+ "sdk-agent-plugin-quality-gate-report.yaml": {
11718
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
11719
+ "type": "object",
11720
+ "properties": {
11721
+ "schema_version": {
11722
+ "type": "number",
11723
+ "const": 1
11724
+ },
11725
+ "generated_at": {
11726
+ "type": "string",
11727
+ "format": "date-time",
11728
+ "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
11729
+ },
11730
+ "feature_ref": {
11731
+ "type": "string",
11732
+ "pattern": "^FEAT-\\d{4}$"
11733
+ },
11734
+ "decision": {
11735
+ "type": "string",
11736
+ "enum": [
11737
+ "passed",
11738
+ "warning",
11739
+ "failed"
11740
+ ]
11741
+ },
11742
+ "summary": {
11743
+ "type": "object",
11744
+ "properties": {
11745
+ "total": {
11746
+ "type": "integer",
11747
+ "minimum": 0,
11748
+ "maximum": 9007199254740991
11749
+ },
11750
+ "passed": {
11751
+ "type": "integer",
11752
+ "minimum": 0,
11753
+ "maximum": 9007199254740991
11754
+ },
11755
+ "warned": {
11756
+ "type": "integer",
11757
+ "minimum": 0,
11758
+ "maximum": 9007199254740991
11759
+ },
11760
+ "failed": {
11761
+ "type": "integer",
11762
+ "minimum": 0,
11763
+ "maximum": 9007199254740991
11764
+ }
11765
+ },
11766
+ "required": [
11767
+ "total",
11768
+ "passed",
11769
+ "warned",
11770
+ "failed"
11771
+ ],
11772
+ "additionalProperties": false
11773
+ },
11774
+ "gates": {
11775
+ "minItems": 1,
11776
+ "type": "array",
11777
+ "items": {
11778
+ "type": "object",
11779
+ "properties": {
11780
+ "id": {
11781
+ "type": "string",
11782
+ "minLength": 1
11783
+ },
11784
+ "domain": {
11785
+ "type": "string",
11786
+ "enum": [
11787
+ "plugin-sdk",
11788
+ "agent-runtime",
11789
+ "plugin-compliance",
11790
+ "foundation-architecture",
11791
+ "coverage"
11792
+ ]
11793
+ },
11794
+ "status": {
11795
+ "type": "string",
11796
+ "enum": [
11797
+ "pass",
11798
+ "warn",
11799
+ "fail"
11800
+ ]
11801
+ },
11802
+ "severity": {
11803
+ "type": "string",
11804
+ "enum": [
11805
+ "info",
11806
+ "warn",
11807
+ "fail"
11808
+ ]
11809
+ },
11810
+ "evidence": {
11811
+ "type": "string",
11812
+ "minLength": 1
11813
+ },
11814
+ "issues": {
11815
+ "default": [],
11816
+ "type": "array",
11817
+ "items": {
11818
+ "type": "object",
11819
+ "properties": {
11820
+ "code": {
11821
+ "type": "string",
11822
+ "pattern": "^[A-Z][A-Z0-9_]*$"
11823
+ },
11824
+ "severity": {
11825
+ "type": "string",
11826
+ "enum": [
11827
+ "warn",
11828
+ "fail"
11829
+ ]
11830
+ },
11831
+ "message": {
11832
+ "type": "string",
11833
+ "minLength": 1
11834
+ },
11835
+ "remediation": {
11836
+ "type": "string",
11837
+ "minLength": 1
11838
+ },
11839
+ "path": {
11840
+ "type": "string",
11841
+ "minLength": 1
11842
+ }
11843
+ },
11844
+ "required": [
11845
+ "code",
11846
+ "severity",
11847
+ "message",
11848
+ "remediation"
11849
+ ],
11850
+ "additionalProperties": false
11851
+ }
11852
+ }
11853
+ },
11854
+ "required": [
11855
+ "id",
11856
+ "domain",
11857
+ "status",
11858
+ "severity",
11859
+ "evidence",
11860
+ "issues"
8797
11861
  ],
8798
11862
  "additionalProperties": false
8799
11863
  }
@@ -8801,16 +11865,14 @@
8801
11865
  },
8802
11866
  "required": [
8803
11867
  "schema_version",
8804
- "run",
8805
- "scenario",
8806
- "filesystem_snapshot",
8807
- "import_graph",
8808
- "exceptions",
8809
- "checksums"
11868
+ "generated_at",
11869
+ "decision",
11870
+ "summary",
11871
+ "gates"
8810
11872
  ],
8811
11873
  "additionalProperties": false,
8812
- "title": "CodeSDD Quality Evidence Bundle",
8813
- "description": "Machine-readable evidence bundle contract tying scenario, run, artifacts, checksums, findings, and exceptions together."
11874
+ "title": "CodeSDD SDK Agent Plugin Quality Gate Report",
11875
+ "description": "Machine-readable quality gate report for SDK contracts, agent runtimes, plugin compliance indexes, Foundation artifact maps, and coverage scopes."
8814
11876
  }
8815
11877
  },
8816
11878
  "deepagent_execution": {
@@ -9080,6 +12142,317 @@
9080
12142
  "additionalProperties": false
9081
12143
  }
9082
12144
  },
12145
+ "change_safety": {
12146
+ "type": "object",
12147
+ "properties": {
12148
+ "explicit_modification_intent": {
12149
+ "type": "object",
12150
+ "properties": {
12151
+ "operation": {
12152
+ "type": "string",
12153
+ "enum": [
12154
+ "add",
12155
+ "modify",
12156
+ "remove",
12157
+ "replace",
12158
+ "refactor",
12159
+ "optimize"
12160
+ ]
12161
+ }
12162
+ },
12163
+ "required": [
12164
+ "operation"
12165
+ ],
12166
+ "additionalProperties": false
12167
+ },
12168
+ "context_lock": {
12169
+ "default": {
12170
+ "allowed_paths": [],
12171
+ "forbidden_paths": [],
12172
+ "protected_core": []
12173
+ },
12174
+ "type": "object",
12175
+ "properties": {
12176
+ "allowed_paths": {
12177
+ "default": [],
12178
+ "type": "array",
12179
+ "items": {
12180
+ "type": "string",
12181
+ "minLength": 1
12182
+ }
12183
+ },
12184
+ "forbidden_paths": {
12185
+ "default": [],
12186
+ "type": "array",
12187
+ "items": {
12188
+ "type": "string",
12189
+ "minLength": 1
12190
+ }
12191
+ },
12192
+ "protected_core": {
12193
+ "default": [],
12194
+ "type": "array",
12195
+ "items": {
12196
+ "type": "string",
12197
+ "minLength": 1
12198
+ }
12199
+ }
12200
+ },
12201
+ "required": [
12202
+ "allowed_paths",
12203
+ "forbidden_paths",
12204
+ "protected_core"
12205
+ ],
12206
+ "additionalProperties": false
12207
+ },
12208
+ "change_budget": {
12209
+ "default": {},
12210
+ "type": "object",
12211
+ "properties": {
12212
+ "max_files_changed": {
12213
+ "type": "integer",
12214
+ "minimum": 0,
12215
+ "maximum": 9007199254740991
12216
+ },
12217
+ "max_new_files": {
12218
+ "type": "integer",
12219
+ "minimum": 0,
12220
+ "maximum": 9007199254740991
12221
+ },
12222
+ "max_deleted_files": {
12223
+ "type": "integer",
12224
+ "minimum": 0,
12225
+ "maximum": 9007199254740991
12226
+ }
12227
+ },
12228
+ "additionalProperties": false
12229
+ },
12230
+ "governed_override": {
12231
+ "type": "object",
12232
+ "properties": {
12233
+ "feature_id": {
12234
+ "type": "string",
12235
+ "pattern": "^FEAT-\\d{4}$"
12236
+ },
12237
+ "intent": {
12238
+ "type": "string",
12239
+ "enum": [
12240
+ "add",
12241
+ "modify",
12242
+ "remove",
12243
+ "replace",
12244
+ "refactor",
12245
+ "optimize"
12246
+ ]
12247
+ },
12248
+ "rationale": {
12249
+ "type": "string",
12250
+ "minLength": 1
12251
+ },
12252
+ "write_scope": {
12253
+ "minItems": 1,
12254
+ "type": "array",
12255
+ "items": {
12256
+ "type": "string",
12257
+ "minLength": 1
12258
+ }
12259
+ },
12260
+ "expected_deletions": {
12261
+ "default": [],
12262
+ "type": "array",
12263
+ "items": {
12264
+ "type": "string",
12265
+ "minLength": 1
12266
+ }
12267
+ },
12268
+ "rollback_plan": {
12269
+ "type": "string",
12270
+ "minLength": 1
12271
+ },
12272
+ "compensating_control": {
12273
+ "type": "string",
12274
+ "minLength": 1
12275
+ },
12276
+ "approver": {
12277
+ "type": "string",
12278
+ "minLength": 1
12279
+ },
12280
+ "expires_at": {
12281
+ "type": "string",
12282
+ "format": "date-time",
12283
+ "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
12284
+ }
12285
+ },
12286
+ "required": [
12287
+ "feature_id",
12288
+ "intent",
12289
+ "rationale",
12290
+ "write_scope",
12291
+ "expected_deletions",
12292
+ "rollback_plan",
12293
+ "compensating_control",
12294
+ "approver",
12295
+ "expires_at"
12296
+ ],
12297
+ "additionalProperties": false
12298
+ }
12299
+ },
12300
+ "required": [
12301
+ "explicit_modification_intent",
12302
+ "context_lock",
12303
+ "change_budget"
12304
+ ],
12305
+ "additionalProperties": false
12306
+ },
12307
+ "planned_file_changes": {
12308
+ "default": [],
12309
+ "type": "array",
12310
+ "items": {
12311
+ "type": "object",
12312
+ "properties": {
12313
+ "path": {
12314
+ "type": "string",
12315
+ "minLength": 1
12316
+ },
12317
+ "operation": {
12318
+ "type": "string",
12319
+ "enum": [
12320
+ "create",
12321
+ "modify",
12322
+ "delete",
12323
+ "rename",
12324
+ "replace"
12325
+ ]
12326
+ },
12327
+ "previous_path": {
12328
+ "type": "string",
12329
+ "minLength": 1
12330
+ }
12331
+ },
12332
+ "required": [
12333
+ "path",
12334
+ "operation"
12335
+ ],
12336
+ "additionalProperties": false
12337
+ }
12338
+ },
12339
+ "capability_inventory_before": {
12340
+ "default": [],
12341
+ "type": "array",
12342
+ "items": {
12343
+ "type": "object",
12344
+ "properties": {
12345
+ "kind": {
12346
+ "type": "string",
12347
+ "enum": [
12348
+ "route",
12349
+ "page",
12350
+ "cli_command",
12351
+ "public_contract",
12352
+ "schema",
12353
+ "event",
12354
+ "core_flow",
12355
+ "governance_state"
12356
+ ]
12357
+ },
12358
+ "id": {
12359
+ "type": "string",
12360
+ "minLength": 1
12361
+ },
12362
+ "path": {
12363
+ "type": "string",
12364
+ "minLength": 1
12365
+ },
12366
+ "fingerprint": {
12367
+ "type": "string",
12368
+ "minLength": 1
12369
+ },
12370
+ "metadata": {
12371
+ "default": {},
12372
+ "type": "object",
12373
+ "propertyNames": {
12374
+ "type": "string"
12375
+ },
12376
+ "additionalProperties": {}
12377
+ }
12378
+ },
12379
+ "required": [
12380
+ "kind",
12381
+ "id",
12382
+ "metadata"
12383
+ ],
12384
+ "additionalProperties": false
12385
+ }
12386
+ },
12387
+ "capability_inventory_after": {
12388
+ "default": [],
12389
+ "type": "array",
12390
+ "items": {
12391
+ "type": "object",
12392
+ "properties": {
12393
+ "kind": {
12394
+ "type": "string",
12395
+ "enum": [
12396
+ "route",
12397
+ "page",
12398
+ "cli_command",
12399
+ "public_contract",
12400
+ "schema",
12401
+ "event",
12402
+ "core_flow",
12403
+ "governance_state"
12404
+ ]
12405
+ },
12406
+ "id": {
12407
+ "type": "string",
12408
+ "minLength": 1
12409
+ },
12410
+ "path": {
12411
+ "type": "string",
12412
+ "minLength": 1
12413
+ },
12414
+ "fingerprint": {
12415
+ "type": "string",
12416
+ "minLength": 1
12417
+ },
12418
+ "metadata": {
12419
+ "default": {},
12420
+ "type": "object",
12421
+ "propertyNames": {
12422
+ "type": "string"
12423
+ },
12424
+ "additionalProperties": {}
12425
+ }
12426
+ },
12427
+ "required": [
12428
+ "kind",
12429
+ "id",
12430
+ "metadata"
12431
+ ],
12432
+ "additionalProperties": false
12433
+ }
12434
+ },
12435
+ "capability_inventory_required": {
12436
+ "default": false,
12437
+ "type": "boolean"
12438
+ },
12439
+ "capability_required_kinds": {
12440
+ "default": [],
12441
+ "type": "array",
12442
+ "items": {
12443
+ "type": "string",
12444
+ "enum": [
12445
+ "route",
12446
+ "page",
12447
+ "cli_command",
12448
+ "public_contract",
12449
+ "schema",
12450
+ "event",
12451
+ "core_flow",
12452
+ "governance_state"
12453
+ ]
12454
+ }
12455
+ },
9083
12456
  "reversa_scope": {
9084
12457
  "type": "object",
9085
12458
  "properties": {
@@ -9128,6 +12501,11 @@
9128
12501
  "env_contract",
9129
12502
  "skill_ids",
9130
12503
  "plugin_envelopes",
12504
+ "planned_file_changes",
12505
+ "capability_inventory_before",
12506
+ "capability_inventory_after",
12507
+ "capability_inventory_required",
12508
+ "capability_required_kinds",
9131
12509
  "reversa_scope",
9132
12510
  "expected_evidence"
9133
12511
  ],