@zalom/plastic 1.14.0 → 2.0.0-alpha.1

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 (190) hide show
  1. package/PLASTIC.md +101 -294
  2. package/README.md +5 -6
  3. package/agents/plastic-advisor.md +18 -17
  4. package/agents/plastic-enforcer.md +57 -69
  5. package/agents/plastic-executor.md +34 -20
  6. package/agents/plastic-faux-advisor.md +18 -18
  7. package/config_asks.yml +38 -0
  8. package/hooks/capture +4 -0
  9. package/hooks/check-update +12 -3
  10. package/hooks/close +5 -0
  11. package/hooks/hooks.json +9 -49
  12. package/hooks/record +4 -0
  13. package/package.json +3 -2
  14. package/scripts/agent-report +8 -9
  15. package/scripts/append-ledger +195 -0
  16. package/scripts/codex-hook +101 -95
  17. package/scripts/dashboard.rb +4 -4
  18. package/scripts/doctor.rb +106 -43
  19. package/scripts/end-intent +77 -76
  20. package/scripts/exec-worktree +11 -20
  21. package/scripts/file-session-intent +61 -0
  22. package/scripts/hook-capture +242 -0
  23. package/scripts/hook-close +34 -0
  24. package/scripts/hook-record +149 -0
  25. package/scripts/hook-session-start +95 -12
  26. package/scripts/install.rb +8 -6
  27. package/scripts/lib/agent_models.rb +1 -7
  28. package/scripts/lib/arm.rb +283 -0
  29. package/scripts/lib/backfill_intent.rb +316 -0
  30. package/scripts/lib/bridge.rb +24 -1597
  31. package/scripts/lib/doctor_core.rb +17 -88
  32. package/scripts/lib/doctor_session_ledger.rb +106 -0
  33. package/scripts/lib/exec_worktree.rb +14 -60
  34. package/scripts/lib/harness_text.rb +5 -4
  35. package/scripts/lib/hook_registry.rb +44 -107
  36. package/scripts/lib/insights.rb +3 -4
  37. package/scripts/lib/installer_core.rb +19 -30
  38. package/scripts/lib/lock.rb +6 -26
  39. package/scripts/lib/outcome_guard.rb +7 -5
  40. package/scripts/lib/project_validator.rb +30 -1
  41. package/scripts/lib/roadmap_queue.rb +3 -3
  42. package/scripts/lib/roadmap_savepoint.rb +1 -1
  43. package/scripts/lib/rule_catalog.rb +6 -3
  44. package/scripts/lib/savepoint.rb +320 -0
  45. package/scripts/lib/scaffold_intent.rb +13 -179
  46. package/scripts/lib/session_backfill.rb +184 -0
  47. package/scripts/lib/session_close.rb +84 -0
  48. package/scripts/lib/session_git.rb +469 -0
  49. package/scripts/lib/session_ledger.rb +497 -0
  50. package/scripts/lib/store_discovery.rb +1 -1
  51. package/scripts/lib/store_provisioning.rb +1 -1
  52. package/scripts/maintenance-run +7 -7
  53. package/scripts/new-intent +63 -4
  54. package/scripts/plastic-lock +94 -41
  55. package/scripts/promote-session-item +150 -0
  56. package/scripts/rebuild-graph +1 -1
  57. package/scripts/roadmap-next +2 -2
  58. package/scripts/rollback.rb +42 -3
  59. package/scripts/scaffold-intent +37 -63
  60. package/scripts/session-commit +116 -0
  61. package/scripts/spawn-preamble +5 -5
  62. package/scripts/update.rb +7 -3
  63. package/skills/agent-advisor/SKILL.md +3 -3
  64. package/skills/agent-advisor/references/advisor-protocol.md +20 -20
  65. package/skills/auto/SKILL.md +218 -317
  66. package/skills/auto/evals/evals.json +10 -10
  67. package/skills/auto/references/agent-architecture.md +102 -90
  68. package/skills/auto/references/agent-report-contract.md +4 -21
  69. package/skills/auto/references/end-tail.md +47 -53
  70. package/skills/auto/references/human-report-contract.md +8 -8
  71. package/skills/conventions/SKILL.md +1 -3
  72. package/skills/conventions/references/lifecycle-and-savepoints.md +35 -1
  73. package/skills/conventions/references/locks-and-worktrees.md +47 -55
  74. package/skills/conventions/references/maintenance-and-revisions.md +12 -12
  75. package/skills/dashboard/SKILL.md +1 -1
  76. package/skills/direct/SKILL.md +66 -0
  77. package/skills/direct/references/request-signals.md +59 -0
  78. package/skills/doctor/SKILL.md +58 -11
  79. package/skills/doctor/report.md +3 -1
  80. package/skills/install/SKILL.md +11 -9
  81. package/skills/intent-continuing/SKILL.md +131 -89
  82. package/skills/intent-continuing/references/boarding-matrix.md +34 -0
  83. package/skills/intent-continuing/references/context-management.md +2 -2
  84. package/skills/intent-creating/SKILL.md +2 -2
  85. package/skills/intent-creating/references/lifecycle.md +1 -1
  86. package/skills/intent-ending/SKILL.md +28 -37
  87. package/skills/intent-ending/evals/evals.json +4 -4
  88. package/skills/intent-executing/SKILL.md +12 -49
  89. package/skills/intent-executing/plan-reviewer-prompt.md +39 -0
  90. package/skills/intent-speccing/SKILL.md +108 -51
  91. package/skills/intent-speccing/evals/evals.json +5 -5
  92. package/skills/intent-speccing/references/per-section-fill-rules.md +4 -4
  93. package/skills/intent-speccing/references/self-verify-checklist.md +1 -2
  94. package/skills/project-creating/SKILL.md +1 -1
  95. package/skills/releasing/SKILL.md +7 -8
  96. package/skills/tutorial/SKILL.md +2 -2
  97. package/skills/tutorial/references/track-1-guided.md +16 -18
  98. package/skills/tutorial/references/track-2-auto.md +12 -13
  99. package/skills/tutorial/references/track-3-projects-and-roadmaps.md +2 -2
  100. package/templates/agents.md +4 -7
  101. package/templates/project.yml +7 -0
  102. package/templates/roadmap.md +1 -1
  103. package/templates/savepoint.md +2 -2
  104. package/templates/session-intent.md +29 -0
  105. package/agents/plastic-brainstorming.md +0 -48
  106. package/agents/plastic-future-intent-researcher.md +0 -35
  107. package/agents/plastic-intent-curator.md +0 -47
  108. package/agents/plastic-intent-discovery.md +0 -43
  109. package/agents/plastic-planner.md +0 -56
  110. package/agents/plastic-spec-specialist.md +0 -53
  111. package/hooks/auto-arm +0 -5
  112. package/hooks/bash-gate +0 -3
  113. package/hooks/continue +0 -31
  114. package/hooks/edit-gates +0 -3
  115. package/hooks/future-intent-check +0 -25
  116. package/hooks/gate-check +0 -12
  117. package/hooks/power-tools +0 -8
  118. package/scripts/hook-auto-arm +0 -51
  119. package/scripts/hook-bash-gate +0 -78
  120. package/scripts/hook-code-gate +0 -38
  121. package/scripts/hook-continue +0 -48
  122. package/scripts/hook-create-gate +0 -51
  123. package/scripts/hook-edit-gates +0 -58
  124. package/scripts/hook-future-intent-check +0 -90
  125. package/scripts/hook-gate-check +0 -169
  126. package/scripts/hook-links-gate +0 -54
  127. package/scripts/hook-lock-gate +0 -47
  128. package/scripts/hook-power-tools +0 -38
  129. package/scripts/hook-savepoint-pre +0 -32
  130. package/scripts/lib/codex_edit_gates.rb +0 -138
  131. package/scripts/lib/edit_gates.rb +0 -398
  132. package/scripts/lib/links_gate.rb +0 -140
  133. package/scripts/lib/qmd_hook.rb +0 -41
  134. package/scripts/lib/spec_header.rb +0 -83
  135. package/scripts/lib/start_intent.rb +0 -296
  136. package/scripts/start-intent +0 -89
  137. package/skills/_active-intent-gate.md +0 -26
  138. package/skills/auto/references/tiers.md +0 -100
  139. package/skills/continuing/SKILL.md +0 -34
  140. package/skills/continuing/evals/evals.json +0 -91
  141. package/skills/conventions/references/gates-and-enforcement.md +0 -53
  142. package/skills/conventions/references/tiers-and-dispatch.md +0 -135
  143. package/skills/doctor/references/gates-stuck-detection.md +0 -43
  144. package/skills/intent-brainstorming/SKILL.md +0 -118
  145. package/skills/intent-brainstorming/evals/evals.json +0 -67
  146. package/skills/intent-continuing/evals/evals.json +0 -145
  147. package/skills/intent-discovering/SKILL.md +0 -56
  148. package/skills/intent-grilling/SKILL.md +0 -108
  149. package/skills/intent-linking/SKILL.md +0 -128
  150. package/skills/intent-linking/evals/evals.json +0 -22
  151. package/skills/intent-linking/references/zettelkasten.md +0 -45
  152. package/skills/intent-locking/SKILL.md +0 -64
  153. package/skills/intent-planning/SKILL.md +0 -145
  154. package/skills/intent-planning/evals/evals.json +0 -81
  155. package/skills/intent-planning/references/plan-format.md +0 -130
  156. package/skills/intent-researching/SKILL.md +0 -123
  157. package/skills/intent-researching/evals/evals.json +0 -22
  158. package/skills/intent-savepoint/SKILL.md +0 -83
  159. package/skills/intent-savepoint/references/context-management.md +0 -32
  160. package/skills/intent-starting/SKILL.md +0 -151
  161. package/skills/intent-starting/evals/evals.json +0 -117
  162. package/skills/intent-starting/references/boarding-matrix.md +0 -35
  163. package/skills/project-continuing/SKILL.md +0 -119
  164. package/skills/project-continuing/evals/evals.json +0 -100
  165. package/skills/roadmap-continuing/SKILL.md +0 -89
  166. package/skills/roadmap-continuing/evals/evals.json +0 -82
  167. package/skills/skill-creating/SKILL.md +0 -75
  168. package/skills/skill-creating/evals/evals.json +0 -108
  169. package/skills/skill-creating/references/agents.md +0 -168
  170. package/skills/skill-creating/references/defaults-first.md +0 -23
  171. package/skills/skill-creating/references/evals.md +0 -41
  172. package/skills/skill-creating/references/hooks.md +0 -251
  173. package/skills/skill-creating/references/progressive-disclosure.md +0 -176
  174. package/skills/skill-creating/references/scripts.md +0 -166
  175. package/skills/skill-creating/references/skills.md +0 -169
  176. package/skills/skill-creating/scripts/scaffold.rb +0 -313
  177. package/skills/skill-evaluating/SKILL.md +0 -141
  178. package/skills/skill-evaluating/assets/eval-template.json +0 -12
  179. package/skills/skill-evaluating/evals/evals.json +0 -75
  180. package/skills/skill-evaluating/references/convention-checks.md +0 -76
  181. package/skills/skill-evaluating/references/eval-methodology.md +0 -154
  182. package/skills/store-curating/SKILL.md +0 -64
  183. package/skills/store-curating/evals/evals.json +0 -38
  184. package/skills/store-indexing/SKILL.md +0 -93
  185. package/skills/store-indexing/evals/evals.json +0 -22
  186. package/skills/store-indexing/references/zettelkasten-linking.md +0 -32
  187. package/skills/store-provisioning/SKILL.md +0 -55
  188. /package/skills/{project-continuing → intent-continuing}/references/board-fill.md +0 -0
  189. /package/skills/{roadmap-continuing → intent-continuing}/references/liveness-ranking.md +0 -0
  190. /package/skills/{intent-brainstorming → intent-speccing}/references/design-principles.md +0 -0
