Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion docs/memory/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,4 @@

| Domain | Description | Memory Files |
|--------|-------------|------|
| wt-cli | Behavior contracts for the `wt` CLI binary (commands, exit codes, signal handling, test seams). | [wt-cli/init-failure-contract.md](wt-cli/init-failure-contract.md), [wt-cli/list-status-contract.md](wt-cli/list-status-contract.md), [wt-cli/menu-navigation-contract.md](wt-cli/menu-navigation-contract.md), [wt-cli/update-command-contract.md](wt-cli/update-command-contract.md), [wt-cli/recency-ordering-contract.md](wt-cli/recency-ordering-contract.md), [wt-cli/idle-staleness-contract.md](wt-cli/idle-staleness-contract.md), [wt-cli/create-output-phases.md](wt-cli/create-output-phases.md) |
| wt-cli | Behavior contracts for the `wt` CLI binary (commands, exit codes, signal handling, test seams). | [wt-cli/init-failure-contract.md](wt-cli/init-failure-contract.md), [wt-cli/list-status-contract.md](wt-cli/list-status-contract.md), [wt-cli/menu-navigation-contract.md](wt-cli/menu-navigation-contract.md), [wt-cli/update-command-contract.md](wt-cli/update-command-contract.md), [wt-cli/recency-ordering-contract.md](wt-cli/recency-ordering-contract.md), [wt-cli/idle-staleness-contract.md](wt-cli/idle-staleness-contract.md), [wt-cli/create-output-phases.md](wt-cli/create-output-phases.md), [wt-cli/help-dump-contract.md](wt-cli/help-dump-contract.md) |
153 changes: 153 additions & 0 deletions docs/memory/wt-cli/help-dump-contract.md

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion fab/backlog.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
## Backlog

