@design-intelligence/ghost 0.20.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.
Files changed (269) hide show
  1. package/LICENSE +201 -0
  2. package/README.md +75 -0
  3. package/dist/bin.d.ts +3 -0
  4. package/dist/bin.d.ts.map +1 -0
  5. package/dist/bin.js +19 -0
  6. package/dist/bin.js.map +1 -0
  7. package/dist/cli.d.ts +4 -0
  8. package/dist/cli.d.ts.map +1 -0
  9. package/dist/cli.js +29 -0
  10. package/dist/cli.js.map +1 -0
  11. package/dist/commands/checks-command.d.ts +9 -0
  12. package/dist/commands/checks-command.d.ts.map +1 -0
  13. package/dist/commands/checks-command.js +45 -0
  14. package/dist/commands/checks-command.js.map +1 -0
  15. package/dist/commands/command-discovery.d.ts +57 -0
  16. package/dist/commands/command-discovery.d.ts.map +1 -0
  17. package/dist/commands/command-discovery.js +220 -0
  18. package/dist/commands/command-discovery.js.map +1 -0
  19. package/dist/commands/errors.d.ts +7 -0
  20. package/dist/commands/errors.d.ts.map +1 -0
  21. package/dist/commands/errors.js +19 -0
  22. package/dist/commands/errors.js.map +1 -0
  23. package/dist/commands/export-command.d.ts +3 -0
  24. package/dist/commands/export-command.d.ts.map +1 -0
  25. package/dist/commands/export-command.js +157 -0
  26. package/dist/commands/export-command.js.map +1 -0
  27. package/dist/commands/fingerprint-commands.d.ts +10 -0
  28. package/dist/commands/fingerprint-commands.d.ts.map +1 -0
  29. package/dist/commands/fingerprint-commands.js +74 -0
  30. package/dist/commands/fingerprint-commands.js.map +1 -0
  31. package/dist/commands/gather-command.d.ts +3 -0
  32. package/dist/commands/gather-command.d.ts.map +1 -0
  33. package/dist/commands/gather-command.js +152 -0
  34. package/dist/commands/gather-command.js.map +1 -0
  35. package/dist/commands/init-command.d.ts +3 -0
  36. package/dist/commands/init-command.d.ts.map +1 -0
  37. package/dist/commands/init-command.js +79 -0
  38. package/dist/commands/init-command.js.map +1 -0
  39. package/dist/commands/manifest-command.d.ts +9 -0
  40. package/dist/commands/manifest-command.d.ts.map +1 -0
  41. package/dist/commands/manifest-command.js +33 -0
  42. package/dist/commands/manifest-command.js.map +1 -0
  43. package/dist/commands/pull-command.d.ts +3 -0
  44. package/dist/commands/pull-command.d.ts.map +1 -0
  45. package/dist/commands/pull-command.js +224 -0
  46. package/dist/commands/pull-command.js.map +1 -0
  47. package/dist/commands/pulse-command.d.ts +3 -0
  48. package/dist/commands/pulse-command.d.ts.map +1 -0
  49. package/dist/commands/pulse-command.js +257 -0
  50. package/dist/commands/pulse-command.js.map +1 -0
  51. package/dist/commands/review-command.d.ts +3 -0
  52. package/dist/commands/review-command.d.ts.map +1 -0
  53. package/dist/commands/review-command.js +77 -0
  54. package/dist/commands/review-command.js.map +1 -0
  55. package/dist/commands/skill-command.d.ts +3 -0
  56. package/dist/commands/skill-command.d.ts.map +1 -0
  57. package/dist/commands/skill-command.js +96 -0
  58. package/dist/commands/skill-command.js.map +1 -0
  59. package/dist/fingerprint.d.ts +5 -0
  60. package/dist/fingerprint.d.ts.map +1 -0
  61. package/dist/fingerprint.js +3 -0
  62. package/dist/fingerprint.js.map +1 -0
  63. package/dist/ghost-core/catalog/assemble.d.ts +30 -0
  64. package/dist/ghost-core/catalog/assemble.d.ts.map +1 -0
  65. package/dist/ghost-core/catalog/assemble.js +38 -0
  66. package/dist/ghost-core/catalog/assemble.js.map +1 -0
  67. package/dist/ghost-core/catalog/closest.d.ts +16 -0
  68. package/dist/ghost-core/catalog/closest.d.ts.map +1 -0
  69. package/dist/ghost-core/catalog/closest.js +63 -0
  70. package/dist/ghost-core/catalog/closest.js.map +1 -0
  71. package/dist/ghost-core/catalog/index.d.ts +10 -0
  72. package/dist/ghost-core/catalog/index.d.ts.map +1 -0
  73. package/dist/ghost-core/catalog/index.js +9 -0
  74. package/dist/ghost-core/catalog/index.js.map +1 -0
  75. package/dist/ghost-core/catalog/menu.d.ts +36 -0
  76. package/dist/ghost-core/catalog/menu.d.ts.map +1 -0
  77. package/dist/ghost-core/catalog/menu.js +27 -0
  78. package/dist/ghost-core/catalog/menu.js.map +1 -0
  79. package/dist/ghost-core/catalog/types.d.ts +37 -0
  80. package/dist/ghost-core/catalog/types.d.ts.map +1 -0
  81. package/dist/ghost-core/catalog/types.js +2 -0
  82. package/dist/ghost-core/catalog/types.js.map +1 -0
  83. package/dist/ghost-core/check/index.d.ts +12 -0
  84. package/dist/ghost-core/check/index.d.ts.map +1 -0
  85. package/dist/ghost-core/check/index.js +12 -0
  86. package/dist/ghost-core/check/index.js.map +1 -0
  87. package/dist/ghost-core/check/lint.d.ts +9 -0
  88. package/dist/ghost-core/check/lint.d.ts.map +1 -0
  89. package/dist/ghost-core/check/lint.js +119 -0
  90. package/dist/ghost-core/check/lint.js.map +1 -0
  91. package/dist/ghost-core/check/load.d.ts +7 -0
  92. package/dist/ghost-core/check/load.d.ts.map +1 -0
  93. package/dist/ghost-core/check/load.js +44 -0
  94. package/dist/ghost-core/check/load.js.map +1 -0
  95. package/dist/ghost-core/check/parse.d.ts +12 -0
  96. package/dist/ghost-core/check/parse.d.ts.map +1 -0
  97. package/dist/ghost-core/check/parse.js +13 -0
  98. package/dist/ghost-core/check/parse.js.map +1 -0
  99. package/dist/ghost-core/check/source-ref.d.ts +27 -0
  100. package/dist/ghost-core/check/source-ref.d.ts.map +1 -0
  101. package/dist/ghost-core/check/source-ref.js +58 -0
  102. package/dist/ghost-core/check/source-ref.js.map +1 -0
  103. package/dist/ghost-core/check/types.d.ts +48 -0
  104. package/dist/ghost-core/check/types.d.ts.map +1 -0
  105. package/dist/ghost-core/check/types.js +4 -0
  106. package/dist/ghost-core/check/types.js.map +1 -0
  107. package/dist/ghost-core/errors.d.ts +30 -0
  108. package/dist/ghost-core/errors.d.ts.map +1 -0
  109. package/dist/ghost-core/errors.js +33 -0
  110. package/dist/ghost-core/errors.js.map +1 -0
  111. package/dist/ghost-core/glob.d.ts +5 -0
  112. package/dist/ghost-core/glob.d.ts.map +1 -0
  113. package/dist/ghost-core/glob.js +68 -0
  114. package/dist/ghost-core/glob.js.map +1 -0
  115. package/dist/ghost-core/glossary.d.ts +38 -0
  116. package/dist/ghost-core/glossary.d.ts.map +1 -0
  117. package/dist/ghost-core/glossary.js +76 -0
  118. package/dist/ghost-core/glossary.js.map +1 -0
  119. package/dist/ghost-core/index.d.ts +13 -0
  120. package/dist/ghost-core/index.d.ts.map +1 -0
  121. package/dist/ghost-core/index.js +19 -0
  122. package/dist/ghost-core/index.js.map +1 -0
  123. package/dist/ghost-core/markdown.d.ts +15 -0
  124. package/dist/ghost-core/markdown.d.ts.map +1 -0
  125. package/dist/ghost-core/markdown.js +30 -0
  126. package/dist/ghost-core/markdown.js.map +1 -0
  127. package/dist/ghost-core/material-transport.d.ts +43 -0
  128. package/dist/ghost-core/material-transport.d.ts.map +1 -0
  129. package/dist/ghost-core/material-transport.js +231 -0
  130. package/dist/ghost-core/material-transport.js.map +1 -0
  131. package/dist/ghost-core/materials.d.ts +14 -0
  132. package/dist/ghost-core/materials.d.ts.map +1 -0
  133. package/dist/ghost-core/materials.js +52 -0
  134. package/dist/ghost-core/materials.js.map +1 -0
  135. package/dist/ghost-core/node/index.d.ts +11 -0
  136. package/dist/ghost-core/node/index.d.ts.map +1 -0
  137. package/dist/ghost-core/node/index.js +11 -0
  138. package/dist/ghost-core/node/index.js.map +1 -0
  139. package/dist/ghost-core/node/parse.d.ts +16 -0
  140. package/dist/ghost-core/node/parse.d.ts.map +1 -0
  141. package/dist/ghost-core/node/parse.js +55 -0
  142. package/dist/ghost-core/node/parse.js.map +1 -0
  143. package/dist/ghost-core/node/schema.d.ts +17 -0
  144. package/dist/ghost-core/node/schema.d.ts.map +1 -0
  145. package/dist/ghost-core/node/schema.js +49 -0
  146. package/dist/ghost-core/node/schema.js.map +1 -0
  147. package/dist/ghost-core/node/serialize.d.ts +11 -0
  148. package/dist/ghost-core/node/serialize.d.ts.map +1 -0
  149. package/dist/ghost-core/node/serialize.js +21 -0
  150. package/dist/ghost-core/node/serialize.js.map +1 -0
  151. package/dist/ghost-core/node/steering.d.ts +18 -0
  152. package/dist/ghost-core/node/steering.d.ts.map +1 -0
  153. package/dist/ghost-core/node/steering.js +65 -0
  154. package/dist/ghost-core/node/steering.js.map +1 -0
  155. package/dist/ghost-core/node/types.d.ts +42 -0
  156. package/dist/ghost-core/node/types.d.ts.map +1 -0
  157. package/dist/ghost-core/node/types.js +2 -0
  158. package/dist/ghost-core/node/types.js.map +1 -0
  159. package/dist/ghost-core/package-manifest.d.ts +12 -0
  160. package/dist/ghost-core/package-manifest.d.ts.map +1 -0
  161. package/dist/ghost-core/package-manifest.js +14 -0
  162. package/dist/ghost-core/package-manifest.js.map +1 -0
  163. package/dist/ghost-core/skill-bundle-loader.d.ts +28 -0
  164. package/dist/ghost-core/skill-bundle-loader.d.ts.map +1 -0
  165. package/dist/ghost-core/skill-bundle-loader.js +51 -0
  166. package/dist/ghost-core/skill-bundle-loader.js.map +1 -0
  167. package/dist/index.d.ts +5 -0
  168. package/dist/index.d.ts.map +1 -0
  169. package/dist/index.js +5 -0
  170. package/dist/index.js.map +1 -0
  171. package/dist/internal/fs.d.ts +4 -0
  172. package/dist/internal/fs.d.ts.map +1 -0
  173. package/dist/internal/fs.js +24 -0
  174. package/dist/internal/fs.js.map +1 -0
  175. package/dist/observability-events.d.ts +27 -0
  176. package/dist/observability-events.d.ts.map +1 -0
  177. package/dist/observability-events.js +56 -0
  178. package/dist/observability-events.js.map +1 -0
  179. package/dist/package-version.d.ts +3 -0
  180. package/dist/package-version.d.ts.map +1 -0
  181. package/dist/package-version.js +10 -0
  182. package/dist/package-version.js.map +1 -0
  183. package/dist/review/baseline.d.ts +11 -0
  184. package/dist/review/baseline.d.ts.map +1 -0
  185. package/dist/review/baseline.js +35 -0
  186. package/dist/review/baseline.js.map +1 -0
  187. package/dist/review/diff.d.ts +7 -0
  188. package/dist/review/diff.d.ts.map +1 -0
  189. package/dist/review/diff.js +41 -0
  190. package/dist/review/diff.js.map +1 -0
  191. package/dist/review/glob.d.ts +2 -0
  192. package/dist/review/glob.d.ts.map +1 -0
  193. package/dist/review/glob.js +2 -0
  194. package/dist/review/glob.js.map +1 -0
  195. package/dist/review/probes.d.ts +13 -0
  196. package/dist/review/probes.d.ts.map +1 -0
  197. package/dist/review/probes.js +45 -0
  198. package/dist/review/probes.js.map +1 -0
  199. package/dist/review/resolve.d.ts +29 -0
  200. package/dist/review/resolve.d.ts.map +1 -0
  201. package/dist/review/resolve.js +87 -0
  202. package/dist/review/resolve.js.map +1 -0
  203. package/dist/review/review-packet.d.ts +40 -0
  204. package/dist/review/review-packet.d.ts.map +1 -0
  205. package/dist/review/review-packet.js +139 -0
  206. package/dist/review/review-packet.js.map +1 -0
  207. package/dist/scan/check-files.d.ts +23 -0
  208. package/dist/scan/check-files.d.ts.map +1 -0
  209. package/dist/scan/check-files.js +90 -0
  210. package/dist/scan/check-files.js.map +1 -0
  211. package/dist/scan/check-scaffold.d.ts +7 -0
  212. package/dist/scan/check-scaffold.d.ts.map +1 -0
  213. package/dist/scan/check-scaffold.js +37 -0
  214. package/dist/scan/check-scaffold.js.map +1 -0
  215. package/dist/scan/constants.d.ts +21 -0
  216. package/dist/scan/constants.d.ts.map +1 -0
  217. package/dist/scan/constants.js +21 -0
  218. package/dist/scan/constants.js.map +1 -0
  219. package/dist/scan/file-kind.d.ts +12 -0
  220. package/dist/scan/file-kind.d.ts.map +1 -0
  221. package/dist/scan/file-kind.js +114 -0
  222. package/dist/scan/file-kind.js.map +1 -0
  223. package/dist/scan/fingerprint-package-loader.d.ts +5 -0
  224. package/dist/scan/fingerprint-package-loader.d.ts.map +1 -0
  225. package/dist/scan/fingerprint-package-loader.js +105 -0
  226. package/dist/scan/fingerprint-package-loader.js.map +1 -0
  227. package/dist/scan/fingerprint-package.d.ts +58 -0
  228. package/dist/scan/fingerprint-package.d.ts.map +1 -0
  229. package/dist/scan/fingerprint-package.js +301 -0
  230. package/dist/scan/fingerprint-package.js.map +1 -0
  231. package/dist/scan/index.d.ts +3 -0
  232. package/dist/scan/index.d.ts.map +1 -0
  233. package/dist/scan/index.js +3 -0
  234. package/dist/scan/index.js.map +1 -0
  235. package/dist/scan/lint.d.ts +15 -0
  236. package/dist/scan/lint.d.ts.map +1 -0
  237. package/dist/scan/lint.js +2 -0
  238. package/dist/scan/lint.js.map +1 -0
  239. package/dist/scan/node-files.d.ts +25 -0
  240. package/dist/scan/node-files.d.ts.map +1 -0
  241. package/dist/scan/node-files.js +114 -0
  242. package/dist/scan/node-files.js.map +1 -0
  243. package/dist/scan/package-paths.d.ts +10 -0
  244. package/dist/scan/package-paths.d.ts.map +1 -0
  245. package/dist/scan/package-paths.js +49 -0
  246. package/dist/scan/package-paths.js.map +1 -0
  247. package/dist/scan/steering-template.d.ts +8 -0
  248. package/dist/scan/steering-template.d.ts.map +1 -0
  249. package/dist/scan/steering-template.js +266 -0
  250. package/dist/scan/steering-template.js.map +1 -0
  251. package/dist/scan/tarball.d.ts +23 -0
  252. package/dist/scan/tarball.d.ts.map +1 -0
  253. package/dist/scan/tarball.js +145 -0
  254. package/dist/scan/tarball.js.map +1 -0
  255. package/dist/scan/templates.d.ts +24 -0
  256. package/dist/scan/templates.d.ts.map +1 -0
  257. package/dist/scan/templates.js +295 -0
  258. package/dist/scan/templates.js.map +1 -0
  259. package/dist/skill-bundle/SKILL.md +140 -0
  260. package/dist/skill-bundle/references/authoring-scenarios.md +147 -0
  261. package/dist/skill-bundle/references/blocks.md +180 -0
  262. package/dist/skill-bundle/references/brief.md +49 -0
  263. package/dist/skill-bundle/references/capture.md +377 -0
  264. package/dist/skill-bundle/references/recall.md +38 -0
  265. package/dist/skill-bundle/references/schema.md +119 -0
  266. package/dist/skill-bundle/references/self-check.md +65 -0
  267. package/dist/skill-bundle/references/steering-audit.md +61 -0
  268. package/dist/skill-bundle/references/wild.md +30 -0
  269. package/package.json +79 -0