@@ -0,0 +1,116 @@
1
+ #!/usr/bin/env ruby
2
+ # encoding: UTF-8
3
+ # frozen_string_literal: true
4
+
5
+ # session-commit (intent 300) - makes one commit for a verified checklist
6
+ # item on the right branch of the repo that contains `--cwd`, applying the
7
+ # branch model and per-repo flow settings in `scripts/lib/session_git.rb`.
8
+ # Idempotent and fail-open: no repository, a detached HEAD, a clean tree, an
9
+ # agent-owned branch, a refused push, a missing `gh`, or a rejected
10
+ # commit-msg hook all degrade to no commit plus a Note savepoint line,
11
+ # never a non-zero exit (spec D1).
12
+ #
13
+ # Usage:
14
+ # session-commit --cwd <dir> --summary <text> [--session <id>] [--day <YYYYMMDD>]
15
+ # [--store <dir>] [--plastic-home <dir>]
16
+ #
17
+ # Exit codes:
18
+ # 0 - always, except a usage error
19
+ # 2 - usage error (missing --cwd or --summary); nothing is written
20
+
21
+ require "fileutils"
22
+ require_relative "lib/session_git"
23
+ require_relative "lib/session_ledger"
24
+
25
+ def usage_abort(message)
26
+ warn "session-commit: #{message}"
27
+ exit 2
28
+ end
29
+
30
+ def next_value!(argv, i, flag)
31
+ usage_abort("#{flag} requires a value") if i + 1 >= argv.length
32
+ argv[i + 1]
33
+ end
34
+
35
+ def parse_args(argv)
36
+ opts = { cwd: nil, summary: nil, session: nil, day: nil, store: nil, plastic_home: nil }
37
+ i = 0
38
+ while i < argv.length
39
+ arg = argv[i]
40
+ case arg
41
+ when "--cwd" then opts[:cwd] = next_value!(argv, i, arg); i += 1
42
+ when "--summary" then opts[:summary] = next_value!(argv, i, arg); i += 1
43
+ when "--session" then opts[:session] = next_value!(argv, i, arg); i += 1
44
+ when "--day" then opts[:day] = next_value!(argv, i, arg); i += 1
45
+ when "--store" then opts[:store] = next_value!(argv, i, arg); i += 1
46
+ when "--plastic-home" then opts[:plastic_home] = next_value!(argv, i, arg); i += 1
47
+ else
48
+ usage_abort("unknown flag #{arg.inspect}")
49
+ end
50
+ i += 1
51
+ end
52
+ opts
53
+ end
54
+
55
+ def expand(path)
56
+ File.expand_path(path.to_s.sub(/\A~/, Dir.home))
57
+ end
58
+
59
+ # Sibling of this script's dir, matching append-ledger's own resolution:
60
+ # in-repo (<repo>/scripts/session-commit -> <repo>/templates) and installed
61
+ # (~/.plastic/scripts/session-commit -> ~/.plastic/templates).
62
+ def default_templates_dir
63
+ File.expand_path("../templates", __dir__)
64
+ end
65
+
66
+ # The fail-open guarantee (spec D1: exit 0 always, except a usage error)
67
+ # must survive a store or ledger failure too (review R2), not only a git
68
+ # failure: a read-only store, a damaged install missing templates/, or any
69
+ # other write failure used to sit outside every rescue, so the CLI could
70
+ # exit 1 with a raw Ruby backtrace on stderr and zero savepoint lines, even
71
+ # after the git commit itself had already landed. `main`'s own body is
72
+ # wrapped so nothing here can turn into a crash; the ledger write is a
73
+ # second, inner rescue so a lost savepoint line never also swallows the
74
+ # result the caller already needs on stdout.
75
+ def main(argv)
76
+ opts = parse_args(argv)
77
+ usage_abort("--cwd is required") if opts[:cwd].nil?
78
+ usage_abort("--summary is required") if opts[:summary].nil?
79
+
80
+ plastic_home = expand(opts[:plastic_home] || ENV.fetch("PLASTIC_HOME", "~/.plastic"))
81
+ store = opts[:store] ? expand(opts[:store]) : File.join(plastic_home, "store")
82
+ cwd = expand(opts[:cwd])
83
+
84
+ day = opts[:day] || SessionLedger.day_id
85
+ session = SessionLedger.short_session_id(opts[:session], ENV["CLAUDE_CODE_SESSION_ID"])
86
+ project = SessionLedger.project_slug(cwd, plastic_home: plastic_home)
87
+
88
+ begin
89
+ templates = default_templates_dir
90
+ SessionLedger.open_day(store: store, day: day, templates: templates, author: session) if Dir.exist?(templates)
91
+ rescue StandardError => e
92
+ warn "session-commit: could not open the day ledger: #{e.message}"
93
+ end
94
+
95
+ result = SessionGit.commit!(cwd: cwd, summary: opts[:summary], day: day, session: session,
96
+ plastic_home: plastic_home, store: store)
97
+
98
+ begin
99
+ # Does not depend on open_day having run: a damaged install with no
100
+ # templates/, or a store error above, must not also block the append.
101
+ savepoint_path = SessionLedger.savepoint_path(store, day)
102
+ FileUtils.mkdir_p(File.dirname(savepoint_path))
103
+ line = SessionLedger.savepoint_line(result.event, session, project, result.message, now: Time.now)
104
+ SessionLedger.append_line(savepoint_path, line, header: nil)
105
+ rescue StandardError => e
106
+ warn "session-commit: could not write the savepoint line: #{e.message}"
107
+ end
108
+
109
+ puts result.message
110
+ exit 0
111
+ rescue StandardError => e
112
+ warn "session-commit: #{e.message}"
113
+ exit 0
114
+ end
115
+
116
+ main(ARGV) if $PROGRAM_NAME == __FILE__
@@ -22,7 +22,7 @@
22
22
  #
