myte 0.0.24 → 0.0.26

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 (2) hide show
  1. package/README.md +88 -2
  2. package/package.json +2 -2
package/README.md CHANGED
@@ -28,6 +28,7 @@ No install:
28
28
  - `MYTE_API_KEY=<project_api_key>` in your shell or workspace `.env`
29
29
  - `MYTEAI_API_KEY=<inference_api_key>` only for `myte ai`
30
30
  - `git` in `PATH` only for `query --with-diff`
31
+ - No runtime npm dependencies beyond the Myte packages themselves.
31
32
 
32
33
  The CLI searches for `.env` in the current folder and then up parent directories.
33
34
 
@@ -54,6 +55,8 @@ The CLI searches for `.env` in the current folder and then up parent directories
54
55
  - `npx myte feedback prd-diff --feedback-id <id> --version-id <version_id> --compare-to <base_version_id>`
55
56
  - `npx myte feedback apply --file ./MyteCommandCenter/reviews/feedback/<id>-edit.yml`
56
57
  - `npx myte suggestions sync`
58
+ - `npx myte mission archive --mission-ids "M001" --reason "Duplicate disposable mission"`
59
+ - `npx myte mission restore --mission-ids "M001" --status todo --reason "Restore after review"`
57
60
  - `npx myte query "Summarize the current branch changes" --with-diff`
58
61
  - `npx myte create-prd ./drafts/auth-prd.md`
59
62
  - `npx myte update-team "Backend deploy completed."`
@@ -63,6 +66,8 @@ The CLI searches for `.env` in the current folder and then up parent directories
63
66
  ## Behavior
64
67
 
65
68
  - `bootstrap`, `sync-qaqc`, `feedback-sync`, and `suggestions sync` write project-scoped local context under `MyteCommandCenter` in the current workspace unless `--output-dir` is provided.
69
+ - `bootstrap` writes mission cards and mission suggestion thread state together; agents should run it before looking for mission or suggestion ids.
70
+ - `mission status` is active-state only (`todo`, `in_progress`, `done`). Use `mission archive` and `mission restore` for lifecycle archival.
66
71
  - `feedback status|edit|assign|archive` writes local review artifacts under `MyteCommandCenter/reviews/feedback`; `feedback submit|revise|reviews|review` routes proposed edits through the backend owner-review membrane.
67
72
  - `feedback move|undo|prd-versions|prd-diff|history` calls the project-key Feedback API while authorization, stale snapshot checks, allowed transitions, and history remain enforced by the backend.
68
73
  - `feedback validate|apply` remains available for validation and owner-direct apply paths.
@@ -70,19 +75,76 @@ The CLI searches for `.env` in the current folder and then up parent directories
70
75
  - If diff-scoped repo configuration is missing or no local project repo can be resolved, `query --with-diff` exits with an error instead of silently dropping diff context.
71
76
  - Most markdown files are excluded from diff context by default so code and runtime configuration changes dominate the payload. Key instruction files such as `README.md` and `AGENTS.md` remain eligible.
72
77
 
78
+ ## Agent Usage Contract
79
+
80
+ Codex, Claude, and other coding agents should use one project-scoped key per workspace:
81
+
82
+ ```bash
83
+ MYTE_API_KEY=<project_api_key>
84
+ ```
85
+
86
+ The key resolves the project server-side. Agents should not pass `project_id` manually for normal CLI commands, and they should not call account-scoped web/JWT endpoints with this key.
87
+
88
+ Recommended agent flow:
89
+
90
+ 1. Run `myte config --json` to confirm the project, API base, configured repos, and local workspace detection.
91
+ 2. Run `myte bootstrap --json`, `myte feedback-sync --json`, or `myte sync-qaqc --json` to hydrate local context under `MyteCommandCenter`. Use `myte suggestions sync --json` only for narrow mission-review refreshes after bootstrap.
92
+ 3. Use `myte query "<goal/evidence/ask>" --with-diff` when local code changes matter.
93
+ 4. Use `myte create-prd <file.md>` only after the PRD markdown has been reviewed by a human. The file body is the PRD document; `--description` is only the short board/card summary.
94
+ 5. Use `myte feedback status|edit|assign|archive` to create reviewable local artifacts, then `feedback submit` and `feedback review` for the owner-review membrane.
95
+ 6. Use `myte feedback move` only for direct board movement that is intentionally audited, with a clear `--reason`.
96
+ 7. Use `myte suggestions create|revise|review` for mission review threads. Valid create `change_type` values are exactly `update` and `create`; revisions keep the existing thread type and must not include `change_type`.
97
+ 8. Use `myte mission archive` and `myte mission restore` for mission lifecycle archive/restore. Archive/restore require Project Owner or elevated delegate capability.
98
+ 9. Use `myte update-team "<content>"` for project/team comments through `/api/project-assistant/project-comment`.
99
+
100
+ PRD document contract:
101
+
102
+ - Always put the complete PRD in the markdown file passed to `myte create-prd`.
103
+ - `title` maps to the feedback/board title.
104
+ - `description` maps to the short feedback/card summary and must not contain the full PRD.
105
+ - The markdown body is sent as `prd_markdown` or `ticket_markdown`, stored as the PRD document source, mirrored as PRD text for search/sync, and used by the backend to generate the PRD DOCX.
106
+ - The UI renders the PRD from the stored document text, not from the card description.
107
+
108
+ Preferred file shape:
109
+
110
+ ````markdown
111
+ ```myte-kanban
112
+ {
113
+ "title": "Feedback Search PRD",
114
+ "description": "Improve feedback search across titles, descriptions, and stored PRD text.",
115
+ "priority": "Medium",
116
+ "tags": ["feedback", "search"]
117
+ }
118
+ ```
119
+
120
+ # Feedback Search PRD
121
+
122
+ ## Goal
123
+
124
+ Full PRD content goes here.
125
+ ````
126
+
127
+ Feedback comments nuance:
128
+
129
+ - `myte feedback-sync` reads existing feedback comment turns and stores them in `MyteCommandCenter/data/feedback.yml`.
130
+ - The web product supports feedback-specific comment create/fetch through JWT-authenticated `/api/feedbacks/<feedback_id>/comments`.
131
+ - The project-key npm CLI does not currently expose `myte feedback comment <feedback_id> "<text>"`. Add a Project Assistant route and CLI command before documenting that as supported.
132
+
73
133
  ## Commands
