trekoon 0.2.6 → 0.2.8

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 (40) hide show
  1. package/README.md +102 -708
  2. package/docs/ai-agents.md +198 -0
  3. package/docs/commands.md +226 -0
  4. package/docs/machine-contracts.md +253 -0
  5. package/docs/plans/2026-03-15-trekoon-board-design.md +13 -0
  6. package/docs/quickstart.md +207 -0
  7. package/package.json +3 -1
  8. package/src/board/assets/app.js +1498 -0
  9. package/src/board/assets/components/AppShell.js +17 -0
  10. package/src/board/assets/components/BoardTopbar.js +78 -0
  11. package/src/board/assets/components/ClampedText.js +31 -0
  12. package/src/board/assets/components/EpicRow.js +62 -0
  13. package/src/board/assets/components/EpicsOverview.js +43 -0
  14. package/src/board/assets/components/WorkspaceHeader.js +70 -0
  15. package/src/board/assets/components/assetMap.js +65 -0
  16. package/src/board/assets/index.html +76 -0
  17. package/src/board/assets/main.js +27 -0
  18. package/src/board/assets/manifest.json +12 -0
  19. package/src/board/assets/state/actions.js +334 -0
  20. package/src/board/assets/state/api.js +126 -0
  21. package/src/board/assets/state/store.js +172 -0
  22. package/src/board/assets/styles/board.css +1127 -0
  23. package/src/board/assets/utils/dom.js +308 -0
  24. package/src/board/install.ts +196 -0
  25. package/src/board/open-browser.ts +131 -0
  26. package/src/board/routes.ts +299 -0
  27. package/src/board/server.ts +184 -0
  28. package/src/board/snapshot.ts +277 -0
  29. package/src/board/types.ts +43 -0
  30. package/src/commands/board.ts +158 -0
  31. package/src/commands/epic.ts +104 -3
  32. package/src/commands/help.ts +52 -13
  33. package/src/commands/init.ts +29 -0
  34. package/src/commands/subtask.ts +78 -1
  35. package/src/commands/task.ts +113 -7
  36. package/src/domain/mutation-service.ts +116 -0
  37. package/src/domain/tracker-domain.ts +261 -5
  38. package/src/domain/types.ts +51 -0
  39. package/src/runtime/cli-shell.ts +5 -0
  40. package/src/storage/path.ts +36 -0