23
23
  # Exit codes: 0 (preamble emitted), 2 (usage).
24
24
 
25
- require_relative "lib/bridge"
25
+ require_relative "lib/savepoint"
26
26
  require_relative "lib/worktree"
27
27
 
28
28
  # Verbatim honoring instruction. Kept as one constant so the contract doc and the
@@ -56,7 +56,7 @@ REPORT_CONTRACT =
56
56
  "insights field carrying 0..N durable nuggets (what I discovered worth keeping, " \
57
57
  "the most interesting residue of this turn; none if there were none); plus a " \
58
58
  "role-specific payload that fulfils your place in the What, Why, How, Exec cycle " \
59
- "(for example the planner explains the plan back to the orchestrator). Populate " \
59
+ "(for example the executor reports what was built and the test result). Populate " \
60
60
  "the insights field even when you cannot write the intent file yourself: a " \
61
61
  "background or dispatched agent carries each nugget home in the report and the " \
62
62
  "orchestrator persists it via scripts/insight-append, so an insight never " \
@@ -90,7 +90,7 @@ end
90
90
  # id/intent we report match what the rest of Plastic sees. Returns a Hash (possibly
91
91
  # empty) — never raises.
92
92
  def frontmatter_for(intent_dir)
93
- ifile = Bridge.intent_file(intent_dir)
93
+ ifile = Savepoint.intent_file(intent_dir)
94
94
  return {} unless File.exist?(ifile)