- [ ] [pc47] 2026-06-02: Add a build-time 'help-dump' step that emits wt's CLI help tree as help/wt.json and PRs it into sahil87/shll.ai (the shll.ai landing site renders it as an expandable 'Command reference' on the wt tool page). CONTRACT (frozen — copy the reference sample committed at sahil87/shll.ai path help/wt.json, which was generated from THIS binary): JSON shape is {tool, version, captured_at (ISO-8601 UTC), schema_version: 1, root: Node} where Node = {name, path (full invocation e.g. 'wt create'), short (one-line desc), usage, text (the RAW -h output byte-for-byte, newlines preserved), commands: Node[] (recursive; empty array = leaf)}. PRODUCER (wt is Cobra/Go, binary 'wt', main at src/cmd/wt): walk the cobra command tree programmatically (rootCmd.Commands() recursively), NOT regex-parsing -h text; per node capture cmd.Name / cmd.CommandPath() / cmd.Short / cmd.UseLine() and cmd.UsageString() (or Long+UsageString) as 'text'. FILTER OUT cobra's auto-generated 'completion' and 'help' subcommands and any cmd.Hidden==true. VERSION: read from the built binary (rootCmd.Version / ldflags) — the committed sample uses a placeholder '1.4.2' because a plain 'go build' reports 'dev'; the CI producer MUST inject the real version. PUSH: in CI after build, run the dump, write help/wt.json, validate it parses, then open a PR into sahil87/shll.ai using the existing repo secret SHLLAI_TOKEN (contents + pull-request write) with auto-merge enabled (PR, not direct push to main, to avoid the multi-repo push race). wt is the reference tool for this 7-tool rollout (its sample help/wt.json is what the other six copy from); the shll.ai site-side consumer (Astro loader + reference UI) is tracked separately in the shll.ai repo.
- [x] [pc47] 2026-06-02: ~~Add a build-time 'help-dump' step that emits wt's CLI help tree as help/wt.json and PRs it into sahil87/shll.ai (the shll.ai landing site renders it as an expandable 'Command reference' on the wt tool page). CONTRACT (frozen — copy the reference sample committed at sahil87/shll.ai path help/wt.json, which was generated from THIS binary): JSON shape is {tool, version, captured_at (ISO-8601 UTC), schema_version: 1, root: Node} where Node = {name, path (full invocation e.g. 'wt create'), short (one-line desc), usage, text (the RAW -h output byte-for-byte, newlines preserved), commands: Node[] (recursive; empty array = leaf)}. PRODUCER (wt is Cobra/Go, binary 'wt', main at src/cmd/wt): walk the cobra command tree programmatically (rootCmd.Commands() recursively), NOT regex-parsing -h text; per node capture cmd.Name / cmd.CommandPath() / cmd.Short / cmd.UseLine() and cmd.UsageString() (or Long+UsageString) as 'text'. FILTER OUT cobra's auto-generated 'completion' and 'help' subcommands and any cmd.Hidden==true. VERSION: read from the built binary (rootCmd.Version / ldflags) — the committed sample uses a placeholder '1.4.2' because a plain 'go build' reports 'dev'; the CI producer MUST inject the real version. PUSH: in CI after build, run the dump, write help/wt.json, validate it parses, then open a PR into sahil87/shll.ai using the existing repo secret SHLLAI_TOKEN (contents + pull-request write) with auto-merge enabled (PR, not direct push to main, to avoid the multi-repo push race). wt is the reference tool for this 7-tool rollout (its sample help/wt.json is what the other six copy from); the shll.ai site-side consumer (Astro loader + reference UI) is tracked separately in the shll.ai repo.~~ — **SUPERSEDED by qqkj (2026-06-03)**: the `wt help-dump` producer command is implemented in change `260603-qqkj-help-dump-command`. The push half (build-time CI step, PR-opening into sahil87/shll.ai, auto-merge, `SHLLAI_TOKEN`) is intentionally **dropped** — shll.ai's help-dump contract inverted the integration to a scheduled *pull* model (shll.ai runs `wt help-dump` itself), retiring the push wiring.
21 changes: 21 additions & 0 deletions fab/changes/260603-qqkj-help-dump-command/.history.jsonl
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{"action":"enter","driver":"fab-new","event":"stage-transition","stage":"intake","ts":"2026-06-03T07:51:49Z"}
{"args":"There's an update in the way we integrate with shll.ai (help-dump-contract.md teardown directive). shll.ai now PULLS help via 'wt help-dump' instead of the retired push model. Implement the wt help-dump Cobra command per the contract (Hidden, walks tree recursively, emits {tool,version,schema_version:1,root} to stdout, no captured_at). Supersedes backlog pc47 (push producer).","cmd":"fab-new","event":"command","ts":"2026-06-03T07:51:49Z"}
{"delta":"+1.8","event":"confidence","score":1.8,"trigger":"calc-score","ts":"2026-06-03T07:52:54Z"}
{"delta":"+0.0","event":"confidence","score":1.8,"trigger":"calc-score","ts":"2026-06-03T07:53:00Z"}
{"cmd":"fab-clarify","event":"command","ts":"2026-06-03T07:54:44Z"}
{"delta":"+3.2","event":"confidence","score":5,"trigger":"calc-score","ts":"2026-06-03T14:22:14Z"}
{"delta":"+0.0","event":"confidence","score":5,"trigger":"calc-score","ts":"2026-06-03T14:22:21Z"}
{"delta":"+0.0","event":"confidence","score":5,"trigger":"calc-score","ts":"2026-06-03T14:22:28Z"}
{"delta":"+0.0","event":"confidence","score":5,"trigger":"calc-score","ts":"2026-06-03T14:22:39Z"}
{"delta":"+0.0","event":"confidence","score":5,"trigger":"calc-score","ts":"2026-06-03T14:22:42Z"}
{"cmd":"fab-fff","event":"command","ts":"2026-06-03T14:22:53Z"}
{"action":"enter","driver":"fab-fff","event":"stage-transition","stage":"apply","ts":"2026-06-03T14:23:17Z"}
{"cmd":"fab-continue","event":"command","ts":"2026-06-03T14:24:28Z"}
{"action":"enter","driver":"fab-fff","event":"stage-transition","stage":"review","ts":"2026-06-03T14:34:53Z"}
{"cmd":"fab-continue","event":"command","ts":"2026-06-03T14:35:34Z"}
{"action":"enter","driver":"fab-fff","event":"stage-transition","stage":"hydrate","ts":"2026-06-03T14:37:47Z"}
{"event":"review","result":"passed","ts":"2026-06-03T14:37:47Z"}
{"cmd":"fab-continue","event":"command","ts":"2026-06-03T14:38:39Z"}
{"action":"enter","driver":"fab-fff","event":"stage-transition","stage":"ship","ts":"2026-06-03T14:40:18Z"}
{"cmd":"git-pr","event":"command","ts":"2026-06-03T14:41:26Z"}
{"action":"enter","driver":"git-pr","event":"stage-transition","stage":"review-pr","ts":"2026-06-03T14:42:33Z"}
51 changes: 51 additions & 0 deletions fab/changes/260603-qqkj-help-dump-command/.status.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
id: qqkj
name: 260603-qqkj-help-dump-command
created: 2026-06-03T07:51:49Z
created_by: sahil87
change_type: feat
issues: []
progress:
intake: done
apply: done
review: done
hydrate: done
ship: done
review-pr: active
plan:
generated: true
task_count: 7
acceptance_count: 15
acceptance_completed: 0
confidence:
certain: 13
confident: 0
tentative: 0
unresolved: 0
score: 5.0
fuzzy: true
dimensions:
signal: 95.9
reversibility: 74.2
competence: 88.3
disambiguation: 86.1
stage_metrics:
intake: {started_at: "2026-06-03T07:51:49Z", driver: fab-new, iterations: 1, completed_at: "2026-06-03T14:23:17Z"}
apply: {started_at: "2026-06-03T14:23:17Z", driver: fab-fff, iterations: 1, completed_at: "2026-06-03T14:34:53Z"}
review: {started_at: "2026-06-03T14:34:53Z", driver: fab-fff, iterations: 1, completed_at: "2026-06-03T14:37:47Z"}
hydrate: {started_at: "2026-06-03T14:37:47Z", driver: fab-fff, iterations: 1, completed_at: "2026-06-03T14:40:18Z"}
ship: {started_at: "2026-06-03T14:40:18Z", driver: fab-fff, iterations: 1, completed_at: "2026-06-03T14:42:33Z"}
review-pr: {started_at: "2026-06-03T14:42:33Z", driver: git-pr, iterations: 1}
prs:
- https://github.com/sahil87/wt/pull/21
true_impact:
added: 0
deleted: 0
net: 0
excluding:
added: 0
deleted: 0
net: 0
computed_at: "2026-06-03T14:40:18Z"
computed_at_stage: hydrate
# true_impact: lazily created on first apply-finish (no placeholder here).
last_updated: 2026-06-03T14:42:33Z
Loading
Loading