@@ -0,0 +1,147 @@
1
+ ---
2
+ name: authoring-scenarios
3
+ description: Choose the right human-agent workflow for authoring Ghost brand fingerprints.
4
+ handoffs:
5
+ - label: Validate the fingerprint
6
+ command: ghost validate --format json
7
+ prompt: Classify this fingerprint's authoring scenario and confirm the package validates.
8
+ ---
9
+
10
+ # Recipe: Collaborative Fingerprint Authoring
11
+
12
+ **Goal:** help a human and agent co-author durable brand truths through
13
+ conversation — without laundering what a codebase happens to do into what the
14
+ brand means.
15
+
16
+ The fingerprint is medium-agnostic and is not derived from a repo. Its raw
17
+ material is **elicitation**: what the human says, shows, and points at — words,
18
+ screenshots, links, exemplar products, marketing copy, a competitor they define
19
+ themselves against. Agent synthesis is draft work until the human curates it
20
+ and ordinary Git review accepts it.
21
+
22
+ Repo-bound reality — components, tokens, paths, building blocks — can be
23
+ recorded as `materials` on the node whose prose explains their purpose. When a
24
+ conversation surfaces "we have a component for that," treat it as material to
25
+ locate and interpret, not as brand truth by itself.
26
+
27
+ ## 1. Start With One Repeated Decision
28
+
29
+ Do not try to fingerprint the whole brand at once. Ask the human for the one
30
+ decision whose feedback keeps repeating — the checkout always flagged for
31
+ trust, the voice always re-toned, the empty state always rewritten — and
32
+ capture that one truth as a node first. One high-confidence truth beats an
33
+ empty catalog; the fingerprint grows as the next repeated decision shows up.
34
+
35
+ The scenario below tunes the authoring *posture* for that first node; it is not
36
+ a gate to clear before writing anything.
37
+
38
+ | Scenario | Default authoring posture |
39
+ | --- | --- |
40
+ | Net new brand | Stance-first. Elicit feel, audience, and early anti-goals before anything else exists to point at. |
41
+ | Established brand, first fingerprint | Artifact-rich interview. The human can show a lot — shipped surfaces, brand docs, campaigns. Elicit which of it is *intentional*. |
42
+ | Strong opinions, weak articulation | Example-led. The human knows it when they see it: work from exemplars and counter-exemplars ("this feels like us, this never would") toward the stance underneath. |
43
+ | Brand doc or design-language deck exists | Distillation. The document is testimony, not truth: pull the claims that actually steer decisions, drop the aspirational filler, and have the human ratify each survivor. |
44
+ | Rebrand, redesign, migration | Transition-led. Capture current, target, and what must not be lost in between. |
45
+ | Fork, white label, tenant variant | Shared base + local divergence. Keep common truths broad; scope divergence with conditions. |
46
+ | Monorepo or product suite | One contract per package. |
47
+
48
+ If more than one applies, start with the broad scenario, then narrow.
49
+
50
+ ## 2. Interview The Human
51
+
52
+ The interview is the engine. Ask only high-leverage questions that change the
53
+ fingerprint:
54
+
55
+ - What should this brand feel like, and what should it never become? (The
56
+ "never become" answers are anti-goal nodes — capture them with the same care
57
+ as the affirmative stance.)
58
+ - Who is the audience, and what are they trying to get done?
59
+ - Which surfaces, campaigns, or moments show the brand at its best? Show me.
60
+ - Which brand or product do you admire — and where do you deliberately differ?
61
+ (The deliberate differences also route to anti-goal nodes: the rejected
62
+ neighbor, named.)
63
+ - What keeps getting flagged in review, re-toned, or rewritten?
64
+ - Where do trust, density, pacing, accessibility, recovery, or disclosure
65
+ matter most?
66
+ - Which truths are universal, and which only hold under a specific situation?
67
+
68
+ Capture human-authored or human-approved answers as nodes. Do not treat
69
+ unapproved notes as canonical.
70
+
71
+ ## 3. Work The Material The Human Brings
72
+
73
+ Ask for artifacts and read them closely: screenshots, links, exemplar products,
74
+ brand docs, marketing copy, past campaigns, a rejected design and why it was
75
+ rejected. Treat every artifact as *testimony* — evidence of a stance the human
76
+ holds — never as truth by itself. A pattern that appears everywhere may be
77
+ legacy; a pattern that appears once may be the brand at its best. The human
78
+ says which.
79
+
80
+ Counter-exemplars are as valuable as exemplars when they name the replacement.
81
+ "We would never ship this; we would ship that instead" with artifacts attached
82
+ usually yields a sharper guard than an hour of affirmative description. Avoid
83
+ blacklist-only anti-goals: the rejected pattern should be purged from exemplars
84
+ and enforced in review, not repeated as the model's main example.
85
+
86
+ ## 4. Draft The Nodes
87
+
88
+ Write the smallest useful set of nodes, each a purpose-coherent prose truth with
89
+ a one-line `description`, named `<kind>.<slug>.md` (or a bare slug when no kind is present). Ask three questions of each body: why (the stance), with what
90
+ (the materials), and how it is assembled (the patterns). These are drafting
91
+ prompts, not fields.
92
+
93
+ Draft only what the human said or showed. State universal truths plainly; give
94
+ narrower truths a **condition** in the prose — the situation they apply in,
95
+ never a destination. Label uncertain reasoning as provisional. Prefer a few
96
+ high-confidence truths over a broad catalog. Hold draft prose to the node prose
97
+ stances in [capture.md](capture.md) and score each node against its drafting
98
+ gate before presenting drafts for curation.
99
+
100
+ ## 5. Curate With The Human
101
+
102
+ Before treating draft content as durable, ask the human to classify important
103
+ claims:
104
+
105
+ - keep as canonical
106
+ - soften into guidance
107
+ - reject as accidental or legacy
108
+ - move to scratch notes
109
+ - restate at a broader or narrower altitude (add or drop a condition)
110
+
111
+ ## 6. Decide Kinds And Altitude
112
+
113
+ Two authoring decisions replace any notion of hierarchy:
114
+
115
+ - **Kind** — declare the kind vocabulary in `glossary.md` and name each node
116
+ `<kind>.<slug>.md` so its normative weight is clear. The glossary defines what
117
+ each kind means and how strongly it binds. Use `posture: guard` for
118
+ review-critical replacement nodes, `posture: wild` for opt-in provocations,
119
+ and the default steady posture for ordinary truths. Kinds are your choice;
120
+ Ghost ships no fixed vocabulary.
121
+ - **Altitude** — state a truth at the level it is actually true. Universal → state
122
+ it plainly. Narrower → name the situation that activates it, in the prose. Never
123
+ file a truth by destination (`for-emails.md`); the model reads the condition and
124
+ decides when it applies.
125
+
126
+ ## 7. Validate And Ratify
127
+
128
+ ```bash
129
+ ghost validate .ghost
130
+ ```
131
+
132
+ `validate` checks artifact shape, per-node validity, and that each node's kind
133
+ prefix is a declared glossary kind (undeclared → warning with a "did you
134
+ mean" suggestion). Use ordinary Git review as the approval boundary: uncommitted
135
+ edits are drafts; checked-in nodes are canonical.
136
+
137
+ ## Never
138
+
139
+ - Never derive brand truth from repo code alone; what the codebase repeats may
140
+ be legacy, not stance. Use repo paths as `materials` only after the prose
141
+ truth has been curated.
142
+ - Never draft a node the human neither said nor showed; that is invention
143
+ wearing the brand's clothes.
144
+ - Never treat a brand doc, an artifact, or repetition frequency as brand
145
+ authority; the human ratifies what is intentional.
146
+ - Never invent a hierarchy, inheritance, or edges — the package is flat.
147
+ - Never file a truth by destination; state its condition in the prose.
@@ -0,0 +1,180 @@
1
+ ---
2
+ name: blocks
3
+ description: Author block and material nodes so an agent can match a fingerprint's stance to concrete building blocks.
4
+ handoffs:
5
+ - label: List the node menu
6
+ command: ghost gather
7
+ prompt: What materials does this fingerprint document, and what is absent?
8
+ ---
9
+
10
+ # Recipe: Author Block And Material Nodes
11
+
12
+ **Goal:** when you are documenting the **materials** a brand draws from — its
13
+ building blocks, assets, and reusable pieces — write that prose so an agent can
14
+ translate the fingerprint's stance into concrete building blocks without the
15
+ fingerprint ever naming a component.
16
+
17
+ This is opinionated method, not new schema. **"Block node" is shorthand in this
18
+ recipe, not a Ghost concept**: it means any node whose truth is a reusable
19
+ building block, whatever kind the author's glossary declares for it (`block`,
20
+ `asset`, `pattern`, …). A block node is a node like any other: a markdown file
21
+ with a `description` and a prose body, named `<kind>.<slug>.md` (or a bare
22
+ slug). See [capture.md](capture.md) for the node shape. Block prose can be one
23
+ paragraph inside a broader node, or split across many nodes, one per block,
24
+ whatever keeps each node purpose-coherent.
25
+
26
+ ## Where it sits
27
+
28
+ A fingerprint declares stance. Block and material nodes ground that stance in
29
+ concrete materials — they are what makes a node **concrete** in gather, pull
30
+ ordering, and review matching. A realizing agent **reads** them and matches
31
+ against them. Strip every block node and the fingerprint is still valid — it
32
+ just gives the agent less to draw on, and prose-only steering is weak steering.
33
+ The agent does the matching.
34
+
35
+ ## Concreteness is the grounding dial
36
+
37
+ This trade belongs to the author:
38
+
39
+ - **Abstract materials** (principles, arrangement, no concrete components) →
40
+ leaves the agent more room, grounds it less.
41
+ - **Concrete materials** (named building blocks) → strongly grounds the agent in
42
+ the materials it should reach for, at the cost of that room.
43
+
44
+ Neither is correct. A concrete block node is a deliberate trade, not a leak.
45
+
46
+ ## Tier first: not everything earns a node
47
+
48
+ - **Primitives** (button, input, badge, avatar, spinner…) get **no prose body**
49
+ when the generic form serves. They are shared vocabulary, not stance. If you
50
+ record one at all, give it only a `description` so `gather` can surface it;
51
+ the absence of a body is the signal that training priors are acceptable here.
52
+ When a primitive is itself brand-distinctive (a button whose shape, weight, or
53
+ focus treatment is a recognizable brand move), its *divergence from the
54
+ generic form* is a truth worth a body: state what differs and why, not the
55
+ full API.
56
+ - **Anything that encodes a user moment** (confirmation, plan, task, tool,
57
+ reasoning, sources…) earns **one short prose body**. This is what the method is
58
+ for.
59
+ - The **composer middle** (card, table, form, sidebar…) is a call to weigh. Give
60
+ it a body when its arrangement carries a stance worth matching.
61
+
62
+ If a primitive ever seems to need stance guidance, that is a signal it is doing
63
+ a composer's job. Promote the pattern into a node; do not write a body on the
64
+ primitive.
65
+
66
+ ## The shape of a block node
67
+
68
+ A node like any other. Frontmatter carries `description` (the retrieval payload —
69
+ write one on every block worth matching); the body is prose the agent reasons
70
+ over.
71
+
72
+ **Body:** one short paragraph in a consistent rhythm, *for / reach when / not
73
+ when (use X instead) / never*:
74
+
75
+ - **for**: the user need or moment it exists for, framed as the problem, not the
76
+ widget.
77
+ - **reach when**: phrased as the user's *first question* ("who/what is this?" vs
78
+ "what's happening / what do I do?"). First-question framing forces a clean pick
79
+ between overlapping blocks.
80
+ - **not when**: name the rival node to reach for instead, by its id. This is what
81
+ makes the set navigable — since the package is flat with no edges, the prose
82
+ "not when" *is* the see-also link. Point at the other node's id in the text.
83
+ - **never**: what it must not be conscripted into, so the agent does not stretch
84
+ it to fit.
85
+
86
+ Keep props, markup, and API reference out; the body documents purpose, and the
87
+ implementation beneath it is swappable. Explicit values are the exception when
88
+ the value itself is the brand truth — an exact color, a specific corner radius —
89
+ not a swappable implementation detail.
90
+
91
+ ## How a match runs
92
+
93
+ The agent reads the fingerprint's stance, `gather`s the menu, ranks candidate
94
+ block nodes by description, separates near-neighbors on *not when* and
95
+ *never*, and assembles. The realizing surface authors the chosen blocks in its
96
+ medium. The fingerprint never named a component; the agent bridged via documented
97
+ purpose.
98
+
99
+ ## Curation rule
100
+
101
+ A block earns its node when its purpose is **distinguishable** from every
102
+ other's. Two blocks may overlap heavily and still be distinct *as long as their
103
+ "reach when" answers a different first question*. If they answer the same first
104
+ question, they are one node, not two.
105
+
106
+ ## Worked example
107
+
108
+ These examples use a `block` kind. The starter glossary does not ship one, so
109
+ declare it (or reuse a declared kind such as `pattern`) before copying the
110
+ filenames:
111
+
112
+ ```yaml
113
+ kinds:
114
+ - name: block
115
+ purpose: a reusable building block matched by purpose, not named by component
116
+ ```
117
+
118
+ `block.confirmation.md` (kind `block`, slug `confirmation`):
119
+
120
+ ```markdown
121
+ ---
122
+ description: Gate a consequential action behind explicit user approval.
123
+ ---
124
+ Gates a tool action behind explicit user approval. Reach for it when the user's
125
+ first question is "do I allow this?", when a consequential action needs a human
126
+ decision before it runs. Not when the action is already complete (that's
127
+ `block.tool`) or when no decision is required. It is never a status display;
128
+ with no decision to make, it only manufactures friction.
129
+ ```
130
+
131
+ `block.table.md`:
132
+
133
+ ```markdown
134
+ ---
135
+ description: Present many records across shared, comparable columns.
136
+ ---
137
+ Presents many records across shared, comparable columns. Reach for it when the
138
+ user's first question is "how do these compare across the same attributes?" Not
139
+ when each item needs rich, non-uniform presentation (use repeated `block.card`)
140
+ or there is a single subject rather than a collection. It is never a single
141
+ record's detail view.
142
+ ```
143
+
144
+ `block.button.md`:
145
+
146
+ ```markdown
147
+ ---
148
+ description: A primitive action trigger.
149
+ ---
150
+ ```
151
+
152
+ (A primitive the generic form serves: a `description` so `gather` can surface
153
+ it, no body. If this brand's button were itself a recognizable brand move, its
154
+ divergence from the generic form would earn a short body.)
155
+
156
+ ## Materials: bundle brand-owned materials, reference implementations
157
+
158
+ Use the rule of thumb literally. Bundle brand-owned materials: brand-owned artifacts that
159
+ should travel with the fingerprint and survive export or refactors — tokens.css,
160
+ motion.json, logo.svg, type materials. Reference implementations: living app
161
+ code, components, stories, or tests whose home is still the product repo. The
162
+ `materials` list locates both; the prose says what the material proves.
163
+
164
+ ## Reuse vs. free-compose
165
+
166
+ Do not pin a block by prop or markup shape. Document the *purpose* and any
167
+ *guarantees* a block must hold (an action routes through a declared tool, a
168
+ control is keyboard-reachable). Let the realizing agent author the form. Pinning
169
+ prop APIs re-imports implementation opinion and creates a mirror to maintain.
170
+
171
+ ## Never
172
+
173
+ - Never write a prose body on a primitive the generic form serves; the absence
174
+ of a body is the signal. A brand-distinctive primitive earns a body for its
175
+ divergence, never for its API.
176
+ - Never put props, markup, or API reference in a block body; explicit
177
+ values belong only when the value itself is the brand truth.
178
+ - Never let the fingerprint reference the realizing surface; blocks are read,
179
+ not addressed.
180
+ - Never split two blocks that answer the same first question; that is one node.
@@ -0,0 +1,49 @@
1
+ ---
2
+ name: brief
3
+ description: Build a compact pre-generation packet from pulled Ghost truths.
4
+ ---
5
+
6
+ # Recipe: Brief Work From Ghost Fingerprint
7
+
8
+ A brief is an ephemeral steering packet for the generating pass. It is not a new
9
+ schema and is never written back into `.ghost/`.
10
+
11
+ 1. Run `ghost gather <ask> --format json` and select against descriptions.
12
+ 2. Pull a small set: **3–5 nodes is normal; 10 is a bad selection** unless the
13
+ task is unusually broad. Always include `index` unless already read this
14
+ session.
15
+ 3. Prefer concrete nodes: `materials`, substantial fenced examples, or a
16
+ `## Skeleton`. If there is **no concrete material for this surface**, the
17
+ readiness ceiling is **Yellow**.
18
+ 4. Keep provisional reasoning visibly separate from Ghost-backed claims.
19
+
20
+ ## The packet: five sections only
21
+
22
+ Return this shape:
23
+
24
+ ```markdown
25
+ ## Grounded in
26
+ - `node.id` — why it was selected
27
+
28
+ ## Non-negotiables
29
+ - ≤5 lines, each cited to a node id
30
+
31
+ ## Materials inline
32
+ - concrete locators, inlined snippets, inspect-pointers, and what to view/use
33
+
34
+ ## Skeleton
35
+ - matching pulled Skeleton, or "none pulled"
36
+
37
+ ## Silent / provisional
38
+ - what Ghost does not cover and what local evidence carries
39
+ ```
40
+
41
+ Rules:
42
+
43
+ - Do not add sections for every kind. Sections dilute instruction weight.
44
+ - Treat `ghost pull` ordering as signal: stance first, concrete material next,
45
+ prose rules, guards late, Skeletons dead last.
46
+ - If a pulled Skeleton matches the surface, begin the artifact from it verbatim
47
+ before filling.
48
+ - Guards (`posture: guard`) are review-critical anti-goals: state the positive
49
+ replacement, not just the rejected pattern.