95
95
 
96
96
  content = File.read(ifile)
@@ -116,12 +116,12 @@ STAGE_LABELS = {
116
116
  }.freeze
117
117
 
118
118
  def current_stage(intent_dir)
119
- ledger = File.join(intent_dir, Bridge::SAVEPOINT_FILE)
119
+ ledger = File.join(intent_dir, Savepoint::SAVEPOINT_FILE)
120
120
  if File.exist?(ledger)
121
121
  last = File.read(ledger).each_line.map(&:strip).reject(&:empty?).last
122
122
  return last if last
123
123
  end
124
- STAGE_LABELS.fetch(Bridge.derive_stage(intent_dir), Bridge.derive_stage(intent_dir))
124
+ STAGE_LABELS.fetch(Savepoint.derive_stage(intent_dir), Savepoint.derive_stage(intent_dir))
125
125
  end
126
126
 
127
127
  intent_dir_arg, role, step = parse_args(ARGV)
package/scripts/update.rb CHANGED
@@ -3,7 +3,7 @@
3
3
  # frozen_string_literal: true
4
4
 
5
5
  # Plastic — `update` verb. Runs via `npx @zalom/plastic update` (bin/plastic.js) or directly.
6
- # Usage: ruby scripts/update.rb [--beta|--latest|--alpha] [--claude|--codex|--hermes|--all] [--help]
6
+ # Usage: ruby scripts/update.rb [--beta|--latest|--alpha] [--yes] [--claude|--codex|--hermes|--all] [--help]
7
7
  #
