litclaude-ai 0.2.2

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 (156) hide show
  1. package/CHANGELOG.md +155 -0
  2. package/LICENSE +21 -0
  3. package/README.md +369 -0
  4. package/README_ko-KR.md +374 -0
  5. package/RELEASE_CHECKLIST.md +165 -0
  6. package/bin/litclaude-ai.js +643 -0
  7. package/cover.png +0 -0
  8. package/docs/agents.md +67 -0
  9. package/docs/hooks.md +134 -0
  10. package/docs/lsp.md +40 -0
  11. package/docs/migration.md +209 -0
  12. package/docs/workflow-compatibility-audit.md +119 -0
  13. package/generate_cover.py +123 -0
  14. package/package.json +48 -0
  15. package/plugins/litclaude/.claude-plugin/plugin.json +25 -0
  16. package/plugins/litclaude/.lsp.json +13 -0
  17. package/plugins/litclaude/.mcp.json +9 -0
  18. package/plugins/litclaude/agents/boulder-executor.md +12 -0
  19. package/plugins/litclaude/agents/librarian-researcher.md +15 -0
  20. package/plugins/litclaude/agents/oracle-verifier.md +16 -0
  21. package/plugins/litclaude/agents/prometheus-planner.md +13 -0
  22. package/plugins/litclaude/agents/qa-runner.md +16 -0
  23. package/plugins/litclaude/agents/quality-reviewer.md +17 -0
  24. package/plugins/litclaude/bin/litclaude-hook.js +110 -0
  25. package/plugins/litclaude/bin/litclaude-hud.js +271 -0
  26. package/plugins/litclaude/bin/litclaude-lsp-doctor.js +15 -0
  27. package/plugins/litclaude/bin/litclaude-mcp.js +70 -0
  28. package/plugins/litclaude/commands/deep-interview.md +21 -0
  29. package/plugins/litclaude/commands/dynamic-workflow.md +36 -0
  30. package/plugins/litclaude/commands/lit-loop.md +40 -0
  31. package/plugins/litclaude/commands/lit-plan.md +35 -0
  32. package/plugins/litclaude/commands/litgoal.md +30 -0
  33. package/plugins/litclaude/commands/review-work.md +35 -0
  34. package/plugins/litclaude/commands/start-work.md +36 -0
  35. package/plugins/litclaude/hooks/hooks.json +54 -0
  36. package/plugins/litclaude/lib/context-pressure.mjs +25 -0
  37. package/plugins/litclaude/lib/hud-accent-palette.mjs +58 -0
  38. package/plugins/litclaude/lib/litgoal/cli.mjs +266 -0
  39. package/plugins/litclaude/lib/litgoal/ledger.mjs +16 -0
  40. package/plugins/litclaude/lib/litgoal/paths.mjs +7 -0
  41. package/plugins/litclaude/lib/litgoal/state.mjs +67 -0
  42. package/plugins/litclaude/lib/mutated-file-paths.mjs +63 -0
  43. package/plugins/litclaude/lib/start-work-continuation.mjs +99 -0
  44. package/plugins/litclaude/lib/workflow-check.mjs +83 -0
  45. package/plugins/litclaude/skills/ai-slop-remover/SKILL.md +142 -0
  46. package/plugins/litclaude/skills/comment-checker/SKILL.md +55 -0
  47. package/plugins/litclaude/skills/debugging/SKILL.md +70 -0
  48. package/plugins/litclaude/skills/debugging/references/methodology/00-setup.md +108 -0
  49. package/plugins/litclaude/skills/debugging/references/methodology/02-investigate.md +126 -0
  50. package/plugins/litclaude/skills/debugging/references/methodology/04-oracle-triple.md +106 -0
  51. package/plugins/litclaude/skills/debugging/references/methodology/05-escalate.md +69 -0
  52. package/plugins/litclaude/skills/debugging/references/methodology/06-fix.md +116 -0
  53. package/plugins/litclaude/skills/debugging/references/methodology/08-qa.md +94 -0
  54. package/plugins/litclaude/skills/debugging/references/methodology/09-cleanup.md +164 -0
  55. package/plugins/litclaude/skills/debugging/references/methodology/partial-runtime-evidence.md +228 -0
  56. package/plugins/litclaude/skills/debugging/references/runtimes/bundled-js-binary.md +415 -0
  57. package/plugins/litclaude/skills/debugging/references/runtimes/go.md +252 -0
  58. package/plugins/litclaude/skills/debugging/references/runtimes/native-binary.md +484 -0
  59. package/plugins/litclaude/skills/debugging/references/runtimes/node.md +260 -0
  60. package/plugins/litclaude/skills/debugging/references/runtimes/python.md +248 -0
  61. package/plugins/litclaude/skills/debugging/references/runtimes/rust.md +234 -0
  62. package/plugins/litclaude/skills/debugging/references/tools/ghidra.md +212 -0
  63. package/plugins/litclaude/skills/debugging/references/tools/playwright-cli.md +194 -0
  64. package/plugins/litclaude/skills/debugging/references/tools/pwndbg.md +263 -0
  65. package/plugins/litclaude/skills/debugging/references/tools/pwntools.md +265 -0
  66. package/plugins/litclaude/skills/deep-interview/SKILL.md +323 -0
  67. package/plugins/litclaude/skills/deep-interview/scripts/render_progress.py +193 -0
  68. package/plugins/litclaude/skills/frontend-ui-ux/SKILL.md +62 -0
  69. package/plugins/litclaude/skills/lit-loop/SKILL.md +144 -0
  70. package/plugins/litclaude/skills/lit-plan/SKILL.md +125 -0
  71. package/plugins/litclaude/skills/litgoal/SKILL.md +219 -0
  72. package/plugins/litclaude/skills/lsp/SKILL.md +63 -0
  73. package/plugins/litclaude/skills/programming/SKILL.md +106 -0
  74. package/plugins/litclaude/skills/programming/references/go/README.md +90 -0
  75. package/plugins/litclaude/skills/programming/references/go/backend-stack.md +641 -0
  76. package/plugins/litclaude/skills/programming/references/go/bootstrap.md +328 -0
  77. package/plugins/litclaude/skills/programming/references/go/bubbletea-v2.md +360 -0
  78. package/plugins/litclaude/skills/programming/references/go/cobra-stack.md +468 -0
  79. package/plugins/litclaude/skills/programming/references/go/concurrency.md +362 -0
  80. package/plugins/litclaude/skills/programming/references/go/data-modeling.md +329 -0
  81. package/plugins/litclaude/skills/programming/references/go/error-handling.md +359 -0
  82. package/plugins/litclaude/skills/programming/references/go/golangci-strict.md +236 -0
  83. package/plugins/litclaude/skills/programming/references/go/grpc-connect.md +375 -0
  84. package/plugins/litclaude/skills/programming/references/go/libraries.md +337 -0
  85. package/plugins/litclaude/skills/programming/references/go/one-liners.md +202 -0
  86. package/plugins/litclaude/skills/programming/references/go/sqlc-pgx.md +471 -0
  87. package/plugins/litclaude/skills/programming/references/go/testing.md +467 -0
  88. package/plugins/litclaude/skills/programming/references/go/type-patterns.md +298 -0
  89. package/plugins/litclaude/skills/programming/references/python/README.md +314 -0
  90. package/plugins/litclaude/skills/programming/references/python/async-anyio.md +442 -0
  91. package/plugins/litclaude/skills/programming/references/python/data-modeling.md +233 -0
  92. package/plugins/litclaude/skills/programming/references/python/data-processing.md +133 -0
  93. package/plugins/litclaude/skills/programming/references/python/error-handling.md +218 -0
  94. package/plugins/litclaude/skills/programming/references/python/fastapi-stack.md +316 -0
  95. package/plugins/litclaude/skills/programming/references/python/httpx2-optimization.md +360 -0
  96. package/plugins/litclaude/skills/programming/references/python/libraries.md +307 -0
  97. package/plugins/litclaude/skills/programming/references/python/one-liners.md +268 -0
  98. package/plugins/litclaude/skills/programming/references/python/orjson-stack.md +378 -0
  99. package/plugins/litclaude/skills/programming/references/python/pydantic-ai.md +285 -0
  100. package/plugins/litclaude/skills/programming/references/python/pyproject-strict.md +232 -0
  101. package/plugins/litclaude/skills/programming/references/python/textual-tui.md +201 -0
  102. package/plugins/litclaude/skills/programming/references/python/type-patterns.md +176 -0
  103. package/plugins/litclaude/skills/programming/references/rust/README.md +317 -0
  104. package/plugins/litclaude/skills/programming/references/rust/async-tokio.md +299 -0
  105. package/plugins/litclaude/skills/programming/references/rust/axum-stack.md +467 -0
  106. package/plugins/litclaude/skills/programming/references/rust/cargo-strict.md +317 -0
  107. package/plugins/litclaude/skills/programming/references/rust/clap-stack.md +409 -0
  108. package/plugins/litclaude/skills/programming/references/rust/concurrency.md +375 -0
  109. package/plugins/litclaude/skills/programming/references/rust/libraries.md +439 -0
  110. package/plugins/litclaude/skills/programming/references/rust/one-liners.md +291 -0
  111. package/plugins/litclaude/skills/programming/references/rust/proptest-insta.md +429 -0
  112. package/plugins/litclaude/skills/programming/references/rust/type-state.md +354 -0
  113. package/plugins/litclaude/skills/programming/references/rust/unsafe-discipline.md +250 -0
  114. package/plugins/litclaude/skills/programming/references/rust/zero-cost-safety.md +527 -0
  115. package/plugins/litclaude/skills/programming/references/rust-ub/README.md +289 -0
  116. package/plugins/litclaude/skills/programming/references/rust-ub/miri-sanitizers-loom.md +411 -0
  117. package/plugins/litclaude/skills/programming/references/rust-ub/ub-taxonomy.md +269 -0
  118. package/plugins/litclaude/skills/programming/references/typescript/README.md +195 -0
  119. package/plugins/litclaude/skills/programming/references/typescript/backend-hono.md +672 -0
  120. package/plugins/litclaude/skills/programming/references/typescript/bootstrap.md +199 -0
  121. package/plugins/litclaude/skills/programming/references/typescript/data-modeling.md +202 -0
  122. package/plugins/litclaude/skills/programming/references/typescript/error-handling.md +169 -0
  123. package/plugins/litclaude/skills/programming/references/typescript/tsconfig-strict.md +152 -0
  124. package/plugins/litclaude/skills/programming/references/typescript/type-patterns.md +196 -0
  125. package/plugins/litclaude/skills/programming/scripts/go/check-no-excuse-rules.sh +173 -0
  126. package/plugins/litclaude/skills/programming/scripts/go/new-project.py +138 -0
  127. package/plugins/litclaude/skills/programming/scripts/go/templates/.editorconfig +13 -0
  128. package/plugins/litclaude/skills/programming/scripts/go/templates/.golangci.yml +95 -0
  129. package/plugins/litclaude/skills/programming/scripts/go/templates/AGENTS.md.tmpl +24 -0
  130. package/plugins/litclaude/skills/programming/scripts/go/templates/README.md.tmpl +12 -0
  131. package/plugins/litclaude/skills/programming/scripts/go/templates/Taskfile.yml +40 -0
  132. package/plugins/litclaude/skills/programming/scripts/go/templates/ci.yml +37 -0
  133. package/plugins/litclaude/skills/programming/scripts/go/templates/config.go +24 -0
  134. package/plugins/litclaude/skills/programming/scripts/go/templates/gitignore +15 -0
  135. package/plugins/litclaude/skills/programming/scripts/go/templates/main.go.tmpl +22 -0
  136. package/plugins/litclaude/skills/programming/scripts/go/templates/run.go +15 -0
  137. package/plugins/litclaude/skills/programming/scripts/python/check-no-excuse-rules.py +687 -0
  138. package/plugins/litclaude/skills/programming/scripts/python/new-project.py +172 -0
  139. package/plugins/litclaude/skills/programming/scripts/python/new-script.py +116 -0
  140. package/plugins/litclaude/skills/programming/scripts/rust/check-no-excuse-rules.py +296 -0
  141. package/plugins/litclaude/skills/programming/scripts/rust/check-no-excuse-rules.sh +158 -0
  142. package/plugins/litclaude/skills/programming/scripts/rust/new-project.py +175 -0
  143. package/plugins/litclaude/skills/programming/scripts/typescript/check-no-excuse-rules.ts +282 -0
  144. package/plugins/litclaude/skills/programming/scripts/typescript/new-project.ts +177 -0
  145. package/plugins/litclaude/skills/refactor/SKILL.md +73 -0
  146. package/plugins/litclaude/skills/remove-ai-slops/SKILL.md +52 -0
  147. package/plugins/litclaude/skills/review-work/SKILL.md +331 -0
  148. package/plugins/litclaude/skills/rules/SKILL.md +66 -0
  149. package/plugins/litclaude/skills/start-work/SKILL.md +132 -0
  150. package/scripts/audit-plan-checkboxes.mjs +37 -0
  151. package/scripts/doctor.mjs +41 -0
  152. package/scripts/inspect-agent-tools.mjs +27 -0
  153. package/scripts/postinstall.mjs +50 -0
  154. package/scripts/qa-claude-plugin-smoke.sh +60 -0
  155. package/scripts/qa-portable-install.sh +136 -0
  156. package/scripts/validate-plugin.mjs +72 -0
