dna-sdk 0.1.0
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.
- package/LICENSE +21 -0
- package/README.md +58 -0
- package/dist/adapters/embedding/onnx.d.ts +32 -0
- package/dist/adapters/embedding/onnx.js +51 -0
- package/dist/adapters/filesystem/cache.d.ts +16 -0
- package/dist/adapters/filesystem/cache.js +113 -0
- package/dist/adapters/filesystem/index.d.ts +2 -0
- package/dist/adapters/filesystem/index.js +2 -0
- package/dist/adapters/filesystem/source.d.ts +82 -0
- package/dist/adapters/filesystem/source.js +357 -0
- package/dist/adapters/postgres/index.d.ts +2 -0
- package/dist/adapters/postgres/index.js +2 -0
- package/dist/adapters/postgres/migrations.d.ts +14 -0
- package/dist/adapters/postgres/migrations.js +88 -0
- package/dist/adapters/postgres/source.d.ts +172 -0
- package/dist/adapters/postgres/source.js +569 -0
- package/dist/adapters/resolvers/github.d.ts +12 -0
- package/dist/adapters/resolvers/github.js +47 -0
- package/dist/adapters/resolvers/http.d.ts +22 -0
- package/dist/adapters/resolvers/http.js +145 -0
- package/dist/adapters/resolvers/index.d.ts +3 -0
- package/dist/adapters/resolvers/index.js +3 -0
- package/dist/adapters/resolvers/local.d.ts +24 -0
- package/dist/adapters/resolvers/local.js +132 -0
- package/dist/adapters/search/driver.d.ts +45 -0
- package/dist/adapters/search/driver.js +138 -0
- package/dist/adapters/search/migrations.d.ts +26 -0
- package/dist/adapters/search/migrations.js +58 -0
- package/dist/adapters/search/rrf.d.ts +23 -0
- package/dist/adapters/search/rrf.js +42 -0
- package/dist/adapters/search/sqlite-vec.d.ts +66 -0
- package/dist/adapters/search/sqlite-vec.js +294 -0
- package/dist/bootstrap.d.ts +45 -0
- package/dist/bootstrap.js +134 -0
- package/dist/extensions/agentskills/DOCS.md +18 -0
- package/dist/extensions/agentskills.d.ts +28 -0
- package/dist/extensions/agentskills.js +252 -0
- package/dist/extensions/agentsmd/DOCS.md +18 -0
- package/dist/extensions/agentsmd.d.ts +22 -0
- package/dist/extensions/agentsmd.js +170 -0
- package/dist/extensions/audit/kinds/audit-log.kind.yaml +148 -0
- package/dist/extensions/audit.d.ts +25 -0
- package/dist/extensions/audit.js +62 -0
- package/dist/extensions/automation/kinds/automation.kind.yaml +296 -0
- package/dist/extensions/automation/query.d.ts +49 -0
- package/dist/extensions/automation/query.js +77 -0
- package/dist/extensions/automation/write-guards.d.ts +59 -0
- package/dist/extensions/automation/write-guards.js +153 -0
- package/dist/extensions/automation.d.ts +41 -0
- package/dist/extensions/automation.js +54 -0
- package/dist/extensions/collab.d.ts +16 -0
- package/dist/extensions/collab.js +79 -0
- package/dist/extensions/doc/kinds/doc.kind.yaml +118 -0
- package/dist/extensions/doc.d.ts +25 -0
- package/dist/extensions/doc.js +10 -0
- package/dist/extensions/eval/kinds/eval-baseline.kind.yaml +65 -0
- package/dist/extensions/eval/kinds/eval-case.kind.yaml +140 -0
- package/dist/extensions/eval/kinds/eval-run.kind.yaml +134 -0
- package/dist/extensions/eval/kinds/eval-suite.kind.yaml +87 -0
- package/dist/extensions/eval.d.ts +24 -0
- package/dist/extensions/eval.js +31 -0
- package/dist/extensions/evidence/kinds/evidence.kind.yaml +92 -0
- package/dist/extensions/evidence.d.ts +17 -0
- package/dist/extensions/evidence.js +94 -0
- package/dist/extensions/federation.d.ts +22 -0
- package/dist/extensions/federation.js +173 -0
- package/dist/extensions/guardrails/DOCS.md +20 -0
- package/dist/extensions/guardrails.d.ts +31 -0
- package/dist/extensions/guardrails.js +228 -0
- package/dist/extensions/helix/DOCS-Actor.md +20 -0
- package/dist/extensions/helix/DOCS-Agent.md +20 -0
- package/dist/extensions/helix/DOCS-UseCase.md +20 -0
- package/dist/extensions/helix/layers.d.ts +12 -0
- package/dist/extensions/helix/layers.js +18 -0
- package/dist/extensions/helix/write-guards.d.ts +70 -0
- package/dist/extensions/helix/write-guards.js +172 -0
- package/dist/extensions/helix.d.ts +29 -0
- package/dist/extensions/helix.js +963 -0
- package/dist/extensions/helix_extras.d.ts +124 -0
- package/dist/extensions/helix_extras.js +328 -0
- package/dist/extensions/hooks.d.ts +31 -0
- package/dist/extensions/hooks.js +247 -0
- package/dist/extensions/kinddef/DOCS.md +24 -0
- package/dist/extensions/kinddef.d.ts +40 -0
- package/dist/extensions/kinddef.js +171 -0
- package/dist/extensions/lesson.d.ts +6 -0
- package/dist/extensions/lesson.js +194 -0
- package/dist/extensions/modelreg/kinds/model-profile.kind.yaml +155 -0
- package/dist/extensions/modelreg.d.ts +30 -0
- package/dist/extensions/modelreg.js +38 -0
- package/dist/extensions/recognizer.d.ts +34 -0
- package/dist/extensions/recognizer.js +272 -0
- package/dist/extensions/research.d.ts +32 -0
- package/dist/extensions/research.js +292 -0
- package/dist/extensions/safety.d.ts +33 -0
- package/dist/extensions/safety.js +230 -0
- package/dist/extensions/sdlc/kinds/adr.kind.yaml +136 -0
- package/dist/extensions/sdlc/kinds/archive-proposal.kind.yaml +107 -0
- package/dist/extensions/sdlc/kinds/changelog.kind.yaml +108 -0
- package/dist/extensions/sdlc/kinds/cognitive-policy.kind.yaml +470 -0
- package/dist/extensions/sdlc/kinds/forecast.kind.yaml +125 -0
- package/dist/extensions/sdlc/kinds/insight.kind.yaml +87 -0
- package/dist/extensions/sdlc/kinds/kaizen.kind.yaml +106 -0
- package/dist/extensions/sdlc/kinds/lesson-learned.kind.yaml +270 -0
- package/dist/extensions/sdlc/kinds/narrative.kind.yaml +189 -0
- package/dist/extensions/sdlc/kinds/pattern-insight.kind.yaml +204 -0
- package/dist/extensions/sdlc/kinds/postmortem.kind.yaml +168 -0
- package/dist/extensions/sdlc/kinds/pre-mortem.kind.yaml +145 -0
- package/dist/extensions/sdlc/kinds/prompt-template.kind.yaml +109 -0
- package/dist/extensions/sdlc/kinds/retrospective.kind.yaml +186 -0
- package/dist/extensions/sdlc/kinds/risk-register.kind.yaml +178 -0
- package/dist/extensions/sdlc/kinds/saved-view.kind.yaml +127 -0
- package/dist/extensions/sdlc/kinds/status-report.kind.yaml +129 -0
- package/dist/extensions/sdlc/kinds/synthesis-run.kind.yaml +279 -0
- package/dist/extensions/sdlc/kinds/synthesizer-state.kind.yaml +196 -0
- package/dist/extensions/sdlc/kinds/workflow-event.kind.yaml +195 -0
- package/dist/extensions/sdlc.d.ts +32 -0
- package/dist/extensions/sdlc.js +1318 -0
- package/dist/extensions/soulspec/DOCS.md +19 -0
- package/dist/extensions/soulspec.d.ts +22 -0
- package/dist/extensions/soulspec.js +287 -0
- package/dist/extensions/tenant.d.ts +6 -0
- package/dist/extensions/tenant.js +291 -0
- package/dist/extensions/testkit.d.ts +24 -0
- package/dist/extensions/testkit.js +211 -0
- package/dist/index.d.ts +80 -0
- package/dist/index.js +102 -0
- package/dist/kernel/_text.d.ts +28 -0
- package/dist/kernel/_text.js +42 -0
- package/dist/kernel/bundle-handle.d.ts +83 -0
- package/dist/kernel/bundle-handle.js +184 -0
- package/dist/kernel/capabilities.d.ts +157 -0
- package/dist/kernel/capabilities.js +109 -0
- package/dist/kernel/collaborator-ports.d.ts +91 -0
- package/dist/kernel/collaborator-ports.js +1 -0
- package/dist/kernel/composition-resolver.d.ts +215 -0
- package/dist/kernel/composition-resolver.js +558 -0
- package/dist/kernel/composition.d.ts +10 -0
- package/dist/kernel/composition.js +1 -0
- package/dist/kernel/descriptor-loader.d.ts +13 -0
- package/dist/kernel/descriptor-loader.js +48 -0
- package/dist/kernel/document.d.ts +43 -0
- package/dist/kernel/document.js +71 -0
- package/dist/kernel/embedding.d.ts +28 -0
- package/dist/kernel/embedding.js +78 -0
- package/dist/kernel/errors.d.ts +62 -0
- package/dist/kernel/errors.js +82 -0
- package/dist/kernel/events.d.ts +6 -0
- package/dist/kernel/events.js +21 -0
- package/dist/kernel/evidence-capture.d.ts +69 -0
- package/dist/kernel/evidence-capture.js +138 -0
- package/dist/kernel/fs.d.ts +20 -0
- package/dist/kernel/fs.js +128 -0
- package/dist/kernel/generic-rw.d.ts +33 -0
- package/dist/kernel/generic-rw.js +235 -0
- package/dist/kernel/hooks.d.ts +172 -0
- package/dist/kernel/hooks.js +256 -0
- package/dist/kernel/index.d.ts +624 -0
- package/dist/kernel/index.js +1638 -0
- package/dist/kernel/instance.d.ts +211 -0
- package/dist/kernel/instance.js +487 -0
- package/dist/kernel/kind-registry.d.ts +183 -0
- package/dist/kernel/kind-registry.js +710 -0
- package/dist/kernel/kind_base.d.ts +106 -0
- package/dist/kernel/kind_base.js +244 -0
- package/dist/kernel/layer-resolver.d.ts +48 -0
- package/dist/kernel/layer-resolver.js +284 -0
- package/dist/kernel/lock-manager.d.ts +21 -0
- package/dist/kernel/lock-manager.js +43 -0
- package/dist/kernel/lock.d.ts +38 -0
- package/dist/kernel/lock.js +115 -0
- package/dist/kernel/meta.d.ts +135 -0
- package/dist/kernel/meta.js +817 -0
- package/dist/kernel/models.d.ts +3089 -0
- package/dist/kernel/models.js +764 -0
- package/dist/kernel/navigator.d.ts +36 -0
- package/dist/kernel/navigator.js +132 -0
- package/dist/kernel/port-surface.d.ts +33 -0
- package/dist/kernel/port-surface.js +180 -0
- package/dist/kernel/preview.d.ts +60 -0
- package/dist/kernel/preview.js +54 -0
- package/dist/kernel/prompt-budget.d.ts +39 -0
- package/dist/kernel/prompt-budget.js +43 -0
- package/dist/kernel/prompt-builder.d.ts +25 -0
- package/dist/kernel/prompt-builder.js +237 -0
- package/dist/kernel/protocols.d.ts +751 -0
- package/dist/kernel/protocols.js +493 -0
- package/dist/kernel/reports.d.ts +26 -0
- package/dist/kernel/reports.js +215 -0
- package/dist/kernel/resolver.d.ts +146 -0
- package/dist/kernel/resolver.js +232 -0
- package/dist/kernel/resource.d.ts +57 -0
- package/dist/kernel/resource.js +97 -0
- package/dist/kernel/runtime.d.ts +16 -0
- package/dist/kernel/runtime.js +18 -0
- package/dist/kernel/safety-scanner.d.ts +38 -0
- package/dist/kernel/safety-scanner.js +228 -0
- package/dist/kernel/serialize-to-files.d.ts +29 -0
- package/dist/kernel/serialize-to-files.js +23 -0
- package/dist/kernel/spec-access.d.ts +23 -0
- package/dist/kernel/spec-access.js +40 -0
- package/dist/kernel/studio_ui.d.ts +88 -0
- package/dist/kernel/studio_ui.js +135 -0
- package/dist/kernel/templates.d.ts +77 -0
- package/dist/kernel/templates.js +116 -0
- package/dist/kernel/tool-registry.d.ts +52 -0
- package/dist/kernel/tool-registry.js +89 -0
- package/dist/kernel/write-pipeline.d.ts +65 -0
- package/dist/kernel/write-pipeline.js +271 -0
- package/dist/kernel/writer-helpers.d.ts +24 -0
- package/dist/kernel/writer-helpers.js +42 -0
- package/dist/memory/decay.d.ts +31 -0
- package/dist/memory/decay.js +97 -0
- package/dist/memory/ecphory.d.ts +25 -0
- package/dist/memory/ecphory.js +178 -0
- package/dist/memory/encodingContext.d.ts +21 -0
- package/dist/memory/encodingContext.js +62 -0
- package/dist/memory/index.d.ts +23 -0
- package/dist/memory/index.js +23 -0
- package/dist/memory/memoryType.d.ts +7 -0
- package/dist/memory/memoryType.js +24 -0
- package/dist/memory/policy.d.ts +35 -0
- package/dist/memory/policy.js +35 -0
- package/dist/memory/retrieval.d.ts +21 -0
- package/dist/memory/retrieval.js +145 -0
- package/dist/testing/index.d.ts +8 -0
- package/dist/testing/index.js +8 -0
- package/dist/testing/recordSearchConformance.d.ts +43 -0
- package/dist/testing/recordSearchConformance.js +147 -0
- package/dist/viz/ascii.d.ts +7 -0
- package/dist/viz/ascii.js +60 -0
- package/dist/viz/health.d.ts +8 -0
- package/dist/viz/health.js +161 -0
- package/dist/viz/index.d.ts +10 -0
- package/dist/viz/index.js +10 -0
- package/dist/viz/matrix.d.ts +8 -0
- package/dist/viz/matrix.js +84 -0
- package/dist/viz/mermaid.d.ts +38 -0
- package/dist/viz/mermaid.js +706 -0
- package/package.json +82 -0
|
@@ -0,0 +1,189 @@
|
|
|
1
|
+
# Narrative — curated human-readable summary of project activity (record
|
|
2
|
+
# plane). [DEPRECATED Phase 2.2d 2026-05-26]: split into ADR + Retrospective;
|
|
3
|
+
# kept read-only for backward-compat (removal planned post rollback window).
|
|
4
|
+
# NOTE: NOT in `embed:` — the legacy embedding text joins spec.paragraphs
|
|
5
|
+
# with "\n\n" (source_text_for branch), which a declared field-join cannot
|
|
6
|
+
# reproduce byte-identically; Narrative stays in _EMBED_LEGACY.
|
|
7
|
+
#
|
|
8
|
+
# F3 lote-2 (spec 2026-06-10-kinds-descriptor-f3): synthesized from this
|
|
9
|
+
# descriptor; the hand-written class twins were deleted. PARITY-CRITICAL
|
|
10
|
+
# package data — byte-identical mirror under packages/sdk-{py,ts};
|
|
11
|
+
# tests/test_descriptor_hash_parity.py enforces. Equivalence vs the extinct
|
|
12
|
+
# class frozen in tests/test_lote2_descriptor_equivalence.py (golden:
|
|
13
|
+
# tests/goldens/lote2/Narrative.golden.json). Deltas intencionais (semântica
|
|
14
|
+
# canônica = port): summary curado substitui o eco whole-spec do KindBase
|
|
15
|
+
# default (list endpoints não usam kp.summary()); parse valida contra o
|
|
16
|
+
# schema (classe era pass-through); to_card morto não migrado.
|
|
17
|
+
apiVersion: github.com/ruinosus/dna/core/v1
|
|
18
|
+
kind: KindDefinition
|
|
19
|
+
metadata:
|
|
20
|
+
name: narrative
|
|
21
|
+
spec:
|
|
22
|
+
target_api_version: github.com/ruinosus/dna/sdlc/v1
|
|
23
|
+
target_kind: Narrative
|
|
24
|
+
alias: sdlc-narrative
|
|
25
|
+
origin: github.com/ruinosus/dna/sdlc
|
|
26
|
+
tenant_scope: global
|
|
27
|
+
plane: record
|
|
28
|
+
prompt_target: false
|
|
29
|
+
flatten_in_context: false
|
|
30
|
+
prompt_target_priority: 0
|
|
31
|
+
scope_inheritable: false
|
|
32
|
+
storage:
|
|
33
|
+
type: bundle
|
|
34
|
+
container: narratives
|
|
35
|
+
marker: NARRATIVE.md
|
|
36
|
+
body_field: body
|
|
37
|
+
dep_filters:
|
|
38
|
+
covers_features: sdlc-feature
|
|
39
|
+
covers_epics: sdlc-epic
|
|
40
|
+
covers_stories: sdlc-story
|
|
41
|
+
schema:
|
|
42
|
+
type: object
|
|
43
|
+
required:
|
|
44
|
+
- title
|
|
45
|
+
- body
|
|
46
|
+
properties:
|
|
47
|
+
title:
|
|
48
|
+
type: string
|
|
49
|
+
description: Headline for this narrative. Shown above the body.
|
|
50
|
+
body:
|
|
51
|
+
type: string
|
|
52
|
+
description: Markdown body of the narrative (lives in NARRATIVE.md). Free-form
|
|
53
|
+
— paragraphs, bullets, links to Stories/Features/commits. Should read like
|
|
54
|
+
a human update, not a log dump.
|
|
55
|
+
period_start:
|
|
56
|
+
type: string
|
|
57
|
+
format: date-time
|
|
58
|
+
description: Start of the period this narrative covers (ISO-8601).
|
|
59
|
+
period_end:
|
|
60
|
+
type: string
|
|
61
|
+
format: date-time
|
|
62
|
+
description: End of the period (often the moment the narrative was written).
|
|
63
|
+
actor:
|
|
64
|
+
type: string
|
|
65
|
+
description: Who wrote this narrative (Actor name, 'claude-code', 'human',
|
|
66
|
+
etc.).
|
|
67
|
+
auto_generated:
|
|
68
|
+
type: boolean
|
|
69
|
+
description: true = LLM-generated draft; false = human or agent-curated prose.
|
|
70
|
+
Studio shows a small badge so readers know what they're reading.
|
|
71
|
+
summary:
|
|
72
|
+
type: string
|
|
73
|
+
description: Optional one-line tl;dr. When present, the Studio card shows
|
|
74
|
+
this above the body for scanning.
|
|
75
|
+
covers_features:
|
|
76
|
+
type: array
|
|
77
|
+
items:
|
|
78
|
+
type: string
|
|
79
|
+
description: Feature names this narrative discusses.
|
|
80
|
+
covers_epics:
|
|
81
|
+
type: array
|
|
82
|
+
items:
|
|
83
|
+
type: string
|
|
84
|
+
description: Epic names this narrative discusses.
|
|
85
|
+
covers_stories:
|
|
86
|
+
type: array
|
|
87
|
+
items:
|
|
88
|
+
type: string
|
|
89
|
+
description: Story names this narrative discusses.
|
|
90
|
+
covers_session:
|
|
91
|
+
type: string
|
|
92
|
+
description: AgentSession name this narrative was auto-derived from (Karpathy
|
|
93
|
+
'context ephemeral, files durable' pattern). Set by `dna sdlc session capture`
|
|
94
|
+
when the post-capture narrative hook runs.
|
|
95
|
+
tags:
|
|
96
|
+
type: array
|
|
97
|
+
items:
|
|
98
|
+
type: string
|
|
99
|
+
description: Free-form tags for filtering (daily, release, retro, ...).
|
|
100
|
+
paragraphs:
|
|
101
|
+
type: array
|
|
102
|
+
items:
|
|
103
|
+
type: string
|
|
104
|
+
description: 'Structured prose: list of past-tense paragraphs describing what
|
|
105
|
+
shipped. Studio renders these as the hero block; falls back to `body` when
|
|
106
|
+
empty.'
|
|
107
|
+
decisions:
|
|
108
|
+
type: array
|
|
109
|
+
items:
|
|
110
|
+
type: object
|
|
111
|
+
required:
|
|
112
|
+
- summary
|
|
113
|
+
properties:
|
|
114
|
+
summary:
|
|
115
|
+
type: string
|
|
116
|
+
description: What was decided (1 sentence).
|
|
117
|
+
reason:
|
|
118
|
+
type: string
|
|
119
|
+
description: Why — the tradeoff or driving constraint.
|
|
120
|
+
trade_offs:
|
|
121
|
+
type: string
|
|
122
|
+
description: 'Optional: what we gave up to make this choice.'
|
|
123
|
+
description: Ratified decisions made during the period covered by this narrative.
|
|
124
|
+
Each captures the WHY, not just the WHAT — the decision-extractor pattern.
|
|
125
|
+
open_items:
|
|
126
|
+
type: array
|
|
127
|
+
items:
|
|
128
|
+
type: object
|
|
129
|
+
required:
|
|
130
|
+
- title
|
|
131
|
+
properties:
|
|
132
|
+
title:
|
|
133
|
+
type: string
|
|
134
|
+
owner:
|
|
135
|
+
type: string
|
|
136
|
+
blocker:
|
|
137
|
+
type: string
|
|
138
|
+
description: Work that started but didn't close in this period. Studio's 'still
|
|
139
|
+
open' section reads from this when present (otherwise computes heuristically
|
|
140
|
+
from event diff).
|
|
141
|
+
author_intent:
|
|
142
|
+
type: string
|
|
143
|
+
enum:
|
|
144
|
+
- daily
|
|
145
|
+
- weekly
|
|
146
|
+
- release
|
|
147
|
+
- retro
|
|
148
|
+
- incident
|
|
149
|
+
- freeform
|
|
150
|
+
description: What kind of narrative this is. Drives how the morning panel
|
|
151
|
+
groups multiple narratives — daily stack on the timeline, releases pin as
|
|
152
|
+
marquee, retros surface in a 'lessons' filter.
|
|
153
|
+
journey_phase:
|
|
154
|
+
type: string
|
|
155
|
+
enum:
|
|
156
|
+
- discover
|
|
157
|
+
- specify
|
|
158
|
+
- plan
|
|
159
|
+
- build
|
|
160
|
+
- verify
|
|
161
|
+
- reflect
|
|
162
|
+
description: Universal journey phase (discover → specify → plan → build →
|
|
163
|
+
reflect). Additive layer over Story/Feature/Epic status, Spec phase, etc.
|
|
164
|
+
Lets the journey ledger pin this doc to one of five universal phases compatible
|
|
165
|
+
with Superpowers / BMAD / Spec Kit / Kiro.
|
|
166
|
+
created_at:
|
|
167
|
+
type: string
|
|
168
|
+
format: date-time
|
|
169
|
+
updated_at:
|
|
170
|
+
type: string
|
|
171
|
+
format: date-time
|
|
172
|
+
summary:
|
|
173
|
+
title: ''
|
|
174
|
+
summary: ''
|
|
175
|
+
actor: ''
|
|
176
|
+
author_intent: ''
|
|
177
|
+
auto_generated: false
|
|
178
|
+
period_end: ''
|
|
179
|
+
graph_style:
|
|
180
|
+
fill: '#A78BFA'
|
|
181
|
+
stroke: '#7C3AED'
|
|
182
|
+
text_color: '#fff'
|
|
183
|
+
ascii_icon: 📜
|
|
184
|
+
display_label: Narratives
|
|
185
|
+
docs: A Narrative is a curated, human-readable summary of project activity. Stored
|
|
186
|
+
as a NARRATIVE.md bundle with markdown body. Names usually encode the period (ISO
|
|
187
|
+
date for daily, milestone slug for releases). Replaces ad-hoc 'what happened tonight?'
|
|
188
|
+
chat scrolling — the agent stamps a Narrative at session end so future readers
|
|
189
|
+
(CEO, customer, new-hire) can open one page and get the story.
|
|
@@ -0,0 +1,204 @@
|
|
|
1
|
+
# PatternInsight — output of a dream-interp engine (record plane).
|
|
2
|
+
#
|
|
3
|
+
# Schema is loose by design: each framework produces different structured
|
|
4
|
+
# output (Hill = exploration/insight/action; Jung = amplifications/
|
|
5
|
+
# archetypes; Gestalt = identifications). `framework` discriminates;
|
|
6
|
+
# multiple interpretations per SynthesisRun coexist (polyphonic engines).
|
|
7
|
+
#
|
|
8
|
+
# F3 lote-1 (spec 2026-06-10-kinds-descriptor-f3): synthesized from this
|
|
9
|
+
# descriptor; the PatternInsightKind class (Py) was deleted. This kind was
|
|
10
|
+
# Py-ONLY before F3 — the descriptor gives TS the kind for free
|
|
11
|
+
# (kind-registry-parity.json: moved py_only_allowlist → ts_aliases).
|
|
12
|
+
# PARITY-CRITICAL package data — byte-identical mirror under
|
|
13
|
+
# packages/sdk-{py,ts}; tests/test_descriptor_hash_parity.py enforces.
|
|
14
|
+
# A classe tinha um to_card morto (zero consumidores) — não migrado.
|
|
15
|
+
apiVersion: github.com/ruinosus/dna/core/v1
|
|
16
|
+
kind: KindDefinition
|
|
17
|
+
metadata:
|
|
18
|
+
name: pattern-insight
|
|
19
|
+
spec:
|
|
20
|
+
target_api_version: github.com/ruinosus/dna/cognitive/v1
|
|
21
|
+
target_kind: PatternInsight
|
|
22
|
+
alias: cognitive-pattern-insight
|
|
23
|
+
origin: github.com/ruinosus/dna/cognitive
|
|
24
|
+
tenant_scope: global
|
|
25
|
+
plane: record
|
|
26
|
+
prompt_target: false
|
|
27
|
+
flatten_in_context: false
|
|
28
|
+
prompt_target_priority: 0
|
|
29
|
+
storage:
|
|
30
|
+
type: bundle
|
|
31
|
+
container: pattern-insights
|
|
32
|
+
marker: PATTERN_INSIGHT.md
|
|
33
|
+
body_field: body
|
|
34
|
+
dep_filters:
|
|
35
|
+
dream_ref: sdlc-synthesis-run
|
|
36
|
+
schema:
|
|
37
|
+
type: object
|
|
38
|
+
required:
|
|
39
|
+
- dream_ref
|
|
40
|
+
- framework
|
|
41
|
+
- engine
|
|
42
|
+
- summary
|
|
43
|
+
properties:
|
|
44
|
+
dream_ref:
|
|
45
|
+
type: string
|
|
46
|
+
description: Slug of the SynthesisRun being interpreted.
|
|
47
|
+
framework:
|
|
48
|
+
type: string
|
|
49
|
+
enum:
|
|
50
|
+
- hill
|
|
51
|
+
- jung
|
|
52
|
+
- gestalt
|
|
53
|
+
- pattern
|
|
54
|
+
- freudian
|
|
55
|
+
- other
|
|
56
|
+
description: Interpretation school applied.
|
|
57
|
+
engine:
|
|
58
|
+
type: string
|
|
59
|
+
description: Engine name from registry (e.g. 'hill-interp').
|
|
60
|
+
engine_params:
|
|
61
|
+
type: object
|
|
62
|
+
default: {}
|
|
63
|
+
description: Params passed to the engine.
|
|
64
|
+
summary:
|
|
65
|
+
type: string
|
|
66
|
+
maxLength: 800
|
|
67
|
+
description: 1-3 sentence overview of the interpretation.
|
|
68
|
+
exploration:
|
|
69
|
+
type: object
|
|
70
|
+
description: 'Hill: stage 1 — re-reading, associations, trigger, affect
|
|
71
|
+
layer.'
|
|
72
|
+
properties:
|
|
73
|
+
re_reading:
|
|
74
|
+
type: string
|
|
75
|
+
associations:
|
|
76
|
+
type: array
|
|
77
|
+
items:
|
|
78
|
+
type: object
|
|
79
|
+
properties:
|
|
80
|
+
fragment:
|
|
81
|
+
type: string
|
|
82
|
+
amplifies_to:
|
|
83
|
+
type: array
|
|
84
|
+
items:
|
|
85
|
+
type: string
|
|
86
|
+
trigger:
|
|
87
|
+
type: string
|
|
88
|
+
affect_layer:
|
|
89
|
+
type: string
|
|
90
|
+
insight:
|
|
91
|
+
type: object
|
|
92
|
+
description: 'Hill: stage 2 — what does the dream MEAN? Level in {waking,
|
|
93
|
+
phenomenological, past, parts-of-self}.'
|
|
94
|
+
properties:
|
|
95
|
+
level:
|
|
96
|
+
type: string
|
|
97
|
+
enum:
|
|
98
|
+
- waking
|
|
99
|
+
- phenomenological
|
|
100
|
+
- past
|
|
101
|
+
- parts-of-self
|
|
102
|
+
statement:
|
|
103
|
+
type: string
|
|
104
|
+
maxLength: 1500
|
|
105
|
+
questions:
|
|
106
|
+
type: array
|
|
107
|
+
items:
|
|
108
|
+
type: string
|
|
109
|
+
action:
|
|
110
|
+
type: object
|
|
111
|
+
description: 'Hill: stage 3 — what would you DO differently? May propose
|
|
112
|
+
concrete docs (ArchiveProposal, Story, PreMortem) for HITL approval.'
|
|
113
|
+
properties:
|
|
114
|
+
propose:
|
|
115
|
+
type: array
|
|
116
|
+
items:
|
|
117
|
+
type: object
|
|
118
|
+
properties:
|
|
119
|
+
kind:
|
|
120
|
+
type: string
|
|
121
|
+
name:
|
|
122
|
+
type: string
|
|
123
|
+
reason:
|
|
124
|
+
type: string
|
|
125
|
+
follow_up:
|
|
126
|
+
type: string
|
|
127
|
+
amplifications:
|
|
128
|
+
type: array
|
|
129
|
+
items:
|
|
130
|
+
type: object
|
|
131
|
+
properties:
|
|
132
|
+
symbol:
|
|
133
|
+
type: string
|
|
134
|
+
archetype:
|
|
135
|
+
type: string
|
|
136
|
+
amplifies_to:
|
|
137
|
+
type: array
|
|
138
|
+
items:
|
|
139
|
+
type: string
|
|
140
|
+
description: 'Jung: each symbol expanded by association.'
|
|
141
|
+
individuation_question:
|
|
142
|
+
type: string
|
|
143
|
+
description: 'Jung: integration question opening reflection.'
|
|
144
|
+
identifications:
|
|
145
|
+
type: array
|
|
146
|
+
items:
|
|
147
|
+
type: object
|
|
148
|
+
properties:
|
|
149
|
+
element:
|
|
150
|
+
type: string
|
|
151
|
+
i_am_voice:
|
|
152
|
+
type: string
|
|
153
|
+
description: 'Gestalt: voice of each element as the dreamer.'
|
|
154
|
+
drafted_at:
|
|
155
|
+
type: string
|
|
156
|
+
format: date-time
|
|
157
|
+
generated_by:
|
|
158
|
+
type: string
|
|
159
|
+
tags:
|
|
160
|
+
type: array
|
|
161
|
+
items:
|
|
162
|
+
type: string
|
|
163
|
+
default: []
|
|
164
|
+
owner:
|
|
165
|
+
type: string
|
|
166
|
+
description: 'Slug reference to a Agent. When set, this PatternInsight
|
|
167
|
+
is PRIVATE to that agent. When null, it is GENERAL. Phase: cognitive-reflection.'
|
|
168
|
+
lens:
|
|
169
|
+
type: string
|
|
170
|
+
description: 'Perspectiva da interpretação. Valores convencionais: ''hill'',
|
|
171
|
+
''jung'', ''gestalt'', ''pattern'', um slug de Agent (ex: ''jarvis'',
|
|
172
|
+
''architect''), ou ''synthesis-by-<agent>'' pra meta-synthesis. Pode coincidir
|
|
173
|
+
com framework — lens é o ponto de vista, framework é a metodologia. Phase:
|
|
174
|
+
cognitive-reflection.'
|
|
175
|
+
synthesizes:
|
|
176
|
+
type: array
|
|
177
|
+
items:
|
|
178
|
+
type: string
|
|
179
|
+
default: []
|
|
180
|
+
description: 'PatternInsight IDs (names/slugs) que esta interpretação sintetiza.
|
|
181
|
+
Vazia pra interpretações de 1ª camada (hill, jung, agent-interp). Não-vazia
|
|
182
|
+
pra synthesis engines (agent-synthesis) que lêem N interps + SynthesisRun
|
|
183
|
+
e produzem leitura final. Phase: cognitive-reflection.'
|
|
184
|
+
# Curated list/tree projection (essência que o to_card morto elegia).
|
|
185
|
+
# DELTA INTENCIONAL: a classe ecoava o spec inteiro (KindBase default);
|
|
186
|
+
# list endpoints não usam summary() — produção inalterada.
|
|
187
|
+
summary:
|
|
188
|
+
dream_ref: ''
|
|
189
|
+
framework: ''
|
|
190
|
+
engine: ''
|
|
191
|
+
summary: ''
|
|
192
|
+
owner: null
|
|
193
|
+
lens: null
|
|
194
|
+
synthesizes: []
|
|
195
|
+
graph_style:
|
|
196
|
+
fill: '#F472B6'
|
|
197
|
+
stroke: '#BE185D'
|
|
198
|
+
text_color: '#fff'
|
|
199
|
+
ascii_icon: 💭
|
|
200
|
+
display_label: Pattern Insights
|
|
201
|
+
docs: PatternInsight = output of a dream-interp engine. Multiple interpretations
|
|
202
|
+
per SynthesisRun OK — engines are complementary lenses, not exclusive. Hill
|
|
203
|
+
engine produces exploration/insight/action structure; Jung produces amplifications
|
|
204
|
+
+ archetypes; Gestalt produces identifications.
|
|
@@ -0,0 +1,168 @@
|
|
|
1
|
+
# Postmortem — blameless incident analysis per Google SRE (record plane).
|
|
2
|
+
# Factual: the incident HAPPENED (timeline + root cause + action items).
|
|
3
|
+
# Distinct from PreMortem (hypothetical) and Retrospective (period summary).
|
|
4
|
+
#
|
|
5
|
+
# F3 lote-2 (spec 2026-06-10-kinds-descriptor-f3): synthesized from this
|
|
6
|
+
# descriptor; the hand-written class twins were deleted. PARITY-CRITICAL
|
|
7
|
+
# package data — byte-identical mirror under packages/sdk-{py,ts};
|
|
8
|
+
# tests/test_descriptor_hash_parity.py enforces. Equivalence vs the extinct
|
|
9
|
+
# class frozen in tests/test_lote2_descriptor_equivalence.py (golden:
|
|
10
|
+
# tests/goldens/lote2/Postmortem.golden.json). Deltas intencionais (semântica
|
|
11
|
+
# canônica = port): summary curado substitui o eco whole-spec do KindBase
|
|
12
|
+
# default (list endpoints não usam kp.summary()); parse valida contra o
|
|
13
|
+
# schema (classe era pass-through); to_card morto não migrado.
|
|
14
|
+
apiVersion: github.com/ruinosus/dna/core/v1
|
|
15
|
+
kind: KindDefinition
|
|
16
|
+
metadata:
|
|
17
|
+
name: postmortem
|
|
18
|
+
spec:
|
|
19
|
+
target_api_version: github.com/ruinosus/dna/sdlc/v1
|
|
20
|
+
target_kind: Postmortem
|
|
21
|
+
alias: sdlc-postmortem
|
|
22
|
+
origin: github.com/ruinosus/dna/sdlc
|
|
23
|
+
tenant_scope: global
|
|
24
|
+
plane: record
|
|
25
|
+
prompt_target: false
|
|
26
|
+
flatten_in_context: false
|
|
27
|
+
prompt_target_priority: 0
|
|
28
|
+
storage:
|
|
29
|
+
type: bundle
|
|
30
|
+
container: postmortems
|
|
31
|
+
marker: POSTMORTEM.md
|
|
32
|
+
body_field: body
|
|
33
|
+
dep_filters:
|
|
34
|
+
related_stories: sdlc-story
|
|
35
|
+
related_features: sdlc-feature
|
|
36
|
+
schema:
|
|
37
|
+
type: object
|
|
38
|
+
required:
|
|
39
|
+
- title
|
|
40
|
+
- incident_at
|
|
41
|
+
- severity
|
|
42
|
+
- root_cause
|
|
43
|
+
properties:
|
|
44
|
+
title:
|
|
45
|
+
type: string
|
|
46
|
+
description: Short incident headline.
|
|
47
|
+
incident_at:
|
|
48
|
+
type: string
|
|
49
|
+
format: date-time
|
|
50
|
+
description: When incident started.
|
|
51
|
+
resolved_at:
|
|
52
|
+
type: string
|
|
53
|
+
format: date-time
|
|
54
|
+
description: When incident was mitigated.
|
|
55
|
+
severity:
|
|
56
|
+
type: string
|
|
57
|
+
enum:
|
|
58
|
+
- sev1
|
|
59
|
+
- sev2
|
|
60
|
+
- sev3
|
|
61
|
+
- sev4
|
|
62
|
+
- sev5
|
|
63
|
+
description: Incident severity (sev1=full outage, sev5=cosmetic).
|
|
64
|
+
blameless:
|
|
65
|
+
type: boolean
|
|
66
|
+
default: true
|
|
67
|
+
description: Google SRE requirement — should always be true.
|
|
68
|
+
impact:
|
|
69
|
+
type: string
|
|
70
|
+
description: Customer-facing impact in plain language (downtime, errors, etc.).
|
|
71
|
+
timeline:
|
|
72
|
+
type: array
|
|
73
|
+
items:
|
|
74
|
+
type: object
|
|
75
|
+
required:
|
|
76
|
+
- at
|
|
77
|
+
- event
|
|
78
|
+
properties:
|
|
79
|
+
at:
|
|
80
|
+
type: string
|
|
81
|
+
format: date-time
|
|
82
|
+
event:
|
|
83
|
+
type: string
|
|
84
|
+
actor:
|
|
85
|
+
type: string
|
|
86
|
+
description: Chronological event log.
|
|
87
|
+
root_cause:
|
|
88
|
+
type: string
|
|
89
|
+
description: Primary cause (1-3 paragraphs).
|
|
90
|
+
contributing_factors:
|
|
91
|
+
type: array
|
|
92
|
+
items:
|
|
93
|
+
type: string
|
|
94
|
+
description: Secondary factors that worsened the incident.
|
|
95
|
+
what_went_well:
|
|
96
|
+
type: array
|
|
97
|
+
items:
|
|
98
|
+
type: string
|
|
99
|
+
description: Detection / response things that worked.
|
|
100
|
+
what_went_wrong:
|
|
101
|
+
type: array
|
|
102
|
+
items:
|
|
103
|
+
type: string
|
|
104
|
+
description: Detection / response things that didn't work.
|
|
105
|
+
action_items:
|
|
106
|
+
type: array
|
|
107
|
+
items:
|
|
108
|
+
type: object
|
|
109
|
+
required:
|
|
110
|
+
- title
|
|
111
|
+
properties:
|
|
112
|
+
title:
|
|
113
|
+
type: string
|
|
114
|
+
owner:
|
|
115
|
+
type: string
|
|
116
|
+
due:
|
|
117
|
+
type: string
|
|
118
|
+
format: date
|
|
119
|
+
story_ref:
|
|
120
|
+
type: string
|
|
121
|
+
status:
|
|
122
|
+
type: string
|
|
123
|
+
enum:
|
|
124
|
+
- todo
|
|
125
|
+
- in-progress
|
|
126
|
+
- done
|
|
127
|
+
description: Concrete follow-ups to prevent recurrence.
|
|
128
|
+
lessons_learned:
|
|
129
|
+
type: array
|
|
130
|
+
items:
|
|
131
|
+
type: string
|
|
132
|
+
description: Insights that generalize beyond this incident.
|
|
133
|
+
related_stories:
|
|
134
|
+
type: array
|
|
135
|
+
items:
|
|
136
|
+
type: string
|
|
137
|
+
description: Story slugs related to root cause or action items.
|
|
138
|
+
related_features:
|
|
139
|
+
type: array
|
|
140
|
+
items:
|
|
141
|
+
type: string
|
|
142
|
+
tags:
|
|
143
|
+
type: array
|
|
144
|
+
items:
|
|
145
|
+
type: string
|
|
146
|
+
body:
|
|
147
|
+
type: string
|
|
148
|
+
created_at:
|
|
149
|
+
type: string
|
|
150
|
+
format: date-time
|
|
151
|
+
updated_at:
|
|
152
|
+
type: string
|
|
153
|
+
format: date-time
|
|
154
|
+
summary:
|
|
155
|
+
title: ''
|
|
156
|
+
severity: ''
|
|
157
|
+
incident_at: ''
|
|
158
|
+
resolved_at: ''
|
|
159
|
+
graph_style:
|
|
160
|
+
fill: '#DC2626'
|
|
161
|
+
stroke: '#991B1B'
|
|
162
|
+
text_color: '#fff'
|
|
163
|
+
ascii_icon: 🚨
|
|
164
|
+
display_label: Postmortems
|
|
165
|
+
docs: 'A Postmortem captures a factual analysis of an incident that happened — timeline,
|
|
166
|
+
root cause, contributing factors, action items, lessons learned. Google SRE convention:
|
|
167
|
+
blameless. Distinct from PreMortem (hypothetical) and Retrospective (recurring
|
|
168
|
+
period summary).'
|
|
@@ -0,0 +1,145 @@
|
|
|
1
|
+
# PreMortem — "what would have happened" hindsight rewrite of a Story's
|
|
2
|
+
# outcome (record plane). Pairs with SynthesisRun (forward-looking) for the
|
|
3
|
+
# cognitive memory triad's hindsight dimension. Verifiable:
|
|
4
|
+
# would_have_changed predictions are checked at outcome_check_at by the
|
|
5
|
+
# same verifier as SynthesisRun.
|
|
6
|
+
#
|
|
7
|
+
# F3 lote-1 (spec 2026-06-10-kinds-descriptor-f3): synthesized from this
|
|
8
|
+
# descriptor; the PreMortemKind class (Py) was deleted. This kind was
|
|
9
|
+
# Py-ONLY before F3 — the descriptor gives TS the kind for free
|
|
10
|
+
# (kind-registry-parity.json: moved py_only_allowlist → ts_aliases).
|
|
11
|
+
# PARITY-CRITICAL package data — byte-identical mirror under
|
|
12
|
+
# packages/sdk-{py,ts}; tests/test_descriptor_hash_parity.py enforces.
|
|
13
|
+
apiVersion: github.com/ruinosus/dna/core/v1
|
|
14
|
+
kind: KindDefinition
|
|
15
|
+
metadata:
|
|
16
|
+
name: pre-mortem
|
|
17
|
+
spec:
|
|
18
|
+
target_api_version: github.com/ruinosus/dna/cognitive/v1
|
|
19
|
+
target_kind: PreMortem
|
|
20
|
+
alias: cognitive-pre-mortem
|
|
21
|
+
origin: github.com/ruinosus/dna/cognitive
|
|
22
|
+
tenant_scope: global
|
|
23
|
+
plane: record
|
|
24
|
+
prompt_target: false
|
|
25
|
+
flatten_in_context: false
|
|
26
|
+
prompt_target_priority: 0
|
|
27
|
+
storage:
|
|
28
|
+
type: bundle
|
|
29
|
+
container: pre-mortems
|
|
30
|
+
marker: PRE_MORTEM.md
|
|
31
|
+
body_field: body
|
|
32
|
+
dep_filters:
|
|
33
|
+
source_story: sdlc-story
|
|
34
|
+
schema:
|
|
35
|
+
type: object
|
|
36
|
+
required:
|
|
37
|
+
- source_story
|
|
38
|
+
- source_outcome
|
|
39
|
+
- alternative
|
|
40
|
+
- divergence_point
|
|
41
|
+
- would_have_changed
|
|
42
|
+
properties:
|
|
43
|
+
source_story:
|
|
44
|
+
type: string
|
|
45
|
+
description: Slug of the Story being rewritten (e.g. 's-foo-bar').
|
|
46
|
+
source_outcome:
|
|
47
|
+
type: string
|
|
48
|
+
enum:
|
|
49
|
+
- cancelled
|
|
50
|
+
- done
|
|
51
|
+
- dropped
|
|
52
|
+
- paused
|
|
53
|
+
description: What ACTUALLY happened to source_story.
|
|
54
|
+
alternative:
|
|
55
|
+
type: string
|
|
56
|
+
description: 'Prose: ''If instead of <outcome>, the Story had <other path>,
|
|
57
|
+
then...''. 2-4 sentences.'
|
|
58
|
+
divergence_point:
|
|
59
|
+
type: string
|
|
60
|
+
description: Decision/event that branched the timeline. Cite a date or trigger
|
|
61
|
+
event.
|
|
62
|
+
evidence_for:
|
|
63
|
+
type: array
|
|
64
|
+
items:
|
|
65
|
+
type: string
|
|
66
|
+
default: []
|
|
67
|
+
description: Doc refs supporting the counterfactual.
|
|
68
|
+
evidence_against:
|
|
69
|
+
type: array
|
|
70
|
+
items:
|
|
71
|
+
type: string
|
|
72
|
+
default: []
|
|
73
|
+
description: Doc refs that complicate the counterfactual.
|
|
74
|
+
would_have_changed:
|
|
75
|
+
type: array
|
|
76
|
+
items:
|
|
77
|
+
type: object
|
|
78
|
+
required:
|
|
79
|
+
- metric
|
|
80
|
+
- from
|
|
81
|
+
- to
|
|
82
|
+
properties:
|
|
83
|
+
metric:
|
|
84
|
+
type: string
|
|
85
|
+
from: {}
|
|
86
|
+
to: {}
|
|
87
|
+
by:
|
|
88
|
+
type: string
|
|
89
|
+
format: date
|
|
90
|
+
description: Predictions same shape as SynthesisRun.would_change. Verifiable
|
|
91
|
+
via same measure_metrics path.
|
|
92
|
+
strength:
|
|
93
|
+
type: string
|
|
94
|
+
enum:
|
|
95
|
+
- weak
|
|
96
|
+
- medium
|
|
97
|
+
- strong
|
|
98
|
+
default: medium
|
|
99
|
+
status:
|
|
100
|
+
type: string
|
|
101
|
+
enum:
|
|
102
|
+
- drafted
|
|
103
|
+
- observing
|
|
104
|
+
- realized
|
|
105
|
+
- falsified
|
|
106
|
+
default: drafted
|
|
107
|
+
outcome_check_at:
|
|
108
|
+
type: string
|
|
109
|
+
format: date-time
|
|
110
|
+
description: When to verify (same loop as SynthesisRun).
|
|
111
|
+
drafted_at:
|
|
112
|
+
type: string
|
|
113
|
+
format: date-time
|
|
114
|
+
generated_by:
|
|
115
|
+
type: string
|
|
116
|
+
tags:
|
|
117
|
+
type: array
|
|
118
|
+
items:
|
|
119
|
+
type: string
|
|
120
|
+
default: []
|
|
121
|
+
verifications:
|
|
122
|
+
type: array
|
|
123
|
+
items:
|
|
124
|
+
type: object
|
|
125
|
+
default: []
|
|
126
|
+
description: Verification trace (auto-populated by the verifier).
|
|
127
|
+
# Curated list/tree projection (campos-âncora do arc do PreMortem; defaults
|
|
128
|
+
# de status/strength espelham os defaults do schema). DELTA INTENCIONAL: a
|
|
129
|
+
# classe ecoava o spec inteiro (KindBase default); list endpoints não usam
|
|
130
|
+
# summary() — produção inalterada.
|
|
131
|
+
summary:
|
|
132
|
+
source_story: ''
|
|
133
|
+
source_outcome: ''
|
|
134
|
+
status: drafted
|
|
135
|
+
strength: medium
|
|
136
|
+
graph_style:
|
|
137
|
+
fill: '#FBBF24'
|
|
138
|
+
stroke: '#D97706'
|
|
139
|
+
text_color: '#fff'
|
|
140
|
+
ascii_icon: ↩️
|
|
141
|
+
display_label: PreMortems
|
|
142
|
+
docs: 'A PreMortem rewinds a Story''s history and asks what would have happened
|
|
143
|
+
on the other branch. Generated by a deep-sleep hindsight hook after Stories
|
|
144
|
+
ship/cancel. Verifiable: would_have_changed predictions are compared against
|
|
145
|
+
current state at outcome_check_at — same verifier as SynthesisRun.'
|