8
8
  # Forward-only version transitions, sourced from npm dist-tags:
9
9
  # - no flag = next version on the CURRENT channel (derived from VERSION)
@@ -62,7 +62,7 @@ class Update < InstallerCore
62
62
  warn "No published version on the #{requested} channel."
63
63
  return 1
64
64
  when :ok
65
- if res[:kind] == :cross_bleeding && !confirm_bleeding(iv, res[:target])
65
+ if res[:kind] == :cross_bleeding && !confirm_bleeding(iv, res[:target], argv)
66
66
  puts "Aborted."
67
67
  return 1
68
68
  end
@@ -222,7 +222,10 @@ class Update < InstallerCore
222
222
  nil
223
223
  end
224
224
 
225
- def confirm_bleeding(current, target)
225
+ # --yes (intent 310) answers the bleeding-edge question without a tty, so a script or an
226
+ # agent can run `update --alpha --yes`; without it a non-tty run aborts as before.
227
+ def confirm_bleeding(current, target, argv = [])
228
+ return true if argv.include?("--yes")
226
229
  return false unless $stdin.tty?
227
230
  print "Switch from #{current} to the less-stable #{target}? [y/N]: "
228
231
  ($stdin.gets&.strip || "").downcase.start_with?("y")
@@ -248,6 +251,7 @@ class Update < InstallerCore
248
251
  --latest Switch to / advance the stable channel