@@ -0,0 +1,198 @@
1
+ # AI agents and the Trekoon skill
2
+
3
+ Use this guide when an AI agent needs to plan work in Trekoon, execute it, and
4
+ keep task state current while it works.
5
+
6
+ ## What the `trekoon` skill does
7
+
8
+ The bundled `trekoon` skill is the operating guide for agents. It tells the
9
+ agent to:
10
+
11
+ - use `--toon` on Trekoon commands
12
+ - prefer the smallest sufficient read
13
+ - use transactional bulk planning commands when possible
14
+ - append progress and blocker notes instead of rewriting full descriptions
15
+ - preview scoped replace before `--apply`
16
+ - treat `.trekoon` as shared repo-scoped operational state
17
+
18
+ The canonical installed file lives at:
19
+
20
+ - `.agents/skills/trekoon/SKILL.md`
21
+
22
+ ## Install the skill
23
+
24
+ Install the bundled skill into the repository:
25
+
26
+ ```bash
27
+ trekoon skills install
28
+ ```
29
+
30
+ Create a project-local editor link when your agent environment supports it:
31
+
32
+ ```bash
33
+ trekoon skills install --link --editor opencode
34
+ trekoon skills install --link --editor claude
35
+ trekoon skills install --link --editor pi
36
+ trekoon skills install --link --editor opencode --to ./.custom-editor/skills
37
+ trekoon skills update
38
+ ```
39
+
40
+ Path behavior:
41
+
42
+ - canonical install path: `.agents/skills/trekoon/SKILL.md`
43
+ - default OpenCode link path: `.opencode/skills/trekoon`
44
+ - default Claude link path: `.claude/skills/trekoon`
45
+ - default Pi link path: `.pi/skills/trekoon`
46
+ - `--to <path>` changes only the editor link root
47
+ - `--allow-outside-repo` is for intentional external links
48
+
49
+ ## Recommended skill stack
50
+
51
+ If your agent environment supports skills, this is the cleanest split of
52
+ responsibilities:
53
+
54
+ | Job | Skill | Why |
55
+ | --- | --- | --- |
56
+ | Turn a request into a concrete backlog | `writing-plans` | Breaks work into epics, tasks, subtasks, and dependencies |
57
+ | Create and update tracker state | `trekoon` | Uses Trekoon safely and efficiently |
58
+ | Execute the plan in dependency order | `executing-plans` | Helps the agent work through the backlog without losing the sequence |
59
+ | Clarify architecture before planning | `architecting-systems` | Useful when boundaries or ownership are still fuzzy |
60
+
61
+ In practice, the flow is usually:
62
+
63
+ 1. plan the work
64
+ 2. load `trekoon`
65
+ 3. create or update the Trekoon graph
66
+ 4. execute the next ready task
67
+ 5. update progress, blockers, and completion state as work moves forward
68
+
69
+ ## Default execution loop for agents
70
+
71
+ The main loop is: **session → work → task done → repeat**.
72
+
73
+ Start with a single orientation call:
74
+
75
+ ```bash
76
+ trekoon --toon session
77
+ ```
78
+
79
+ If the session output shows you are behind, pull tracker events before claiming
80
+ work:
81
+
82
+ ```bash
83
+ trekoon --toon sync pull --from main
84
+ ```
85
+
86
+ Claim work, then finish or report a block:
87
+
88
+ ```bash
89
+ trekoon --toon task update <task-id> --status in_progress
90
+ trekoon --toon task done <task-id>
91
+ trekoon --toon task update <task-id> --append "Blocked by <reason>" --status blocked
92
+ ```
93
+
94
+ Use `task done` when the task is actually finished. It marks the task complete
95
+ and returns the next ready candidate with blockers inline.
96
+
97
+ ## Use descendant cascade mode when closing a whole tree
98
+
99
+ When an agent needs to close or reopen an entire epic or task tree from the
100
+ command layer, use positional-ID `update --all` instead of looping one row at a
101
+ time:
102
+
103
+ ```bash
104
+ trekoon --toon epic update <epic-id> --all --status done
105
+ trekoon --toon epic update <epic-id> --all --status todo
106
+ trekoon --toon task update <task-id> --all --status done
107
+ trekoon --toon task update <task-id> --all --status todo
108
+ trekoon --toon subtask update <subtask-id> --all --status done
109
+ ```
110
+
111
+ Notes:
112
+
113
+ - Epic/task cascade mode is atomic: blocked descendants abort the whole update
114
+ - Use it only with `--status done|todo`
115
+ - Do not combine positional ID + `--all` with `--append`, `--description`,
116
+ `--title`, or `--ids`
117
+ - Subtask positional-ID `--all` is accepted for contract consistency, but it is
118
+ equivalent to a normal single-subtask status update
119
+
120
+ ## Tell the agent exactly what to do
121
+
122
+ These prompts work well because they are explicit about the skill order and the
123
+ expected loop.
124
+
125
+ ### Plan first, then create the backlog
126
+
127
+ ```text
128
+ Load writing-plans, break this feature into one epic with tasks and subtasks,
129
+ then load trekoon and create that graph in Trekoon.
130
+ ```
131
+
132
+ ### Execute an existing backlog
133
+
134
+ ```text
135
+ Load trekoon, run `trekoon --toon session`, take the next ready task, do the
136
+ work, append progress notes, mark it done, and repeat until there are no ready
137
+ tasks or you hit a blocker.
138
+ ```
139
+
140
+ ### Use planning, tracking, and execution together
141
+
142
+ ```text
143
+ Load writing-plans to shape the backlog, load trekoon to create and update the
144
+ tasks, then load executing-plans and complete the work in dependency order.
145
+ ```
146
+
147
+ ## Keep reads small and mutations safe
148
+
149
+ Use the narrowest command that answers the question:
150
+
151
+ | Need | Preferred command |
152
+ | --- | --- |
153
+ | Session startup | `trekoon --toon session` |
154
+ | Next task only | `trekoon --toon task next` |
155
+ | A few ready options | `trekoon --toon task ready --limit 5` |
156
+ | One task with subtasks | `trekoon --toon task show <task-id> --all` |
157
+ | One epic tree | `trekoon --toon epic show <epic-id> --all` |
158
+ | Repeated text in one scope | `trekoon --toon epic|task|subtask search ...` |
159
+
160
+ For repeated text changes, use the safe replace loop:
161
+
162
+ 1. search the narrowest valid scope
163
+ 2. preview replace
164
+ 3. run `--apply` only after the preview matches the intended scope
165
+
166
+ Example:
167
+
168
+ ```bash
169
+ trekoon --toon epic search <epic-id> "path/to/somewhere"
170
+ trekoon --toon epic replace <epic-id> --search "path/to/somewhere" --replace "path/to/new-path"
171
+ trekoon --toon epic replace <epic-id> --search "path/to/somewhere" --replace "path/to/new-path" --apply
172
+ ```
173
+
174
+ ## Worktree and sync rules
175
+
176
+ - Treat `meta.storageRootDiagnostics` as the source of truth for storage.
177
+ - In linked worktrees, `sharedStorageRoot` may differ from `worktreeRoot`. That
178
+ is expected.
179
+ - Do not commit `.trekoon/trekoon.db` as a recovery fix.
180
+ - Run `trekoon sync status` at session start and before merge.
181
+ - Resolve sync conflicts explicitly when they appear.
182
+
183
+ Useful commands:
184
+
185
+ ```bash
186
+ trekoon --toon sync status
187
+ trekoon --toon sync pull --from main
188
+ trekoon --toon sync conflicts list
189
+ trekoon --toon sync conflicts show <conflict-id>
190
+ trekoon --toon sync resolve <conflict-id> --use ours
191
+ ```
192
+
193
+ ## Related docs
194
+
195
+ - [Quickstart](quickstart.md)
196
+ - [Command reference](commands.md)
197
+ - [Machine contracts](machine-contracts.md)
198
+ - [Installed skill source](../.agents/skills/trekoon/SKILL.md)
@@ -0,0 +1,226 @@
1
+ # Command reference
2
+
3
+ Use this page when you already know what Trekoon does and just need the command
4
+ surface, defaults, and flag rules.
5
+
6
+ ## Command surface
7
+
8
+ - `trekoon init`
9
+ - `trekoon board <open|update>`
10
+ - `trekoon help [command]`
11
+ - `trekoon quickstart`
12
+ - `trekoon epic <create|expand|list|show|search|replace|update|delete>`
13
+ - `trekoon session`
14
+ - `trekoon task <create|create-many|list|show|ready|next|done|search|replace|update|delete>`
15
+ - `trekoon subtask <create|create-many|list|search|replace|update|delete>`
16
+ - `trekoon dep <add|add-many|remove|list|reverse>`
17
+ - `trekoon events prune [--dry-run] [--archive] [--retention-days <n>]`
18
+ - `trekoon migrate <status|rollback> [--to-version <n>]`
19
+ - `trekoon sync <status|pull|resolve|conflicts>`
20
+ - `trekoon skills install [--link --editor opencode|claude|pi] [--to <path>] [--allow-outside-repo]`
21
+ - `trekoon skills update`
22
+ - `trekoon wipe --yes`
23
+
24
+ ## Global output modes
25
+
26
+ - `--json` for structured JSON output
27
+ - `--toon` for true TOON-encoded output
28
+ - `--compat <mode>` for explicit machine compatibility behavior
29
+ - `--help` for root and command help
30
+ - `--version` for CLI version
31
+
32
+ Global options can be used before or after the command:
33
+
34
+ ```bash
35
+ trekoon --toon quickstart
36
+ trekoon quickstart --toon
37
+ trekoon --json quickstart
38
+ trekoon quickstart --json
39
+ ```
40
+
41
+ Trekoon uses long-form options for command and subcommand flags. Root help and
42
+ version aliases `-h` and `-v` are also supported.
43
+
44
+ ## Board lifecycle commands
45
+
46
+ Board terminology in docs matches `trekoon help board`:
47
+
48
+ - `trekoon board open`
49
+ - ensures board assets are installed in the repo-shared runtime directory
50
+ - starts a local board server on `127.0.0.1`
51
+ - launches the browser and returns the board URL, fallback URL, and launch
52
+ metadata in machine output
53
+ - `trekoon board update`
54
+ - refreshes board runtime assets only
55
+ - does not start the server or open a browser
56
+
57
+ Operator guidance:
58
+
59
+ - use `trekoon board open` as the normal one-command startup path
60
+ - use `trekoon board update` when you specifically need to refresh copied assets
61
+ before the next launch
62
+
63
+ Board commands do not accept command-specific options yet. For tests and local
64
+ development only, `TREKOON_BOARD_ASSET_ROOT` can override the bundled asset
65
+ source used by `init`, `board open`, and `board update`.
66
+
67
+ Runtime layout and security model:
68
+
69
+ - `trekoon init` installs or refreshes the board runtime under `.trekoon/board`
70
+ - `board open` serves those bundled files over a loopback-only server instead of
71
+ opening a raw file directly
72
+ - the server binds to `127.0.0.1` on a random port
73
+ - every session gets a per-session token; browser/API requests must present that
74
+ token
75
+ - static responses use `cache-control: no-store`, and CLI output always includes
76
+ a manual fallback URL
77
+
78
+ Current shell/runtime notes:
79
+
80
+ - the runtime copied into `.trekoon/board` includes the HTML shell, local app
81
+ modules, and shared styles
82
+ - the current shell also requests Vue from `unpkg.com`, Tailwind from
83
+ `cdn.tailwindcss.com`, and Google-hosted fonts/icons in the browser
84
+ - if those remote dependencies are blocked, the local server still starts and
85
+ the fallback URL remains valid, but the browser UI may not fully load until
86
+ network access is restored
87
+
88
+ Board UI architecture:
89
+
90
+ - the board is a single-page application served from `.trekoon/board` with Vue 3
91
+ (shell) and vanilla JS (board app) loaded from CDN dependencies
92
+ - the backend is a Bun HTTP server exposing a REST API at `/api/*` with
93
+ token-based authentication; every mutation response includes an updated
94
+ snapshot so the client always has fresh state
95
+ - the frontend uses optimistic updates: the UI changes immediately on user
96
+ action, then rolls back if the server rejects the mutation
97
+
98
+ Board layout behavior:
99
+
100
+ - the topbar is a compact flex-row navbar with workspace identity, Epics and
101
+ Board navigation pills, a debounced search input, theme toggle, and a
102
+ workspace info popover
103
+ - extra-wide layouts show the epic switcher sidebar, task workspace, and task
104
+ inspector or detail modal together
105
+ - narrower layouts progressively collapse support surfaces into stacked panels
106
+ or drawer-style views
107
+ - task cards show truncated descriptions; clicking anywhere on a card opens the
108
+ task detail modal
109
+
110
+ Scroll and overlay behavior:
111
+
112
+ - the page scrolls naturally as a single document; there are no internal scroll
113
+ containers trapping wheel events in the main content area
114
+ - when a modal overlay opens (task detail, subtask editor), body scroll is
115
+ locked and the modal surface becomes the scroll container
116
+ - close overlays from the top down: subtask modal → task detail → broader board
117
+ context; each close unlocks body scroll and returns to the previous context
118
+
119
+ Board API endpoints (all require token authentication):
120
+
121
+ - `GET /api/snapshot` — full board state (epics, tasks, subtasks, dependencies,
122
+ counts)
123
+ - `PATCH /api/epics/{id}` — update epic title, description, or status
124
+ - `PATCH /api/tasks/{id}` — update task title, description, or status
125
+ - `PATCH /api/subtasks/{id}` — update subtask title, description, or status
126
+ - `POST /api/subtasks` — create subtask (requires taskId, title)
127
+ - `DELETE /api/subtasks/{id}` — delete subtask
128
+ - `POST /api/dependencies` — add dependency edge (sourceId, dependsOnId)
129
+ - `DELETE /api/dependencies?sourceId=...&dependsOnId=...` — remove dependency
130
+
131
+ Token is sent as `Authorization: Bearer {token}` header or `x-trekoon-token`
132
+ header or `?token={token}` query parameter. Invalid tokens return `401`.
133
+
134
+ Examples:
135
+
136
+ ```bash
137
+ trekoon init
138
+ trekoon board open
139
+ trekoon --json board open
140
+ trekoon board update
141
+ ```
142
+
143
+ ## Human views
144
+
145
+ - List and show commands default to table output in human mode.
146
+ - Use `--view compact` to restore compact pipe output.
147
+ - `epic list`, `task list`, and `subtask list` support `--view table|compact`.
148
+ - `epic show` and `task show` support `--view table|compact|tree|detail`.
149
+
150
+ ## List defaults and filters
151
+
152
+ These defaults apply to `epic list`, `task list`, and `subtask list`:
153
+
154
+ - Default scope: open work only (`in_progress`, `in-progress`, `todo`)
155
+ - Default limit: `10`
156
+ - Status filter: `--status in_progress,todo`
157
+ - Custom limit: `--limit <n>`
158
+ - Cursor pagination: `--cursor <n>`
159
+ - All rows and statuses: `--all`
160
+ - `--all` is mutually exclusive with `--status`, `--limit`, and `--cursor`
161
+
162
+ ## Update modes
163
+
164
+ `epic update`, `task update`, and `subtask update` now have two meanings for
165
+ `--all`, depending on whether you also pass a positional ID.
166
+
167
+ ### Repo-wide bulk mode
168
+
169
+ Use `update --all` or `update --ids <csv>` when you want to target multiple
170
+ top-level rows directly.
171
+
172
+ This mode preserves the existing per-row update behavior. It is **not** the same
173
+ as descendant cascade mode and is not one atomic multi-row transaction.
174
+
175
+ - Target all rows: `--all`
176
+ - Target specific rows: `--ids <id1,id2,...>`
177
+ - Bulk mode supports only `--append <text>`, `--status <status>`, or both
178
+ - In bulk mode, do not pass a positional ID
179
+ - `--all` and `--ids` are mutually exclusive
180
+ - `--append` and `--description` are mutually exclusive
181
+
182
+ Examples:
183
+
184
+ ```bash
185
+ trekoon task update --all --status in_progress
186
+ trekoon task update --ids <task-1>,<task-2> --append "\nFollow-up note"
187
+ trekoon subtask update --all --status done
188
+ trekoon subtask update --ids <subtask-1>,<subtask-2> --append "\nFollow-up note"
189
+ trekoon epic update --ids <epic-1>,<epic-2> --status done
190
+ ```
191
+
192
+ ### Descendant cascade mode
193
+
194
+ Use positional-ID `update <id> --all --status done|todo` when you want to close
195
+ or reopen a whole tree from one root.
196
+
197
+ - `trekoon epic update <epic-id> --all --status done|todo`
198
+ - updates the epic and all descendant tasks/subtasks in one atomic operation
199
+ - `trekoon task update <task-id> --all --status done|todo`
200
+ - updates the task and all descendant subtasks in one atomic operation
201
+ - `trekoon subtask update <subtask-id> --all --status done|todo`
202
+ - accepts the same syntax for consistency, but behaves like a normal
203
+ single-subtask status update because there are no descendants
204
+ - Positional-ID cascade mode supports only `--status done|todo`
205
+ - Do not combine positional ID + `--all` with `--ids`, `--append`,
206
+ `--description`, or `--title`
207
+ - For epic/task cascades, unresolved external dependencies abort the whole
208
+ update with `dependency_blocked`; no partial writes are committed
209
+ - Successful machine output includes `data.cascade` with the root, target
210
+ status, atomic flag, changed IDs, unchanged IDs, and per-kind counts
211
+
212
+ Examples:
213
+
214
+ ```bash
215
+ trekoon epic update <epic-id> --all --status done
216
+ trekoon epic update <epic-id> --all --status todo
217
+ trekoon task update <task-id> --all --status done
218
+ trekoon task update <task-id> --all --status todo
219
+ trekoon subtask update <subtask-id> --all --status done
220
+ ```
221
+
222
+ ## Related docs
223
+
224
+ - [Quickstart](quickstart.md)
225
+ - [AI agents and the Trekoon skill](ai-agents.md)
226
+ - [Machine contracts](machine-contracts.md)
@@ -0,0 +1,253 @@
1
+ # Machine contracts
2
+
3
+ Use `--toon` for production agent loops. Use `--json` only when an integration
4
+ explicitly requires JSON.
5
+
6
+ ## Base envelope
7
+
8
+ All machine responses use the same top-level shape:
9
+
10
+ ```text
11
+ ok: true|false
12
+ command: <stable command id>
13
+ data: <payload>
14
+ metadata:
15
+ contractVersion: "1.0.0"
16
+ requestId: req-<stable-id>
17
+ ```
18
+
19
+ Most subcommand identifiers are dot-namespaced, such as `task.list` or
20
+ `sync.pull`. Root-level commands may use single-token IDs such as `help`,
21
+ `init`, `quickstart`, `wipe`, or `version`.
22
+
23
+ Additional metadata may appear when relevant:
24
+
25
+ - `metadata.compatibility` when `--compat` mode is active
26
+ - `meta.storageRootDiagnostics` when storage resolves from a non-canonical cwd
27
+
28
+ ## Ready queue contract
29
+
30
+ ```bash
31
+ trekoon --toon task ready --limit 3
32
+ ```
33
+
34
+ Payload fields:
35
+
36
+ ```text
37
+ ok: true
38
+ command: task.ready
39
+ data:
40
+ candidates[]:
41
+ task: { id, epicId, title, status, ... }
42
+ readiness: { isReady, reason }
43
+ blockerSummary: { blockedByCount, totalDependencies, blockedBy[] }
44
+ ranking: { rank, blockerCount, statusPriority }
45
+ blocked[]: (same shape, non-ready items)
46
+ summary:
47
+ totalOpenTasks
48
+ readyCount
49
+ returnedCount
50
+ appliedLimit
51
+ blockedCount
52
+ unresolvedDependencyCount
53
+ ```
54
+
55
+ ## Reverse dependency walk
56
+
57
+ ```bash
58
+ trekoon --toon dep reverse <task-or-subtask-id>
59
+ ```
60
+
61
+ Payload fields:
62
+
63
+ ```text
64
+ ok: true
65
+ command: dep.reverse
66
+ data:
67
+ targetId: <id>
68
+ targetKind: task|subtask
69
+ blockedNodes[]: { id, kind, distance, isDirect }
70
+ ```
71
+
72
+ ## Pagination contract for list calls
73
+
74
+ ```bash
75
+ trekoon --toon task list --status todo --limit 2
76
+ trekoon --toon task list --status todo --limit 2 --cursor 2
77
+ ```
78
+
79
+ Cursor rules:
80
+
81
+ - `--cursor <n>` is offset-like pagination for `epic list`, `task list`, and
82
+ `subtask list`
83
+ - do not combine `--all` with `--cursor`
84
+ - machine consumers should page using `meta.pagination.hasMore` and
85
+ `meta.pagination.nextCursor`
86
+
87
+ Payload fields:
88
+
89
+ ```text
90
+ ok: true
91
+ command: task.list
92
+ data:
93
+ tasks[]: ...
94
+ metadata:
95
+ contractVersion: "1.0.0"
96
+ requestId: req-<stable-id>
97
+ meta:
98
+ pagination: { hasMore, nextCursor }
99
+ ```
100
+
101
+ ## Descendant cascade update contract
102
+
103
+ ```bash
104
+ trekoon --toon epic update <epic-id> --all --status done
105
+ trekoon --toon task update <task-id> --all --status todo
106
+ ```
107
+
108
+ Success payload fields for epic/task cascade mode:
109
+
110
+ ```text
111
+ ok: true
112
+ command: epic.update | task.update
113
+ data:
114
+ epic | task: { ...updated root row... }
115
+ cascade:
116
+ mode: descendants
117
+ root: { kind: epic|task, id: <root-id> }
118
+ targetStatus: done|todo
119
+ atomic: true
120
+ changedIds[]
121
+ unchangedIds[]
122
+ counts:
123
+ scope
124
+ changed
125
+ unchanged
126
+ blockers
127
+ changedEpics
128
+ changedTasks
129
+ changedSubtasks
130
+ ```
131
+
132
+ Failure contract for blocked epic/task cascade mode:
133
+
134
+ ```text
135
+ ok: false
136
+ error:
137
+ code: dependency_blocked
138
+ data:
139
+ entity: epic|task
140
+ id: <root-id>
141
+ status: done|todo
142
+ atomic: true
143
+ changedIds[]
144
+ unchangedIds[]
145
+ blockerCount
146
+ blockedNodeIds[]
147
+ unresolvedDependencyIds[]
148
+ blockers[]:
149
+ sourceId
150
+ sourceKind
151
+ dependsOnId
152
+ dependsOnKind
153
+ dependsOnStatus
154
+ inScope
155
+ willCascade
156
+ ```
157
+
158
+ Notes:
159
+
160
+ - `subtask update <subtask-id> --all --status done|todo` is accepted, but it
161
+ returns the normal single-subtask `subtask.update` payload because there are
162
+ no descendants to traverse
163
+ - Cascade mode is reserved for status-only close/reopen operations; combine
164
+ append/title/description changes in separate commands
165
+
166
+ ## Batch create and expand payloads
167
+
168
+ Trekoon uses stable batch payloads for one-shot graph creation and sibling batch
169
+ creation commands.
170
+
171
+ ### `epic create` and `epic expand`
172
+
173
+ ```bash
174
+ trekoon --toon epic create --title "..." --description "..." --task "..."
175
+ trekoon --toon epic expand <epic-id> --task "..."
176
+ ```
177
+
178
+ Payload fields:
179
+
180
+ ```text
181
+ ok: true
182
+ command: epic.create | epic.expand
183
+ data:
184
+ epic: { ... } # epic.create only
185
+ epicId: <epic-id> # epic.expand only
186
+ tasks[]
187
+ subtasks[]
188
+ dependencies[]
189
+ result:
190
+ mappings[]: { kind, tempKey, id }
191
+ counts: { tasks, subtasks, dependencies }
192
+ ```
193
+
194
+ ### `task create-many`
195
+
196
+ ```bash
197
+ trekoon --toon task create-many --epic <epic-id> --task "..."
198
+ ```
199
+
200
+ Payload fields:
201
+
202
+ ```text
203
+ ok: true
204
+ command: task.create-many
205
+ data:
206
+ epicId: <epic-id>
207
+ tasks[]
208
+ result:
209
+ mappings[]: { kind: task, tempKey, id }
210
+ ```
211
+
212
+ ### `subtask create-many`
213
+
214
+ ```bash
215
+ trekoon --toon subtask create-many --task <task-id> --subtask "..."
216
+ ```
217
+
218
+ Payload fields:
219
+
220
+ ```text
221
+ ok: true
222
+ command: subtask.create-many
223
+ data:
224
+ taskId: <task-id>
225
+ subtasks[]
226
+ result:
227
+ mappings[]: { kind: subtask, tempKey, id }
228
+ ```
229
+
230
+ ## Sync compatibility mode
231
+
232
+ Compatibility mode exists for integrations that still consume legacy sync
233
+ command IDs:
234
+
235
+ ```bash
236
+ trekoon --json --compat legacy-sync-command-ids sync status
237
+ trekoon --toon --compat legacy-sync-command-ids sync pull --from main
238
+ ```
239
+
240
+ Behavior:
241
+
242
+ - default output uses canonical dotted IDs such as `sync.status`
243
+ - compatibility mode rewrites sync command IDs to legacy forms such as
244
+ `sync_status`
245
+ - compatibility mode is machine-only and valid only for `sync` commands
246
+ - machine output includes `metadata.compatibility` with migration guidance and
247
+ removal timing
248
+
249
+ ## Related docs
250
+
251
+ - [Quickstart](quickstart.md)
252
+ - [Command reference](commands.md)
253
+ - [AI agents and the Trekoon skill](ai-agents.md)
@@ -0,0 +1,13 @@
1
+ <section name="problem">
2
+ Add a no-install HTML board generated by Trekoon that opens fast and lets developers browse epics, filter/search, and manage tasks with kanban and list views. It should support inline editing, drag-and-drop status changes, and a GitLab-like task detail view with subtasks and dependencies. The board should be created on `trekoon init`, open via a CLI command, and be updatable with a future `trekoon board update` command. Include light/dark mode.
3
+ </section>
4
+
5
+ <section name="findings">
6
+ - Visual design: Soft studio aesthetic with warm neutrals, layered surfaces, subtle gradients, and refined typography to keep dense data readable and calm.
7
+ - Data flow: Pinia as the primary client-side state layer coordinating epics, filters/search, kanban status moves, and task edits across views.
8
+ - UX flow: Emphasize speed, keyboard-first actions, progressive disclosure, inline editing, and context preservation using a split-view layout.
9
+ </section>
10
+
11
+ <section name="recommendation">
12
+ Generate a static `board/index.html` on `trekoon init` with Vue + Tailwind via CDN, Pinia for shared state, and a small JSON payload from `trekoon epic list --all` embedded as initial data. Use a split-view layout: left column for epics and filters/search, right column for epic details with a tabbed kanban/list switch and a task detail drawer. Provide drag-and-drop in kanban to update status, inline edits in list rows, and a GitLab-style task detail view with subtasks and dependencies. Add a `trekoon board open` command to open the HTML file and a `trekoon board update` command to refresh the generated assets. Support light/dark mode via CSS variables and a theme toggle persisted in localStorage.
13
+ </section>