@@ -0,0 +1,323 @@
1
+ ---
2
+ name: deep-interview
3
+ description: Socratic deep-interview loop that turns a vague idea into an execution-ready spec, using a quantitative ambiguity score to gate when requirements are clear enough to build. Use this BEFORE planning or implementation whenever a request is broad, underspecified, or missing acceptance criteria — or when the user says "interview me", "ask me everything", "don't assume", or "deep interview".
4
+ argument-hint: "[--quick|--standard|--deep] <idea or vague description>"
5
+ ---
6
+
7
+ <Purpose>
8
+ Deep Interview is an intent-first Socratic clarification loop that runs before planning or implementation. It turns vague ideas into execution-ready specifications by asking targeted questions about why the user wants a change, how far it should go, what should stay out of scope, and what the implementer may decide without confirmation.
9
+ </Purpose>
10
+
11
+ <Use_When>
12
+ - The request is broad, ambiguous, or missing concrete acceptance criteria
13
+ - The user says "deep interview", "interview me", "ask me everything", or "don't assume"
14
+ - The user wants to avoid misaligned implementation from underspecified requirements
15
+ - You need a clear requirements artifact before handing off to planning or implementation
16
+ </Use_When>
17
+
18
+ <Do_Not_Use_When>
19
+ - The request already has concrete file/symbol targets and clear acceptance criteria
20
+ - The user explicitly asks to skip planning/interview and execute immediately
21
+ - The user asks for lightweight, open-ended brainstorming only
22
+ - A complete spec/plan already exists and execution should start
23
+ </Do_Not_Use_When>
24
+
25
+ <Why_This_Exists>
26
+ Execution quality is usually bottlenecked by intent clarity, not just missing implementation detail. A single expansion pass often misses why the user wants a change, where the scope should stop, which tradeoffs are unacceptable, and which decisions still require user approval. This workflow applies Socratic pressure + quantitative ambiguity scoring so downstream planning and execution begin with an explicit, testable, intent-aligned spec.
27
+ </Why_This_Exists>
28
+
29
+ <Depth_Profiles>
30
+ | Profile | Flag | Target ambiguity | Max rounds | Use for |
31
+ |---------|------|-----------------:|-----------:|---------|
32
+ | Quick | `--quick` | ≤ 30% | 5 | Fast pre-spec pass |
33
+ | Standard *(default)* | `--standard` | ≤ 20% | 12 | Full requirement interview |
34
+ | Deep | `--deep` | ≤ 15% | 20 | High-rigor exploration |
35
+
36
+ If no flag is provided, use **Standard**.
37
+ </Depth_Profiles>
38
+
39
+ <Execution_Policy>
40
+ - Ask ONE question per round (never batch)
41
+ - Ask about intent and boundaries before implementation detail
42
+ - Target the weakest clarity dimension each round after applying the stage-priority rules below
43
+ - Treat every answer as a claim to pressure-test before moving on: the next question should usually demand evidence or examples, expose a hidden assumption, force a tradeoff or boundary, or reframe root cause vs symptom
44
+ - Do not rotate to a new clarity dimension just for coverage when the current answer is still vague; stay on the same thread until one layer deeper, one assumption clearer, or one boundary tighter
45
+ - Before crystallizing, complete at least one explicit pressure pass that revisits an earlier answer with a deeper, assumption-focused, or tradeoff-focused follow-up
46
+ - Gather codebase facts with read-only search tools (or an exploration subagent) before asking the user about internals
47
+ - Keep exploration prompts narrow and concrete; fall back to the user only for facts that can't be discovered directly
48
+ - Always run a preflight context intake before the first interview question
49
+ - Reduce user effort: ask only the highest-leverage unresolved question, and never ask the user for codebase facts you can discover yourself
50
+ - For brownfield work, prefer evidence-backed confirmation questions such as "I found X in Y. Should this change follow that pattern?"
51
+ - Prefer a structured user-input tool (`AskUserQuestion` / equivalent) for each round; if none is available, fall back to concise plain-text one-question turns
52
+ - Re-score ambiguity after each answer and show progress transparently
53
+ - Do not hand off to execution while ambiguity remains above threshold unless the user explicitly opts to proceed with warning
54
+ - Do not crystallize or hand off while `Non-goals` or `Decision Boundaries` remain unresolved, even if the weighted ambiguity threshold is met
55
+ - Treat early exit as a safety valve, not the default success path
56
+ - Persist progress to a state file after each round so the interview can resume if interrupted
57
+ </Execution_Policy>
58
+
59
+ <Steps>
60
+
61
+ ## Phase 0: Preflight Context Intake
62
+
63
+ 1. Parse `{{ARGUMENTS}}` and derive a short task slug.
64
+ 2. Attempt to load the latest relevant context snapshot from `deep-interview/{slug}-context.md`.
65
+ 3. If no snapshot exists, create a minimum context snapshot with:
66
+ - Task statement
67
+ - Desired outcome
68
+ - Stated solution (what the user asked for)
69
+ - Probable intent hypothesis (why they likely want it)
70
+ - Known facts/evidence
71
+ - Constraints
72
+ - Unknowns/open questions
73
+ - Decision-boundary unknowns
74
+ - Likely codebase touchpoints
75
+ 4. Save the snapshot to `deep-interview/{slug}-context.md` and reference it in the state file.
76
+
77
+ ## Phase 1: Initialize
78
+
79
+ 1. Parse `{{ARGUMENTS}}` and depth profile (`--quick|--standard|--deep`).
80
+ 2. Detect project context:
81
+ - Classify **brownfield** (existing codebase target) vs **greenfield** using read-only search.
82
+ - For brownfield, collect relevant codebase context before questioning.
83
+ 3. Initialize the state file at `deep-interview/{slug}-state.json`. Set `threshold` and `max_rounds` from the chosen profile (see the Depth Profiles table) — the values below are illustrative:
84
+
85
+ ```json
86
+ {
87
+ "active": true,
88
+ "current_phase": "deep-interview",
89
+ "state": {
90
+ "interview_id": "<uuid>",
91
+ "profile": "quick|standard|deep",
92
+ "type": "greenfield|brownfield",
93
+ "initial_idea": "<user input>",
94
+ "rounds": [],
95
+ "current_ambiguity": 1.0,
96
+ "threshold": 0.2,
97
+ "max_rounds": 12,
98
+ "challenge_modes_used": [],
99
+ "codebase_context": null,
100
+ "current_stage": "intent-first",
101
+ "current_focus": "intent",
102
+ "context_snapshot_path": "deep-interview/<slug>-context.md"
103
+ }
104
+ }
105
+ ```
106
+
107
+ 4. Announce kickoff with a compact banner so the user immediately understands the contract (profile, target, budget, starting point). Render it before the first question:
108
+
109
+ ```
110
+ 🎯 Deep Interview · {Quick|Standard|Deep} · {greenfield|brownfield}
111
+ Goal turn "{short initial idea}" into an execution-ready spec
112
+ Target ambiguity ≤ {threshold}% · Budget up to {max_rounds} rounds
113
+ Starting ambiguity {score}% · One question per round, intent before detail
114
+ ```
115
+
116
+ For a colorized banner, run `scripts/render_progress.py banner --color always ...` via Bash (see the renderer note in 2b).
117
+
118
+ ## Phase 2: Socratic Interview Loop
119
+
120
+ Repeat until ambiguity `<= threshold`, the pressure pass is complete, the readiness gates are explicit, the user exits with warning, or max rounds are reached.
121
+
122
+ ### 2a) Generate next question
123
+ Use:
124
+ - Original idea
125
+ - Prior Q&A rounds
126
+ - Current dimension scores
127
+ - Brownfield context (if any)
128
+ - Activated challenge mode injection (Phase 3)
129
+
130
+ Target the lowest-scoring dimension, but respect stage priority:
131
+ - **Stage 1 — Intent-first:** Intent, Outcome, Scope, Non-goals, Decision Boundaries
132
+ - **Stage 2 — Feasibility:** Constraints, Success Criteria
133
+ - **Stage 3 — Brownfield grounding:** Context Clarity (brownfield only)
134
+
135
+ Follow-up pressure ladder after each answer:
136
+ 1. Ask for a concrete example, counterexample, or evidence signal behind the latest claim
137
+ 2. Probe the hidden assumption, dependency, or belief that makes the claim true
138
+ 3. Force a boundary or tradeoff: what would you explicitly not do, defer, or reject?
139
+ 4. If the answer still describes symptoms, reframe toward essence / root cause before moving on
140
+
141
+ Prefer staying on the same thread for multiple rounds when it has the highest leverage. Breadth without pressure is not progress.
142
+
143
+ Detailed dimensions:
144
+ - Intent Clarity — why the user wants this
145
+ - Outcome Clarity — what end state they want
146
+ - Scope Clarity — how far the change should go
147
+ - Constraint Clarity — technical or business limits that must hold
148
+ - Success Criteria Clarity — how completion will be judged
149
+ - Context Clarity — existing codebase understanding (brownfield only)
150
+
151
+ `Non-goals` and `Decision Boundaries` are mandatory readiness gates. Ask about them early and keep revisiting them until they are explicit.
152
+
153
+ ### 2b) Ask the question
154
+ Lead with a one-glance ambiguity meter so the user always sees how close the spec is to ready and how much budget remains. The meter is a *draining gauge*: the filled cells represent the ambiguity that still remains, and a `┊` tick marks the target — the job each round is to drain the filled edge down to or under the tick. The fill reads red while far from target, amber as it approaches, and green once at or under it.
155
+
156
+ ```
157
+ Round {n}/{max_rounds} · Stage {1-3}: {stage name} · Focus: {weakest_dimension}
158
+ Ambiguity {score}% [███████░░░░░░░░░░░░░░░] target ≤ {threshold}% (┊ tick appears as you drain past it)
159
+ ```
160
+
161
+ Then ask exactly one question.
162
+
163
+ **Optional color rendering (pretty TUI):** for a polished colorized terminal display, render the banner / meter / breakdown with the bundled `scripts/render_progress.py` via the Bash tool — a terminal renders its ANSI color, whereas the assistant's markdown reply channel does not, so never paste raw escape codes into a reply. The script degrades to plain text under `--color never` or `NO_COLOR`, so it's safe everywhere. Example:
164
+
165
+ ```
166
+ python3 scripts/render_progress.py --color always meter \
167
+ --round {n} --max-rounds {max} --stage "{1-3}: {stage}" \
168
+ --focus {dimension} --ambiguity {score} --threshold {threshold}
169
+ ```
170
+
171
+ The inline markdown blocks above are the always-works fallback; reach for the script when a richer TUI is wanted.
172
+
173
+ **Rendering with structured tools:** when `AskUserQuestion` (or equivalent) is available, prefer it for crisp option capture — but those tools don't render the meter inside the prompt. So emit the meter line (or run the script) *immediately before* the tool call, use the focus dimension as the short header chip (e.g. `Scope`, `Non-goals`), and put the round/ambiguity context in the question text. If no structured tool is available, fall back to a plain-text single-question turn with the same meter on top.
174
+
175
+ ### 2c) Score ambiguity
176
+ Score each weighted dimension in `[0.0, 1.0]` with justification + gap.
177
+
178
+ Greenfield: `ambiguity = 1 - (intent × 0.30 + outcome × 0.25 + scope × 0.20 + constraints × 0.15 + success × 0.10)`
179
+
180
+ Brownfield: `ambiguity = 1 - (intent × 0.25 + outcome × 0.20 + scope × 0.20 + constraints × 0.15 + success × 0.10 + context × 0.10)`
181
+
182
+ Readiness gate:
183
+ - `Non-goals` must be explicit
184
+ - `Decision Boundaries` must be explicit
185
+ - A pressure pass must be complete: at least one earlier answer has been revisited with an evidence, assumption, or tradeoff follow-up
186
+ - If either gate is unresolved, or the pressure pass is incomplete, continue interviewing even when weighted ambiguity is below threshold
187
+
188
+ ### 2d) Report progress
189
+ After scoring, show a compact breakdown so the user sees *what moved* and *what's still blocking readiness*. The readiness gates are shown every round (not just at the end), because they can block crystallization even when the weighted score is already under threshold — surfacing them early tells the user exactly why the interview is still open.
190
+
191
+ ```
192
+ Clarity
193
+ Intent ▓▓▓▓▓▓▓▓░░ 0.80 why they want it — clear
194
+ Outcome ▓▓▓▓▓▓░░░░ 0.60 end state — partially defined
195
+ Scope ▓▓▓▓░░░░░░ 0.40 ← weakest, next focus
196
+ Constraints ▓▓▓▓▓▓▓░░░ 0.70 limits mostly known
197
+ Success ▓▓▓░░░░░░░ 0.30 no acceptance criteria yet
198
+ (Context) ▓▓▓▓▓░░░░░ 0.50 brownfield only
199
+
200
+ Readiness gates
201
+ ✅ Non-goals explicit ⬜ Decision Boundaries ✅ Pressure pass done
202
+ → blocked by: Decision Boundaries (not yet explicit)
203
+
204
+ Ambiguity {prev}% → {new}% · Next: {weakest_dimension}
205
+ ```
206
+
207
+ Use `✅` for met gates and `⬜` for open ones, and name what's blocking. If all gates are met and ambiguity is under threshold, say so plainly: "All gates met — ready to crystallize." For the colorized version, run `scripts/render_progress.py breakdown --color always --scores "Intent=0.80,..." --gates "nongoals=1,boundaries=0,pressure=1" --threshold {t} --prev {p} --ambiguity {a} --next {dim}` via Bash.
208
+
209
+ ### 2e) Persist state
210
+ Append the round result and updated scores to the state file.
211
+
212
+ ### 2f) Round controls
213
+ - Do not offer early exit before the first explicit assumption probe and one persistent follow-up have happened
214
+ - Round 4+: allow explicit early exit with risk warning. Make it visible once available — add a quiet footer line so the user knows the escape hatch exists, e.g. `(You can say "good enough" to stop early and crystallize with the current clarity.)`
215
+ - Soft warning at profile midpoint (e.g., round 3/6/10 depending on profile): surface remaining budget, e.g. `⚠️ Round {n}/{max_rounds} — {remaining} rounds left before the cap.`
216
+ - Hard cap at profile `max_rounds`
217
+
218
+ ## Phase 3: Challenge Modes (assumption stress tests)
219
+
220
+ Use each mode once when applicable. These are normal escalation tools, not rare rescue moves:
221
+
222
+ - **Contrarian** (round 2+ or immediately when an answer rests on an untested assumption): challenge core assumptions
223
+ - **Simplifier** (round 4+ or when scope expands faster than outcome clarity): probe minimal viable scope
224
+ - **Ontologist** (round 5+ and ambiguity > 0.25, or when the user keeps describing symptoms): ask for essence-level reframing
225
+
226
+ Track used modes in the state file to prevent repetition.
227
+
228
+ ## Phase 4: Crystallize Artifacts
229
+
230
+ When threshold is met (or user exits with warning / hard cap):
231
+
232
+ 1. Write the interview transcript summary to `deep-interview/{slug}-transcript.md`.
233
+ 2. Write the execution-ready spec to `deep-interview/{slug}-spec.md`.
234
+
235
+ Spec should include:
236
+ - Metadata (profile, rounds, final ambiguity, threshold, context type)
237
+ - Context snapshot reference/path (for downstream reuse)
238
+ - Clarity breakdown table
239
+ - Intent (why the user wants this)
240
+ - Desired Outcome
241
+ - In-Scope
242
+ - Out-of-Scope / Non-goals
243
+ - Decision Boundaries (what the implementer may decide without confirmation)
244
+ - Constraints
245
+ - Testable acceptance criteria
246
+ - Assumptions exposed + resolutions
247
+ - Pressure-pass findings (which answer was revisited, and what changed)
248
+ - Brownfield evidence vs inference notes for any repository-grounded confirmation questions
249
+ - Technical context findings
250
+ - Full or condensed transcript
251
+
252
+ ## Phase 5: Handoff
253
+
254
+ Deep-interview is a requirements mode. When the spec is ready, hand off to planning or implementation — do **not** implement directly here. The spec is the requirements source of truth: preserve intent, non-goals, decision boundaries, acceptance criteria, and any residual-risk warning across the handoff.
255
+
256
+ Present a short menu of next steps and let the user choose:
257
+
258
+ ```
259
+ Spec ready → deep-interview/{slug}-spec.md · final ambiguity {score}%{ · residual risk: <reason>}
260
+
261
+ 1. Plan turn the spec into a detailed implementation/architecture plan first
262
+ 2. Build implement directly — the spec is strong enough to start
263
+ 3. Refine keep interviewing — ambiguity or boundaries are still too loose
264
+ ```
265
+
266
+ When handing the spec to a downstream planner or implementer:
267
+ - Pass the spec file as the requirements source of truth; don't re-run the interview unless the user asks to refine.
268
+ - Carry the non-goals, decision boundaries, and acceptance criteria forward as binding constraints.
269
+
270
+ **Residual-Risk Rule:** if the interview ended via early exit, hard-cap completion, or proceed-with-warning, state that residual-risk explicitly in the handoff so the downstream step knows it inherited a partially clarified brief.
271
+
272
+ </Steps>
273
+
274
+ <Tool_Usage>
275
+ - Use read-only search tools (or an exploration subagent) for codebase fact gathering
276
+ - Use a structured user-input tool (`AskUserQuestion` / equivalent) for each interview round when available
277
+ - If structured question tools are unavailable, use plain-text single-question rounds and keep the same stage order
278
+ - Persist round state to `deep-interview/{slug}-state.json` for resumability; read it back to resume
279
+ - Read/write the context snapshot at `deep-interview/{slug}-context.md`
280
+ - Save transcript and spec artifacts to `deep-interview/{slug}-transcript.md` and `deep-interview/{slug}-spec.md`
281
+ - For a colorized TUI, render the banner / meter / breakdown with `scripts/render_progress.py` via Bash (ANSI shows in the terminal, not in markdown replies); it degrades to plain text under `--color never` / `NO_COLOR`
282
+ </Tool_Usage>
283
+
284
+ <Escalation_And_Stop_Conditions>
285
+ - User says stop/cancel/abort -> persist state and stop
286
+ - Ambiguity stalls for 3 rounds (+/- 0.05) -> force Ontologist mode once
287
+ - Max rounds reached -> proceed with explicit residual-risk warning
288
+ - All dimensions >= 0.9 -> allow early crystallization even before max rounds
289
+ </Escalation_And_Stop_Conditions>
290
+
291
+ <Final_Checklist>
292
+ - [ ] Preflight context snapshot exists at `deep-interview/{slug}-context.md`
293
+ - [ ] Progress strip (round budget + ambiguity bar) shown each round
294
+ - [ ] Readiness-gate status (`Non-goals`, `Decision Boundaries`, pressure pass) shown each round with what's blocking
295
+ - [ ] Intent-first stage priority used before implementation detail
296
+ - [ ] Weakest-dimension targeting used within the active stage
297
+ - [ ] At least one explicit assumption probe happened before crystallization
298
+ - [ ] At least one persistent follow-up / pressure pass deepened a prior answer
299
+ - [ ] Challenge modes triggered at thresholds (when applicable)
300
+ - [ ] Transcript written to `deep-interview/{slug}-transcript.md`
301
+ - [ ] Spec written to `deep-interview/{slug}-spec.md`
302
+ - [ ] Brownfield questions use evidence-backed confirmation when applicable
303
+ - [ ] Next-step handoff menu presented (Plan / Build / Refine)
304
+ - [ ] No direct implementation performed in this mode
305
+ </Final_Checklist>
306
+
307
+ <Advanced>
308
+ ## Resume
309
+
310
+ If interrupted, rerun the skill. Resume by reading the persisted state file (`deep-interview/{slug}-state.json`) and continuing from the last completed round.
311
+
312
+ ## Recommended pipeline
313
+
314
+ ```
315
+ deep-interview → planning → execution
316
+ ```
317
+
318
+ - Stage 1 (deep-interview): clarity gate — this skill
319
+ - Stage 2 (planning): feasibility + architecture gate
320
+ - Stage 3 (execution): build + QA + validation gate
321
+ </Advanced>
322
+
323
+ Task: {{ARGUMENTS}}
@@ -0,0 +1,193 @@
1
+ #!/usr/bin/env python3
2
+ """Colorized TUI renderer for the deep-interview skill.
3
+
4
+ Prints ANSI-colored progress surfaces — the kickoff banner, the per-round
5
+ ambiguity meter, and the clarity breakdown + readiness gates — to stdout.
6
+
7
+ Why a script instead of inline text: the assistant's markdown reply channel
8
+ does not render ANSI escape codes (they show up as literal garbage), but the
9
+ terminal output of a Bash command does. So run this via Bash whenever you want
10
+ the pretty colorized TUI; the plain markdown blocks in SKILL.md remain the
11
+ always-works fallback.
12
+
13
+ Degrades gracefully: pass --color never, or set NO_COLOR=1, to emit plain text
14
+ (safe for logs and pipes). Uses 256-color codes for broad terminal support.
15
+
16
+ Examples
17
+ --------
18
+ render_progress.py banner --profile Standard --context greenfield \
19
+ --idea "add dark mode to settings" --threshold 20 --max-rounds 12 --ambiguity 100
20
+
21
+ render_progress.py meter --round 3 --max-rounds 12 \
22
+ --stage "1: Intent-first" --focus Scope --ambiguity 52 --threshold 20
23
+
24
+ render_progress.py breakdown --threshold 20 --prev 60 --ambiguity 52 --next Scope \
25
+ --scores "Intent=0.80,Outcome=0.60,Scope=0.40,Constraints=0.70,Success=0.30" \
26
+ --gates "nongoals=1,boundaries=0,pressure=1"
27
+ """
28
+ import argparse
29
+ import os
30
+ import sys
31
+
32
+ # 256-color palette
33
+ RED, AMBER, GREEN, GRAY, CYAN, WHITE = 203, 214, 78, 244, 80, 252
34
+ _use_color = True
35
+
36
+
37
+ def c(code, s, bold=False):
38
+ if not _use_color:
39
+ return s
40
+ pre = "\033[1m" if bold else ""
41
+ return f"{pre}\033[38;5;{code}m{s}\033[0m"
42
+
43
+
44
+ def amb_color(amb, threshold):
45
+ """Red far from target, amber approaching, green at/under target."""
46
+ if amb <= threshold:
47
+ return GREEN
48
+ if amb <= 2 * threshold:
49
+ return AMBER
50
+ return RED
51
+
52
+
53
+ def meter_bar(amb, threshold, width=22):
54
+ """Draining ambiguity meter: filled cells = remaining ambiguity, a tick
55
+ marks the target. Goal is to drain the filled edge at/under the tick."""
56
+ filled = round(width * amb / 100)
57
+ tick = round(width * threshold / 100)
58
+ col = amb_color(amb, threshold)
59
+ cells = []
60
+ for i in range(width):
61
+ if i < filled:
62
+ cells.append(c(col, "█"))
63
+ elif i == tick:
64
+ cells.append(c(GREEN if amb <= threshold else CYAN, "┊"))
65
+ else:
66
+ cells.append(c(GRAY, "░"))
67
+ return "".join(cells)
68
+
69
+
70
+ def dim_bar(score, width=10):
71
+ filled = round(width * score)
72
+ col = GREEN if score >= 0.7 else AMBER if score >= 0.4 else RED
73
+ return c(col, "█" * filled) + c(GRAY, "░" * (width - filled))
74
+
75
+
76
+ def banner(a):
77
+ bar = c(CYAN, "│")
78
+ edge_t = c(CYAN, "╭─")
79
+ edge_b = c(CYAN, "╰" + "─" * 50)
80
+ idea = a.idea if len(a.idea) <= 52 else a.idea[:49] + "..."
81
+ lines = [
82
+ f" {edge_t} {c(WHITE, '🎯 Deep Interview', bold=True)} {c(CYAN, '─' * 30)}",
83
+ f" {bar} {c(GRAY, 'Profile ')} {c(WHITE, a.profile)} · {a.context}",
84
+ f" {bar} {c(GRAY, 'Goal ')} turn \"{idea}\" into an execution-ready spec",
85
+ f" {bar} {c(GRAY, 'Target ')} ambiguity {c(GREEN, f'≤ {a.threshold}%')} · Budget up to {a.max_rounds} rounds",
86
+ f" {bar} {c(GRAY, 'Start ')} ambiguity {c(amb_color(a.ambiguity, a.threshold), f'{a.ambiguity}%')} · one question / round, intent before detail",
87
+ f" {edge_b}",
88
+ ]
89
+ print("\n".join(lines))
90
+
91
+
92
+ def meter(a):
93
+ head = (
94
+ f"{c(GRAY, 'Round')} {c(WHITE, f'{a.round}/{a.max_rounds}', bold=True)}"
95
+ f" {c(GRAY, '·')} {c(GRAY, 'Stage')} {a.stage}"
96
+ f" {c(GRAY, '·')} {c(GRAY, 'Focus:')} {c(CYAN, a.focus)}"
97
+ )
98
+ bar = meter_bar(a.ambiguity, a.threshold)
99
+ line = (
100
+ f"{c(GRAY, 'Ambiguity')} {c(amb_color(a.ambiguity, a.threshold), f'{a.ambiguity:>3}%', bold=True)} "
101
+ f"[{bar}] {c(GRAY, f'target ≤ {a.threshold}%')}"
102
+ )
103
+ print(head)
104
+ print(line)
105
+
106
+
107
+ def breakdown(a):
108
+ print(c(WHITE, "Clarity", bold=True))
109
+ scores = {}
110
+ for pair in a.scores.split(","):
111
+ if not pair.strip():
112
+ continue
113
+ k, v = pair.split("=")
114
+ scores[k.strip()] = float(v)
115
+ weakest = min(scores, key=scores.get) if scores else None
116
+ for name, score in scores.items():
117
+ mark = c(CYAN, " ← weakest") if name == weakest else ""
118
+ print(f" {name:<12}{dim_bar(score)} {c(WHITE, f'{score:.2f}')}{mark}")
119
+
120
+ print()
121
+ print(c(WHITE, "Readiness gates", bold=True))
122
+ gate_labels = {
123
+ "nongoals": "Non-goals explicit",
124
+ "boundaries": "Decision Boundaries",
125
+ "pressure": "Pressure pass done",
126
+ }
127
+ gates, open_gates = {}, []
128
+ for pair in a.gates.split(","):
129
+ if not pair.strip():
130
+ continue
131
+ k, v = pair.split("=")
132
+ gates[k.strip()] = v.strip() in ("1", "true", "yes")
133
+ cells = []
134
+ for key, label in gate_labels.items():
135
+ met = gates.get(key, False)
136
+ cells.append(c(GREEN, f"✅ {label}") if met else c(GRAY, f"⬜ {label}"))
137
+ if not met:
138
+ open_gates.append(label)
139
+ print(" " + " ".join(cells))
140
+ if open_gates:
141
+ print(c(AMBER, f" → blocked by: {', '.join(open_gates)}"))
142
+ elif a.ambiguity <= a.threshold:
143
+ print(c(GREEN, " → all gates met — ready to crystallize"))
144
+
145
+ print()
146
+ delta = c(GREEN, "↓") if a.ambiguity < a.prev else c(GRAY, "·")
147
+ print(
148
+ f"{c(GRAY, 'Ambiguity')} {a.prev}% {delta} {c(amb_color(a.ambiguity, a.threshold), f'{a.ambiguity}%', bold=True)}"
149
+ f" {c(GRAY, '·')} {c(GRAY, 'Next:')} {c(CYAN, a.next)}"
150
+ )
151
+
152
+
153
+ def main():
154
+ global _use_color
155
+ p = argparse.ArgumentParser(description="deep-interview TUI renderer")
156
+ p.add_argument("--color", choices=["auto", "always", "never"], default="auto")
157
+ sub = p.add_subparsers(dest="cmd", required=True)
158
+
159
+ b = sub.add_parser("banner")
160
+ b.add_argument("--profile", required=True)
161
+ b.add_argument("--context", default="greenfield")
162
+ b.add_argument("--idea", default="")
163
+ b.add_argument("--threshold", type=int, required=True)
164
+ b.add_argument("--max-rounds", type=int, required=True)
165
+ b.add_argument("--ambiguity", type=int, default=100)
166
+ b.set_defaults(fn=banner)
167
+
168
+ m = sub.add_parser("meter")
169
+ m.add_argument("--round", type=int, required=True)
170
+ m.add_argument("--max-rounds", type=int, required=True)
171
+ m.add_argument("--stage", default="")
172
+ m.add_argument("--focus", default="")
173
+ m.add_argument("--ambiguity", type=int, required=True)
174
+ m.add_argument("--threshold", type=int, required=True)
175
+ m.set_defaults(fn=meter)
176
+
177
+ d = sub.add_parser("breakdown")
178
+ d.add_argument("--scores", required=True, help="Name=0.80,Name=0.60,...")
179
+ d.add_argument("--gates", default="nongoals=0,boundaries=0,pressure=0")
180
+ d.add_argument("--threshold", type=int, required=True)
181
+ d.add_argument("--prev", type=int, default=100)
182
+ d.add_argument("--ambiguity", type=int, required=True)
183
+ d.add_argument("--next", default="")
184
+ d.set_defaults(fn=breakdown)
185
+
186
+ a = p.parse_args()
187
+ if a.color == "never" or (a.color == "auto" and os.environ.get("NO_COLOR")):
188
+ _use_color = False
189
+ a.fn(a)
190
+
191
+
192
+ if __name__ == "__main__":
193
+ main()
@@ -0,0 +1,62 @@
1
+ ---
2
+ name: frontend-ui-ux
3
+ description: Frontend and user-facing UX review discipline adapted for LitClaude for Claude Code apps, docs, CLI surfaces, and plugin install flows.
4
+ ---
5
+
6
+ # Frontend UI UX
7
+
8
+ Use this skill for browser UI, CLI UX, documentation UX, screenshots, and any
9
+ user-facing workflow. For LitClaude, the main UX surface is install, command
10
+ activation, docs, and clear terminal output.
11
+
12
+ ## Product Posture
13
+
14
+ LitClaude is a developer/operator tool. Prefer quiet, direct, scan-friendly
15
+ interfaces over marketing-heavy copy. A good UX lets the user install, launch,
16
+ verify, update, and uninstall without remembering long paths.
17
+
18
+ ## CLI UX Rules
19
+
20
+ - Show the command the user should run next.
21
+ - Prefer `Launch with: claude` after global plugin install.
22
+ - Keep errors actionable and short.
23
+ - Do not expose implementation paths unless they help diagnosis.
24
+ - Include `--dry-run` for safe inspection.
25
+ - Do not require repeated long `claude --plugin-dir ...` commands after install.
26
+
27
+ ## Documentation UX
28
+
29
+ - First screen should answer what it is, how to install, and how to run.
30
+ - English and Korean READMEs should agree on commands and version.
31
+ - Put caveats near the command they affect.
32
+ - Avoid claiming unsupported automation such as silent `/goal` injection.
33
+ - Keep private-use posture clear: public npm convenience, no advertisement.
34
+
35
+ ## Visual Assets
36
+
37
+ If changing `cover.png` or visual docs, verify dimensions and rendering. In this
38
+ repo, tests expect a PNG with social dimensions. Do not replace it with a broken
39
+ or purely decorative asset that hides the product signal.
40
+
41
+ ## Manual QA
42
+
43
+ For browser UI, drive the browser. For CLI UX, a tmux transcript or captured
44
+ shell output is the surface. The artifact must show the exact text a user sees.
45
+
46
+ Good LitClaude CLI QA:
47
+
48
+ ```sh
49
+ npm exec --yes --package ./ -- litclaude-ai --dry-run install
50
+ ```
51
+
52
+ PASS if the output shows the intended version, install paths, plugin key, and
53
+ `Launch with: claude`.
54
+
55
+ ## Accessibility and Clarity
56
+
57
+ - Avoid long wrapped commands when a shorter command exists.
58
+ - Avoid jargon in first-use docs.
59
+ - Make fallback behavior explicit only where it helps action.
60
+ - Keep warnings near risky operations such as publish, uninstall, or registry
61
+ mutation.
62
+