249
252
  --beta Switch to / advance the beta channel
250
253
  --alpha Switch to / advance the alpha channel (bleeding edge — confirmed)
254
+ --yes Confirm a switch toward bleeding edge without a prompt (scripts, agents)
251
255
 
252
256
  Agent options (default: --claude):
253
257
  --claude --codex --hermes --all
@@ -33,7 +33,7 @@ when the ordering decides where you spend the next day.
33
33
  Never buy a consultation for: anything a tool can answer (search, reading code, running
34
34
  tests, documentation), writing code at volume, confirming a decision you already made,
35
35
  style or naming a linter would settle, or anything reversible and cheap you have not
36
- tried first. The full buy/never-buy list, the tier table, and the entry test live in
36
+ tried first. The full buy/never-buy list, the effort table, and the entry test live in
37
37
  `references/advisor-protocol.md`; read it before writing a brief for the first time in
38
38
  a session.
39
39
 
@@ -50,7 +50,7 @@ a session.
50
50
  advisor is disabled and point at "Setting the default" below.
51
51
  4. Dispatch the resolved agent with a brief built per `references/advisor-protocol.md`
52
52
  section 4 (natural prose, the block is a completeness check, not a form to fill).
53
- State TIER (S, M, or L) and EFFORT explicitly; classify low and prove your way up,
53
+ State EFFORT and the answer shape explicitly; classify low and prove your way up,
54
54
  never open high "to be safe".