74
134
 
75
135
  - `config`: verify the project key and inspect local repo resolution
76
136
  - `bootstrap`: write project board context locally
77
137
  - `run-qaqc`: queue QAQC for explicit mission ids
78
- - `mission status`: update mission state
138
+ - `mission status`: update active mission state
139
+ - `mission archive`: archive missions without hard delete
140
+ - `mission restore`: restore archived missions to an active state
79
141
  - `sync-qaqc`: refresh active mission QAQC context locally
80
142
  - `feedback-sync`: refresh feedback and PRD context locally
81
143
  - `feedback status|edit|assign|archive|submit|revise|reviews|review|move|undo|prd-versions|prd-diff|validate|apply|history|get`: create reviewable feedback artifacts and operate the governed Feedback API
82
144
  - `suggestions sync|create|revise|review`: work with mission suggestion workflow state
83
145
  - `query`: ask the project assistant, optionally with local diff context
84
146
  - `ai`: use the Myte AI gateway
85
- - `create-prd`: upload deterministic PRD markdown
147
+ - `create-prd`: upload deterministic PRD markdown as the stored renderable PRD document; use `description` only as the short card summary
86
148
  - `update-team`, `update-owner`, `update-client`: send project updates through the project-key surface
87
149
 
88
150
  ## Notes
@@ -90,6 +152,28 @@ The CLI searches for `.env` in the current folder and then up parent directories
90
152
  - The package ships the CLI only. Internal rollout notes, validation logs, and project-specific operating docs are not part of the public npm contract.
91
153
  - The public `myte` package is the supported entrypoint. The scoped `@mytegroupinc/myte-core` package is the implementation dependency used by the wrapper.
92
154
 
155
+ ## Mission Action Map
156
+
157
+ | Action | Command / Surface | Contract |
158
+ | --- | --- | --- |
159
+ | Sync mission cards and review threads | `myte bootstrap --json` | Refreshes `MyteCommandCenter/data/missions/*.yml`, project structure, and `MyteCommandCenter/data/mission-ops.yml`. |
160
+ | Sync only mission review threads | `myte suggestions sync --json` | Narrow refresh for `mission-ops.yml` after bootstrap or a mutation. |
161
+ | Suggest edit to existing mission | `myte suggestions create` with `change_type: update` and `mission_id` | Creates or appends to an active review thread; live mission is unchanged until approval. |
162
+ | Suggest new mission | `myte suggestions create` with `change_type: create` | Requires `change_set.title` and `change_set.description`; mission card is created only after approval. |
163
+ | Revise a suggestion | `myte suggestions revise` with `suggestion_id` | Adds another revision to the same thread. Do not include `change_type`. |
164
+ | Review a suggestion | `myte suggestions review` with `review_action: approve|request_changes|reject` | Project Owner or elevated mission-review delegate required. |
165
+ | Update mission status | `myte mission status --mission-ids "M001" --status todo|in_progress|done` | Active status update only. |
166
+ | Archive mission | `myte mission archive --mission-ids "M001" --reason "..."` | Project Owner or elevated delegate required. Keeps the mission record and hides it from normal board/bootstrap state. |
167
+ | Restore mission | `myte mission restore --mission-ids "M001" --status todo|in_progress|done --reason "..."` | Project Owner or elevated delegate required. Restores archived cards to an active state. |
168
+
169
+ After `bootstrap`, find ids locally:
170
+
171
+ - existing mission ids: `MyteCommandCenter/data/missions/*.yml` -> `mission_id`
172
+ - suggestion ids: `MyteCommandCenter/data/mission-ops.yml` -> `queue[].suggestion_id` or `threads[].suggestion_id`
173
+ - revise revision: `threads[].latest_revision` or `threads[].latest_server_revision.revision`
174
+ - review revision: `threads[].review_revision`
175
+ - thread type: `threads[].change_type`
176
+
93
177
  ## Feedback Action Map
94
178
 
95
179
  | Command | What It Does | Governance |
@@ -137,6 +221,8 @@ Mutation routes:
137
221
  - `POST /api/project-assistant/query`
138
222
  - `POST /api/project-assistant/run-qaqc`
139
223
  - `POST /api/project-assistant/mission-status-update`
224
+ - `POST /api/project-assistant/mission-archive`
225
+ - `POST /api/project-assistant/mission-restore`
140
226
  - `POST /api/project-assistant/project-comment`
141
227
  - `POST /api/project-assistant/update-owner`
142
228
  - `POST /api/project-assistant/client-update-drafts`
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "myte",
3
- "version": "0.0.24",
3
+ "version": "0.0.26",
4
4
  "description": "Myte developer CLI.",
5
5
  "type": "commonjs",
6
6
  "license": "MIT",
@@ -16,6 +16,6 @@
16
16
  "node": ">=18"
17
17
  },
18
18
  "dependencies": {
19
- "@mytegroupinc/myte-core": "0.0.24"
19
+ "@mytegroupinc/myte-core": "0.0.26"
20
20
  }
21
21
  }