55
55
  5. Consume the answer per the protocol's section 5: run the Operating Manual's
56
56
  five-question self-test on the advisor's plan before executing it. Advice is input,
@@ -86,7 +86,7 @@ the new default back to the user in one line.
86
86
  ## References
87
87
 
88
88
  - `references/advisor-protocol.md`: the full shipped Advisor Protocol (what to buy,
89
- tiers and effort, the entry test, how to write a brief that earns its cost, the
89
+ effort and answer shape, the entry test, how to write a brief that earns its cost, the
90
90
  answer contract, session economics, anti-patterns). Read it before the first
91
91
  consultation in a session; the second consultation in the same advisor thread costs a
92
92
  fraction of the first, so keep follow-ups on one thread rather than opening a new one.
@@ -5,9 +5,9 @@
5
5
  *Adapted for Plastic (intent 185): this is the shipped reference copy the
6
6
  `plastic-agent-advisor` skill teaches from. Two named agents carry it,
7
7
  `plastic-advisor` (the real advisor) and `plastic-faux-advisor` (the cheaper
8
- imitation, the same discipline at a fraction of the cost); TIER and EFFORT
9
- below shape the brief and the answer on whichever one you dispatch, never
10
- which file to pick, since there is no longer one file per tier. The
8
+ imitation, the same discipline at a fraction of the cost); EFFORT and the
9
+ answer shape below shape the brief and the answer on whichever one you
10
+ dispatch, never which file to pick. The
11
11
  `plastic-agent-advisor` skill reads harness-scoped config
12
12
  (`advisor.claude.default`, falling back to `secondary`, then to
13
13
  `plastic-faux-advisor`) to route your consultation automatically; name a
@@ -53,26 +53,26 @@ You own the work and the outcome. Fable owns the hardest thinking, on demand.
53
53
 
54
54
  ---
55
55
 
56
- ## 2. Tiers and effort
56
+ ## 2. Effort and answer shape
57
57
 
58
- Classify every consultation before sending it. Default to S and prove your way
59
- up. Never open at a higher effort "to be safe": effort follows the cost of being
58
+ Classify every consultation before sending it. Default to the smallest shape and
59
+ prove your way up. Never open at a higher effort "to be safe": effort follows the cost of being
60
60
  wrong, not the importance the task feels like it has.
61
61
 
62
- | Tier | Coding | Business | Research | Effort | Brief size | Expected return |
62
+ | Shape | Coding | Business | Research | Effort | Brief size | Expected return |
63
63
  |------|--------|----------|----------|--------|------------|-----------------|
64
- | **S** | Verdict on one step; choose between two named implementations | Pick between two options you already compared (vendor, pricing point) | Judge whether one source or result is trustworthy enough to build on | `low` | Under 300 words | Verdict, one paragraph of reasoning, the single biggest risk |
65
- | **M** | Plan a feature inside one system; review a full plan for holes; design one interface; rank root causes | Positioning or pricing decision from a compiled evidence pack; review a proposal before sending it | Design a research plan for a bounded question; rank competing explanations of the data you gathered | `medium`, or `high` if an irreversible step is inside | Up to one page | Decision, numbered plan with per-step checks, risk map |
66
- | **L** | Cross-system architecture; migration with one-way doors; deadlock after two failed attempts; security-critical design | Build-vs-buy, market entry, or any commitment measured in months; strategy where reversal is expensive | Synthesis across many sources where the conclusion drives a large bet; contested questions with conflicting evidence | `xhigh`; `max` only when being wrong means data loss, a broken contract, or weeks of rework | Full evidence brief | Decision, plan, risk register, kill criteria, list of what could not be verified |
64
+ | **Verdict** | Verdict on one step; choose between two named implementations | Pick between two options you already compared (vendor, pricing point) | Judge whether one source or result is trustworthy enough to build on | `low` | Under 300 words | Verdict, one paragraph of reasoning, the single biggest risk |
65
+ | **Plan** | Plan a feature inside one system; review a full plan for holes; design one interface; rank root causes | Positioning or pricing decision from a compiled evidence pack; review a proposal before sending it | Design a research plan for a bounded question; rank competing explanations of the data you gathered | `medium`, or `high` if an irreversible step is inside | Up to one page | Decision, numbered plan with per-step checks, risk map |
66
+ | **Architecture** | Cross-system architecture; migration with one-way doors; deadlock after two failed attempts; security-critical design | Build-vs-buy, market entry, or any commitment measured in months; strategy where reversal is expensive | Synthesis across many sources where the conclusion drives a large bet; contested questions with conflicting evidence | `xhigh`; `max` only when being wrong means data loss, a broken contract, or weeks of rework | Full evidence brief | Decision, plan, risk register, kill criteria, list of what could not be verified |
67
67
 
68
- **Escalate one tier when any of these holds:**
68
+ **Escalate one shape when any of these holds:**
69
69
 
70
70
  - Two attempts failed and you cannot explain why.
71
71
  - The next step is irreversible.
72
72
  - The scope crossed a system boundary since you last consulted.
73
73
  - Your confidence has stopped tracking your evidence.
74
74
 
75
- **Front-load.** One L consultation at plan time is cheaper than five M
75
+ **Front-load.** One architecture consultation at plan time is cheaper than five plan
76
76
  consultations during execution. Spend early, at the point of maximum leverage.
77
77
 
78
78
  ---
@@ -142,7 +142,7 @@ briefing described above; use the block as your completeness check before
142
142
  sending. Fable must never need to explore.
143
143
 
144
144
  ```
145
- TIER: S | M | L EFFORT: low | medium | high | xhigh | max
145
+ SHAPE: verdict | plan | architecture EFFORT: low | medium | high | xhigh | max
146
146
  DOMAIN: coding | business | research
147
147
  GOAL: <target state in one sentence, and the decision this answer feeds>
148
148
  QUESTIONS:
@@ -186,7 +186,7 @@ reformat, then work with what you have.
186
186
  verify before starting, which failure mode from the Manual's section 8 that
187
187
  step invites, and the observation that means stop and come back. The plan is
188
188
  written for you to execute at your best, not just to be correct on paper.
189
- 7. **L tier only, kill criteria:** the observation that means abandon this plan.
189
+ 7. **Architecture shape only, kill criteria:** the observation that means abandon this plan.
190
190
 
191
191
  **Consuming the answer:**
192
192
 
@@ -210,12 +210,12 @@ reformat, then work with what you have.
210
210
  consultation on all of them. Five separate S calls that were really one M
211
211
  question is the most common way to overpay.
212
212
  - **Cadence for large work:** at most three consultations. One after
213
- exploration, for plan design (L). One before the irreversible step, for risk
214
- review (S or M). One after implementation, for adversarial review of the
215
- result (M). Everything between those points is your own work.
216
- - **Keep a ledger.** For each consultation record the question, the tier, the
217
- first line of the answer, and what it changed in your actions. If a tier's
218
- answers never change what you do, you are over-buying that tier. Stop.
213
+ exploration, for plan design (architecture). One before the irreversible step, for risk
214
+ review (verdict or plan). One after implementation, for adversarial review of the
215
+ result (plan). Everything between those points is your own work.
216
+ - **Keep a ledger.** For each consultation record the question, the shape, the
217
+ first line of the answer, and what it changed in your actions. If a shape's
218
+ answers never change what you do, you are over-buying that shape. Stop.
219
219
 
220
220
  ---
221
221