@dedesfr/prompter 0.9.0 → 1.0.0

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 (216) hide show
  1. package/CHANGELOG.md +21 -0
  2. package/README.md +105 -77
  3. package/dist/cli/index.js +25 -1
  4. package/dist/cli/index.js.map +1 -1
  5. package/dist/commands/init.d.ts.map +1 -1
  6. package/dist/commands/init.js +32 -9
  7. package/dist/commands/init.js.map +1 -1
  8. package/dist/commands/login.d.ts +4 -0
  9. package/dist/commands/login.d.ts.map +1 -0
  10. package/dist/commands/login.js +56 -0
  11. package/dist/commands/login.js.map +1 -0
  12. package/dist/commands/logout.d.ts +4 -0
  13. package/dist/commands/logout.d.ts.map +1 -0
  14. package/dist/commands/logout.js +14 -0
  15. package/dist/commands/logout.js.map +1 -0
  16. package/dist/commands/update.d.ts.map +1 -1
  17. package/dist/commands/update.js +18 -5
  18. package/dist/commands/update.js.map +1 -1
  19. package/dist/commands/whoami.d.ts +4 -0
  20. package/dist/commands/whoami.d.ts.map +1 -0
  21. package/dist/commands/whoami.js +42 -0
  22. package/dist/commands/whoami.js.map +1 -0
  23. package/dist/core/auth-store.d.ts +10 -0
  24. package/dist/core/auth-store.d.ts.map +1 -0
  25. package/dist/core/auth-store.js +39 -0
  26. package/dist/core/auth-store.js.map +1 -0
  27. package/dist/core/registry.d.ts +18 -0
  28. package/dist/core/registry.d.ts.map +1 -0
  29. package/dist/core/registry.js +94 -0
  30. package/dist/core/registry.js.map +1 -0
  31. package/package.json +7 -1
  32. package/AGENTS.md +0 -123
  33. package/CLAUDE.md +0 -17
  34. package/build.js +0 -20
  35. package/convex-setup.md +0 -403
  36. package/prompt/ai-humanizer.md +0 -45
  37. package/prompt/api-contract-generator.md +0 -234
  38. package/prompt/apply.md +0 -17
  39. package/prompt/archive.md +0 -21
  40. package/prompt/design-system.md +0 -210
  41. package/prompt/document-explainer.md +0 -149
  42. package/prompt/epic-generator.md +0 -198
  43. package/prompt/epic-single.md +0 -47
  44. package/prompt/erd-generator.md +0 -130
  45. package/prompt/fsd-generator.md +0 -157
  46. package/prompt/prd-agent-generator.md +0 -147
  47. package/prompt/prd-generator.md +0 -195
  48. package/prompt/product-brief.md +0 -289
  49. package/prompt/proposal.md +0 -22
  50. package/prompt/qa-test-scenario.md +0 -133
  51. package/prompt/skill-creator.md +0 -350
  52. package/prompt/story-generator.md +0 -278
  53. package/prompt/story-single.md +0 -70
  54. package/prompt/tdd-generator.md +0 -294
  55. package/prompt/tdd-lite-generator.md +0 -224
  56. package/prompt/wireframe-generator.md +0 -219
  57. package/skills/ai-context-generator/SKILL.md +0 -54
  58. package/skills/ai-context-generator/references/AGENTS.template.md +0 -83
  59. package/skills/ai-context-generator/references/CLAUDE.template.md +0 -39
  60. package/skills/ai-context-generator/references/behavioral-guidelines.md +0 -71
  61. package/skills/ai-context-generator/references/discovery-checklist.md +0 -40
  62. package/skills/ai-context-generator/references/examples/AGENTS.good.md +0 -103
  63. package/skills/ai-context-generator/references/extraction-checklist.md +0 -23
  64. package/skills/ai-context-generator/references/overlays/laravel.md +0 -44
  65. package/skills/ai-humanizer/SKILL.md +0 -50
  66. package/skills/api-contract-generator/SKILL.md +0 -243
  67. package/skills/apply/SKILL.md +0 -23
  68. package/skills/archive/SKILL.md +0 -27
  69. package/skills/cerebro/SKILL.md +0 -187
  70. package/skills/cerebro/references/agents.md +0 -213
  71. package/skills/code-review/SKILL.md +0 -373
  72. package/skills/code-review/assets/report-template-agent.md +0 -212
  73. package/skills/code-review/assets/report-template-compact.md +0 -81
  74. package/skills/code-review/assets/report-template-full.md +0 -264
  75. package/skills/code-review/assets/report-template-human.md +0 -168
  76. package/skills/code-review/references/universal-patterns.md +0 -495
  77. package/skills/design-md/README.md +0 -34
  78. package/skills/design-md/SKILL.md +0 -172
  79. package/skills/design-md/examples/DESIGN.md +0 -154
  80. package/skills/design-system/SKILL.md +0 -216
  81. package/skills/design-system-generator/SKILL.md +0 -324
  82. package/skills/design-system-generator/assets/design-system-template.md +0 -348
  83. package/skills/design-system-generator/references/extraction-patterns.md +0 -321
  84. package/skills/doc-builder/SKILL.md +0 -115
  85. package/skills/doc-builder/references/ui-patterns.md +0 -394
  86. package/skills/document-explainer/SKILL.md +0 -155
  87. package/skills/document-translator/SKILL.md +0 -58
  88. package/skills/enhance/SKILL.md +0 -47
  89. package/skills/enhance-prompt/README.md +0 -34
  90. package/skills/enhance-prompt/SKILL.md +0 -204
  91. package/skills/enhance-prompt/references/KEYWORDS.md +0 -114
  92. package/skills/epic-generator/SKILL.md +0 -204
  93. package/skills/epic-single/SKILL.md +0 -63
  94. package/skills/erd-generator/SKILL.md +0 -138
  95. package/skills/feature-planner/SKILL.md +0 -305
  96. package/skills/feature-planner/assets/implementation-plan-template.md +0 -85
  97. package/skills/frontend-design/LICENSE.txt +0 -177
  98. package/skills/frontend-design/SKILL.md +0 -42
  99. package/skills/fsd-generator/SKILL.md +0 -163
  100. package/skills/gamma-builder/SKILL.md +0 -134
  101. package/skills/laravel-code-review/SKILL.md +0 -383
  102. package/skills/laravel-code-review/assets/report-template-agent.md +0 -195
  103. package/skills/laravel-code-review/assets/report-template-compact.md +0 -79
  104. package/skills/laravel-code-review/assets/report-template-full.md +0 -253
  105. package/skills/laravel-code-review/assets/report-template-human.md +0 -159
  106. package/skills/laravel-code-review/references/laravel-patterns.md +0 -571
  107. package/skills/laravel-code-review/references/php84-features.md +0 -442
  108. package/skills/mcp-builder/LICENSE.txt +0 -202
  109. package/skills/mcp-builder/SKILL.md +0 -236
  110. package/skills/mcp-builder/reference/evaluation.md +0 -602
  111. package/skills/mcp-builder/reference/mcp_best_practices.md +0 -249
  112. package/skills/mcp-builder/reference/node_mcp_server.md +0 -970
  113. package/skills/mcp-builder/reference/python_mcp_server.md +0 -719
  114. package/skills/mcp-builder/scripts/connections.py +0 -151
  115. package/skills/mcp-builder/scripts/evaluation.py +0 -373
  116. package/skills/mcp-builder/scripts/example_evaluation.xml +0 -22
  117. package/skills/mcp-builder/scripts/requirements.txt +0 -2
  118. package/skills/meeting-notes/SKILL.md +0 -159
  119. package/skills/meeting-notes/evals/evals.json +0 -23
  120. package/skills/prd-agent-generator/SKILL.md +0 -132
  121. package/skills/prd-generator/SKILL.md +0 -211
  122. package/skills/product-brief/SKILL.md +0 -141
  123. package/skills/project-orchestrator/SKILL.md +0 -487
  124. package/skills/project-orchestrator/assets/caddy-vps-setup.md +0 -180
  125. package/skills/project-orchestrator/assets/plan-summary-template.md +0 -159
  126. package/skills/prompter-specs/SKILL.md +0 -115
  127. package/skills/prompter-workflow/SKILL.md +0 -166
  128. package/skills/prompter-workflow/evals/evals.json +0 -89
  129. package/skills/proposal/SKILL.md +0 -28
  130. package/skills/qa-test-scenario/SKILL.md +0 -149
  131. package/skills/skill-creator/SKILL.md +0 -173
  132. package/skills/sph-generator/SKILL.md +0 -488
  133. package/skills/story-generator/SKILL.md +0 -285
  134. package/skills/story-single/SKILL.md +0 -86
  135. package/skills/tdd-generator/SKILL.md +0 -300
  136. package/skills/tdd-lite-generator/SKILL.md +0 -230
  137. package/skills/ui-ux-pro/SKILL.md +0 -199
  138. package/skills/ui-ux-pro/assets/design-spec-template.md +0 -173
  139. package/skills/ui-ux-pro/references/component-patterns.md +0 -255
  140. package/skills/ui-ux-pro/references/design-principles.md +0 -167
  141. package/skills/wireframe-generator/SKILL.md +0 -227
  142. package/src/cli/index.ts +0 -223
  143. package/src/commands/archive.ts +0 -302
  144. package/src/commands/change.ts +0 -292
  145. package/src/commands/config.ts +0 -233
  146. package/src/commands/guide.ts +0 -50
  147. package/src/commands/init.ts +0 -597
  148. package/src/commands/list.ts +0 -194
  149. package/src/commands/show.ts +0 -138
  150. package/src/commands/spec.ts +0 -251
  151. package/src/commands/update.ts +0 -129
  152. package/src/commands/upgrade.ts +0 -30
  153. package/src/commands/validate.ts +0 -326
  154. package/src/core/artifact-graph/graph.ts +0 -167
  155. package/src/core/artifact-graph/index.ts +0 -44
  156. package/src/core/artifact-graph/instruction-loader.ts +0 -302
  157. package/src/core/artifact-graph/resolver.ts +0 -226
  158. package/src/core/artifact-graph/schema.ts +0 -124
  159. package/src/core/artifact-graph/state.ts +0 -64
  160. package/src/core/artifact-graph/types.ts +0 -65
  161. package/src/core/completions/command-registry.ts +0 -382
  162. package/src/core/completions/completion-provider.ts +0 -128
  163. package/src/core/completions/generators/bash-generator.ts +0 -191
  164. package/src/core/completions/generators/fish-generator.ts +0 -188
  165. package/src/core/completions/generators/powershell-generator.ts +0 -223
  166. package/src/core/completions/generators/zsh-generator.ts +0 -281
  167. package/src/core/completions/templates/bash-templates.ts +0 -24
  168. package/src/core/completions/templates/fish-templates.ts +0 -40
  169. package/src/core/completions/templates/powershell-templates.ts +0 -25
  170. package/src/core/completions/templates/zsh-templates.ts +0 -36
  171. package/src/core/completions/types.ts +0 -90
  172. package/src/core/config-schema.ts +0 -230
  173. package/src/core/config.ts +0 -181
  174. package/src/core/configurators/slash/antigravity.ts +0 -10
  175. package/src/core/configurators/slash/base.ts +0 -109
  176. package/src/core/configurators/slash/claude.ts +0 -10
  177. package/src/core/configurators/slash/codex.ts +0 -10
  178. package/src/core/configurators/slash/droid.ts +0 -10
  179. package/src/core/configurators/slash/forge.ts +0 -10
  180. package/src/core/configurators/slash/github-copilot.ts +0 -10
  181. package/src/core/configurators/slash/index.ts +0 -10
  182. package/src/core/configurators/slash/kilocode.ts +0 -10
  183. package/src/core/configurators/slash/opencode.ts +0 -10
  184. package/src/core/configurators/slash/registry.ts +0 -51
  185. package/src/core/converters/json-converter.ts +0 -62
  186. package/src/core/global-config.ts +0 -136
  187. package/src/core/parsers/change-parser.ts +0 -234
  188. package/src/core/parsers/markdown-parser.ts +0 -237
  189. package/src/core/parsers/requirement-blocks.ts +0 -234
  190. package/src/core/prompt-templates.ts +0 -3504
  191. package/src/core/schemas/base.schema.ts +0 -20
  192. package/src/core/schemas/change.schema.ts +0 -42
  193. package/src/core/schemas/index.ts +0 -20
  194. package/src/core/schemas/spec.schema.ts +0 -17
  195. package/src/core/skill-discovery.ts +0 -68
  196. package/src/core/specs-apply.ts +0 -483
  197. package/src/core/styles/palette.ts +0 -8
  198. package/src/core/templates/agents-template.ts +0 -459
  199. package/src/core/templates/claude-template.ts +0 -2
  200. package/src/core/templates/index.ts +0 -3
  201. package/src/core/templates/project-template.ts +0 -32
  202. package/src/core/validation/constants.ts +0 -48
  203. package/src/core/validation/types.ts +0 -19
  204. package/src/core/validation/validator.ts +0 -449
  205. package/src/core/view.ts +0 -219
  206. package/src/index.ts +0 -1
  207. package/src/utils/change-metadata.ts +0 -171
  208. package/src/utils/change-utils.ts +0 -131
  209. package/src/utils/file-system.ts +0 -252
  210. package/src/utils/index.ts +0 -12
  211. package/src/utils/interactive.ts +0 -29
  212. package/src/utils/item-discovery.ts +0 -66
  213. package/src/utils/match.ts +0 -26
  214. package/src/utils/shell-detection.ts +0 -62
  215. package/src/utils/task-progress.ts +0 -43
  216. package/tsconfig.json +0 -28
package/convex-setup.md DELETED
@@ -1,403 +0,0 @@
1
- # Convex Self-Hosted Setup Guide
2
-
3
- This document explains how to set up a self-hosted Convex deployment for this project using the official Convex self-hosted flow.
4
-
5
- It covers:
6
-
7
- - the Convex backend container
8
- - the Convex dashboard container
9
- - the frontend app connected through `VITE_CONVEX_URL`
10
- - the Convex CLI workflow for deploying schema and functions to a self-hosted instance
11
-
12
- ## Official self-hosted flow
13
-
14
- The official Convex self-hosted documentation uses this sequence:
15
-
16
- 1. start the backend and dashboard
17
- 2. generate the admin key from the running backend container
18
- 3. save `CONVEX_SELF_HOSTED_URL` and `CONVEX_SELF_HOSTED_ADMIN_KEY` in `.env.local`
19
- 4. use the Convex CLI to deploy schema and functions
20
- 5. run queries, mutations, imports, or seeds against the self-hosted backend
21
-
22
- Important:
23
-
24
- - The CLI admin key is generated from the running backend.
25
- - Do not assume the Docker env value `CONVEX_ADMIN_KEY` is the same value the CLI expects.
26
- - Do not use a random `openssl rand -hex 32` string as `CONVEX_SELF_HOSTED_ADMIN_KEY` unless Convex explicitly tells you to do so for your setup.
27
-
28
- ## How this project is wired
29
-
30
- ### Frontend
31
-
32
- The frontend creates the Convex React client from `VITE_CONVEX_URL`:
33
-
34
- ```ts
35
- const convex = new ConvexReactClient(import.meta.env.VITE_CONVEX_URL as string);
36
- ```
37
-
38
- That means:
39
-
40
- - `VITE_CONVEX_URL` must be reachable by the browser
41
- - the frontend needs this value during local development
42
- - when building the Docker image, the same value must be passed as a build argument
43
-
44
- ### Deploy script
45
-
46
- This project exposes a self-hosted deploy script in `package.json`:
47
-
48
- ```json
49
- {
50
- "scripts": {
51
- "deploy:selfhosted": "convex deploy --url $CONVEX_SELF_HOSTED_URL --admin-key $CONVEX_SELF_HOSTED_ADMIN_KEY"
52
- }
53
- }
54
- ```
55
-
56
- ## Prerequisites
57
-
58
- Install these first:
59
-
60
- - Node.js 22+
61
- - npm
62
- - Docker Desktop or Docker Engine with Compose
63
- - project dependencies installed with `npm install`
64
-
65
- If `node` or `npm` are missing from your `PATH`, use the Node 22 install configured for this project:
66
-
67
- ```bash
68
- export PATH="$HOME/.nvm/versions/node/v22.17.1/bin:$PATH"
69
- ```
70
-
71
- ## Environment variables used by this project
72
-
73
- This project uses two different configuration contexts.
74
-
75
- ### 1. Docker Compose environment
76
-
77
- The compose stack reads values such as:
78
-
79
- ```env
80
- APP_ENV=dev
81
- WEB_PORT=8080
82
- CONVEX_PORT=3220
83
- CONVEX_DASHBOARD_PORT=3221
84
- CONVEX_DASHBOARD_UI_PORT=6792
85
- VITE_CONVEX_URL=http://localhost:3220
86
- CONVEX_ADMIN_KEY=replace-with-placeholder-if-needed
87
- CONVEX_CLOUD_ORIGIN=http://localhost:3220
88
- CONVEX_SITE_ORIGIN=http://localhost:6792
89
- ```
90
-
91
- Notes:
92
-
93
- - `CONVEX_ADMIN_KEY` is passed into the backend container.
94
- - In practice, the Convex CLI should use the admin key generated from the running backend container.
95
- - `CONVEX_CLOUD_ORIGIN` should point to the backend API origin.
96
- - `CONVEX_SITE_ORIGIN` should point to the dashboard UI origin.
97
-
98
- ### 2. Local CLI and frontend environment
99
-
100
- For local development, `.env.local` should contain:
101
-
102
- ```env
103
- VITE_CONVEX_URL=http://localhost:3220
104
- CONVEX_SELF_HOSTED_URL=http://localhost:3220
105
- CONVEX_SELF_HOSTED_ADMIN_KEY=convex-self-hosted|generated-from-container
106
- ```
107
-
108
- Notes:
109
-
110
- - `VITE_CONVEX_URL` is used by the frontend.
111
- - `CONVEX_SELF_HOSTED_URL` and `CONVEX_SELF_HOSTED_ADMIN_KEY` are used by the Convex CLI.
112
- - `.env.local` should not be committed.
113
-
114
- ## Reference Docker Compose pattern
115
-
116
- This project uses the same high-level pattern as the official self-hosted documentation: one backend service and one dashboard service.
117
-
118
- ```yaml
119
- services:
120
- convex:
121
- image: ghcr.io/get-convex/convex-backend:latest
122
- ports:
123
- - "${CONVEX_PORT:-3210}:3210"
124
- - "${CONVEX_DASHBOARD_PORT:-3211}:3211"
125
- volumes:
126
- - convex-data:/convex/data
127
- environment:
128
- CONVEX_ADMIN_KEY: ${CONVEX_ADMIN_KEY}
129
- CONVEX_CLOUD_ORIGIN: ${CONVEX_CLOUD_ORIGIN}
130
- CONVEX_SITE_ORIGIN: ${CONVEX_SITE_ORIGIN}
131
-
132
- convex-dashboard:
133
- image: ghcr.io/get-convex/convex-dashboard:latest
134
- depends_on:
135
- convex:
136
- condition: service_started
137
- ports:
138
- - "${CONVEX_DASHBOARD_UI_PORT:-6791}:6791"
139
- environment:
140
- NEXT_PUBLIC_DEPLOYMENT_URL: ${CONVEX_CLOUD_ORIGIN}
141
- NEXT_PUBLIC_LOAD_MONACO_INTERNALLY: "true"
142
-
143
- volumes:
144
- convex-data:
145
- ```
146
-
147
- In this repository, the actual compose file also includes a `web` service for the frontend.
148
-
149
- ## Step-by-step setup for this project
150
-
151
- ### 1. Install dependencies
152
-
153
- From the repository root:
154
-
155
- ```bash
156
- npm install
157
- ```
158
-
159
- ### 2. Create `.env.dev`
160
-
161
- Copy the development template:
162
-
163
- ```bash
164
- cp env.dev.example .env.dev
165
- ```
166
-
167
- Recommended local values:
168
-
169
- ```env
170
- APP_ENV=dev
171
- WEB_PORT=8080
172
- CONVEX_PORT=3220
173
- CONVEX_DASHBOARD_PORT=3221
174
- CONVEX_DASHBOARD_UI_PORT=6792
175
- VITE_CONVEX_URL=http://localhost:3220
176
- CONVEX_ADMIN_KEY=replace-with-placeholder-if-needed
177
- CONVEX_CLOUD_ORIGIN=http://localhost:3220
178
- CONVEX_SITE_ORIGIN=http://localhost:6792
179
- ```
180
-
181
- Important:
182
-
183
- - Treat `CONVEX_ADMIN_KEY` here as backend container configuration.
184
- - Do not copy this value into `CONVEX_SELF_HOSTED_ADMIN_KEY` for CLI usage unless you have confirmed it is the generated self-hosted admin key for your instance.
185
-
186
- ### 3. Create `.env.local`
187
-
188
- Create the local file with the frontend URL first:
189
-
190
- ```bash
191
- cat > .env.local <<'EOF'
192
- VITE_CONVEX_URL=http://localhost:3220
193
- EOF
194
- ```
195
-
196
- You will append the self-hosted CLI settings after the backend starts and after you generate the real admin key.
197
-
198
- ### 4. Start the Convex backend and dashboard
199
-
200
- Run:
201
-
202
- ```bash
203
- docker compose --env-file .env.dev up -d convex convex-dashboard
204
- ```
205
-
206
- Check status:
207
-
208
- ```bash
209
- docker compose --env-file .env.dev ps
210
- ```
211
-
212
- Expected result:
213
-
214
- - `convex` is running
215
- - `convex-dashboard` is running
216
-
217
- By default for local development in this project:
218
-
219
- - backend API is available at `http://localhost:3220`
220
- - backend dashboard/API port is mapped at `http://localhost:3221`
221
- - dashboard UI is available at `http://localhost:6792`
222
-
223
- ## 5. Generate the real self-hosted admin key
224
-
225
- After the backend is running, generate the admin key from the live Convex container.
226
-
227
- Run:
228
-
229
- ```bash
230
- docker compose --env-file .env.dev exec convex ./generate_admin_key.sh
231
- ```
232
-
233
- Expected output format:
234
-
235
- ```text
236
- convex-self-hosted|...
237
- ```
238
-
239
- Copy that exact value.
240
-
241
- Now append the self-hosted CLI settings to `.env.local`:
242
-
243
- ```bash
244
- cat >> .env.local <<'EOF'
245
- CONVEX_SELF_HOSTED_URL=http://localhost:3220
246
- CONVEX_SELF_HOSTED_ADMIN_KEY=paste-the-generated-key-here
247
- EOF
248
- ```
249
-
250
- Important:
251
-
252
- - Use the generated key exactly as printed.
253
- - If you later recreate the backend state, generate the key again.
254
- - If the backend uses a persistent Docker volume, the instance credentials can persist across restarts.
255
-
256
- ## 6. Deploy schema and functions
257
-
258
- With `.env.local` configured, deploy the Convex schema and functions:
259
-
260
- ```bash
261
- npm run deploy:selfhosted
262
- ```
263
-
264
- Equivalent raw command:
265
-
266
- ```bash
267
- convex deploy --url "$CONVEX_SELF_HOSTED_URL" --admin-key "$CONVEX_SELF_HOSTED_ADMIN_KEY"
268
- ```
269
-
270
- If deployment succeeds, the self-hosted backend now has the current Convex schema and functions.
271
-
272
- ### Project-specific warning
273
-
274
- This repository currently has a known self-hosted compatibility issue in `convex/schema.ts`: reserved index names such as `by_id` can cause deploy to fail on self-hosted Convex.
275
-
276
- If you see an error like:
277
-
278
- ```text
279
- IndexNameReserved: In table "agents" cannot name an index "by_id"
280
- ```
281
-
282
- rename the reserved index names to something non-reserved such as `by_external_id`, then deploy again.
283
-
284
- ## 7. Seed or run commands against the backend
285
-
286
- Once deploy succeeds, you can run Convex commands against the self-hosted instance.
287
-
288
- For this project's seed function:
289
-
290
- ```bash
291
- npx convex run seed:run '{}' \
292
- --url http://localhost:3220 \
293
- --admin-key "$CONVEX_SELF_HOSTED_ADMIN_KEY"
294
- ```
295
-
296
- You can also use other CLI commands after configuration, for example:
297
-
298
- ```bash
299
- npx convex --help
300
- ```
301
-
302
- ## 8. Run the frontend locally
303
-
304
- Start the frontend development server:
305
-
306
- ```bash
307
- npm run dev
308
- ```
309
-
310
- Open the local Vite URL shown in the terminal, typically:
311
-
312
- ```text
313
- http://localhost:5173
314
- ```
315
-
316
- ## 9. Optional Dockerized frontend
317
-
318
- If you want to run the frontend through Docker Compose too:
319
-
320
- ```bash
321
- docker compose --env-file .env.dev up -d --build
322
- ```
323
-
324
- This project passes `VITE_CONVEX_URL` as a Docker build argument so the Vite app can be built with the correct public backend URL.
325
-
326
- ## Verification checklist
327
-
328
- - `npm install` completes successfully
329
- - `docker compose --env-file .env.dev up -d convex convex-dashboard` succeeds
330
- - `docker compose --env-file .env.dev exec convex ./generate_admin_key.sh` returns a `convex-self-hosted|...` key
331
- - `.env.local` contains `VITE_CONVEX_URL`, `CONVEX_SELF_HOSTED_URL`, and the generated `CONVEX_SELF_HOSTED_ADMIN_KEY`
332
- - `npm run deploy:selfhosted` succeeds
333
- - any seed or query command against the backend succeeds
334
- - `npm run dev` starts the frontend successfully
335
- - the frontend can load data from Convex
336
-
337
- ## Common mistakes
338
-
339
- - using `.env.dev`'s `CONVEX_ADMIN_KEY` as the CLI admin key without generating the real self-hosted key from the container
340
- - using a random string as `CONVEX_SELF_HOSTED_ADMIN_KEY`
341
- - forgetting to deploy schema and functions before running seed commands
342
- - using a `VITE_CONVEX_URL` that the browser cannot reach
343
- - assuming changing `.env.dev` automatically updates credentials already persisted in a Docker volume
344
- - overlooking self-hosted restrictions such as reserved index names during deploy
345
-
346
- ## Troubleshooting
347
-
348
- ### `401 Unauthorized: BadAdminKey`
349
-
350
- Cause:
351
-
352
- - the CLI is using the wrong admin key
353
-
354
- Fix:
355
-
356
- 1. make sure the backend is running
357
- 2. run `docker compose --env-file .env.dev exec convex ./generate_admin_key.sh`
358
- 3. copy the printed `convex-self-hosted|...` value into `.env.local` as `CONVEX_SELF_HOSTED_ADMIN_KEY`
359
- 4. retry deploy or seed
360
-
361
- ### `Could not find function for 'seed:run'`
362
-
363
- Cause:
364
-
365
- - deploy has not succeeded yet, so the function is not available on the backend
366
-
367
- Fix:
368
-
369
- 1. resolve the deploy error first
370
- 2. rerun `npm run deploy:selfhosted`
371
- 3. rerun the seed command
372
-
373
- ### `IndexNameReserved`
374
-
375
- Cause:
376
-
377
- - the schema defines a reserved index name such as `by_id`
378
-
379
- Fix:
380
-
381
- - rename the reserved index to a non-reserved name such as `by_external_id`
382
- - redeploy
383
-
384
- ### Frontend fails because `VITE_CONVEX_URL` is missing
385
-
386
- Cause:
387
-
388
- - `.env.local` is missing or incomplete
389
-
390
- Fix:
391
-
392
- - recreate `.env.local`
393
- - restart the frontend dev server
394
-
395
- ## Files in this project you can reuse as references
396
-
397
- - `package.json`
398
- - `docker-compose.yml`
399
- - `Dockerfile`
400
- - `env.dev.example`
401
- - `env.prod.example`
402
- - `src/providers/ConvexClientProvider.tsx`
403
- - `prompter/changes/add-convex-backend/guide.md`
@@ -1,45 +0,0 @@
1
- SYSTEM INSTRUCTIONS:
2
-
3
- DEEP CONDITIONING: Do not use em dashes (—) UNDER ANY CIRCUMSTANCE. All em dashes must be replaced with commas, periods, semicolons, or fully rewritten for natural flow. This rule overrides all other writing, grammar, or tone guidelines. If an em dash appears in the original draft, it must be rewritten during editing. The use of em dash for the final output is STRICTLY PROHIBITED.
4
-
5
- # Role
6
- You are an expert copywriter and proofreader. Your mission is to meticulously review and refine all draft content (including blogs, emails, newsletters, and social media captions), ensuring every word flows naturally, embodies a friendly-yet-authoritative voice, and is fully publication-ready.
7
-
8
- # Core Objectives
9
- 1. Human-Centric, Conversational Voice:** Ensure all text reads as genuinely conversational, empathetic, and authoritative in a friendly expert tone.
10
-
11
- 2. Remove AI Hallmarks: Eliminate any sign of AI-generated writing—robotic phrasing, self-references, overly formal transitions, excessive qualifiers, and symbols such as em dashes. Cross-reference the “GPT Humanization.txt” checklist for each draft.
12
-
13
- 3. Clarity, Accuracy, Proofreading, and Redundancy Prevention:
14
- - Proofread for absolute clarity and accuracy.
15
- - Correct all grammar, spelling, and punctuation errors.
16
- - Eliminate redundant sentences and repetitive information.
17
- - Ensure proper punctuation usage throughout.
18
- - Favor contractions and natural fragments; remove redundancy and avoid formulaic lists (“firstly/secondly/thirdly”).
19
-
20
- 4. Brand Standards & Formatting:
21
- - Use only approved vocabulary and phrasing from the style guide.
22
- - Apply formatting for headings, subheadings, paragraphs, and iconography exactly as specified. Avoid symbol overuse.
23
- - Ensure product names and calls-to-action are consistent and always benefit-focused.
24
-
25
- 5. Actionable Feedback: Provide specific, actionable feedback for every change:
26
- - Highlight all edits with concise explanations (e.g., “Changed ‘Moreover’ to ‘Plus’ for a friendlier flow”).
27
- - Suggest detailed rewrites for areas needing substantial revision.
28
-
29
- # Interaction Protocol
30
- - Always ask the user to provide the complete draft text before beginning any proofreading.
31
-
32
- # Output Requirements
33
- - A clean, final draft incorporating all changes, with no em dash throughout the entire output.
34
-
35
- # Tone and Style
36
- - Maintain a professional, neutral, and supportive tone.
37
- - Avoid clinical, alarmist, or overly formal language.
38
- - Ensure content is always clear, universally accessible, and empathetic.
39
-
40
- # Important Reminders
41
- - Never use em dashes (—). Replace all em dashes with commas, periods, semicolons, or restructured phrasing; this overrides all other stylistic considerations.
42
- - Watch for and eliminate em dashes from both the input and the output.
43
- - Prevent redundancies of text, sentences, and information.
44
- - Be vigilant about proper punctuation in every sentence.
45
- - Ensure the final output is indistinguishable from human writing.
@@ -1,234 +0,0 @@
1
- # API Contract Generator Prompt
2
-
3
- # Role & Expertise
4
- You are a Senior API Architect and Technical Documentation Specialist with extensive experience in RESTful API design, OpenAPI/Swagger specifications, and translating business requirements into precise technical contracts. You have deep expertise in data modeling, HTTP standards, and enterprise integration patterns.
5
-
6
- # Context
7
- You will receive a Functional Specification Document (FSD) and an Entity Relationship Diagram (ERD) as inputs. Your task is to synthesize these artifacts into a comprehensive API contract that developers can immediately implement. The API contract must accurately reflect the business logic from the FSD while respecting the data structures defined in the ERD.
8
-
9
- # Primary Objective
10
- Generate a complete, production-ready API contract in OpenAPI 3.0+ specification format that:
11
- - Covers all functional requirements from the FSD
12
- - Aligns data models with the ERD entities and relationships
13
- - Follows REST best practices and industry standards
14
- - Is immediately usable for development and API documentation tools
15
-
16
- # Process
17
-
18
- ## Phase 1: Analysis
19
- 1. **FSD Extraction**
20
- - Identify all user stories/use cases
21
- - Extract business rules and validation requirements
22
- - Map functional flows to potential API operations
23
- - Note authentication/authorization requirements
24
- - Identify error scenarios and edge cases
25
-
26
- 2. **ERD Interpretation**
27
- - Catalog all entities and their attributes
28
- - Map data types to API schema types
29
- - Identify relationships (1:1, 1:N, M:N)
30
- - Note required vs optional fields
31
- - Identify unique constraints and keys
32
-
33
- 3. **Cross-Reference Mapping**
34
- - Link FSD operations to ERD entities
35
- - Identify CRUD requirements per entity
36
- - Map business validations to schema constraints
37
- - Determine resource hierarchies and nesting
38
-
39
- ## Phase 2: API Design
40
- 1. **Resource Modeling**
41
- - Define REST resources from entities
42
- - Establish URL hierarchy and naming
43
- - Determine resource representations (full, summary, reference)
44
-
45
- 2. **Endpoint Definition**
46
- - Map operations to HTTP methods
47
- - Define path parameters and query parameters
48
- - Establish pagination, filtering, sorting patterns
49
-
50
- 3. **Schema Development**
51
- - Create request/response schemas
52
- - Define reusable components
53
- - Establish enum types from domain values
54
-
55
- 4. **Security & Error Handling**
56
- - Define authentication schemes
57
- - Create standard error response formats
58
- - Map business errors to HTTP status codes
59
-
60
- ## Phase 3: Contract Generation
61
- 1. Compile OpenAPI specification
62
- 2. Add comprehensive descriptions
63
- 3. Include request/response examples
64
- 4. Document edge cases and constraints
65
-
66
- # Input Specifications
67
-
68
- **Functional Specification Document (FSD):**
69
- - Business requirements and user stories
70
- - Functional flows and processes
71
- - Business rules and validations
72
- - User roles and permissions
73
- - Expected system behaviors
74
-
75
- **Entity Relationship Diagram (ERD):**
76
- - Entity names and descriptions
77
- - Attributes with data types
78
- - Primary and foreign keys
79
- - Relationship cardinalities
80
- - Constraints and indexes
81
-
82
- # Output Requirements
83
-
84
- **Format:** OpenAPI 3.0+ YAML specification
85
-
86
- **Required Sections:**
87
-
88
- yaml
89
- openapi: 3.0.x
90
- info:
91
- title: [API Name]
92
- description: [Comprehensive API description]
93
- version: [Version]
94
-
95
- servers:
96
- - url: [Base URL patterns]
97
-
98
- tags:
99
- - [Logical groupings of endpoints]
100
-
101
- paths:
102
- [All endpoints with full specifications]
103
-
104
- components:
105
- schemas:
106
- [All data models derived from ERD]
107
- parameters:
108
- [Reusable parameters]
109
- responses:
110
- [Standard response definitions]
111
- securitySchemes:
112
- [Authentication methods]
113
- examples:
114
- [Request/response examples]
115
-
116
- security:
117
- [Global security requirements]
118
-
119
- **Per Endpoint Requirements:**
120
- - Summary and detailed description
121
- - Operation ID (for code generation)
122
- - Tags for grouping
123
- - All parameters (path, query, header)
124
- - Request body with schema reference
125
- - All possible responses (2xx, 4xx, 5xx)
126
- - Security requirements
127
- - At least one example per request/response
128
-
129
- **Schema Requirements:**
130
- - All properties with types and descriptions
131
- - Required fields array
132
- - Validation constraints (minLength, maxLength, pattern, minimum, maximum, enum)
133
- - Nullable indicators
134
- - Example values
135
-
136
- # Quality Standards
137
-
138
- 1. **Completeness**
139
- - Every FSD requirement maps to at least one endpoint
140
- - Every ERD entity has corresponding schema(s)
141
- - All CRUD operations covered where applicable
142
-
143
- 2. **Consistency**
144
- - Uniform naming conventions (camelCase for properties, kebab-case for URLs)
145
- - Consistent response structures across endpoints
146
- - Standard pagination/filtering patterns
147
-
148
- 3. **Accuracy**
149
- - Data types match ERD definitions
150
- - Validations reflect business rules
151
- - Relationships properly represented in nested/linked resources
152
-
153
- 4. **Usability**
154
- - Clear, actionable descriptions
155
- - Meaningful examples
156
- - Logical endpoint organization
157
-
158
- 5. **Standards Compliance**
159
- - Valid OpenAPI 3.0+ syntax
160
- - RESTful conventions followed
161
- - HTTP semantics correctly applied
162
-
163
- # Special Instructions
164
-
165
- **Naming Conventions:**
166
- - Resources: plural nouns (e.g., `/users`, `/orders`)
167
- - Endpoints: `kebab-case`
168
- - Schema names: `PascalCase`
169
- - Properties: `camelCase`
170
- - Query parameters: `camelCase`
171
-
172
- **Standard Patterns to Apply:**
173
-
174
- | Operation | Method | Path Pattern | Success Code |
175
- |-----------|--------|--------------|--------------|
176
- | List | GET | /resources | 200 |
177
- | Get One | GET | /resources/{id} | 200 |
178
- | Create | POST | /resources | 201 |
179
- | Full Update | PUT | /resources/{id} | 200 |
180
- | Partial Update | PATCH | /resources/{id} | 200 |
181
- | Delete | DELETE | /resources/{id} | 204 |
182
-
183
- **Pagination Standard:**
184
- yaml
185
- parameters:
186
- - name: page
187
- in: query
188
- schema:
189
- type: integer
190
- default: 1
191
- - name: limit
192
- in: query
193
- schema:
194
- type: integer
195
- default: 20
196
- maximum: 100
197
-
198
- **Error Response Standard:**
199
- yaml
200
- ErrorResponse:
201
- type: object
202
- required:
203
- - code
204
- - message
205
- properties:
206
- code:
207
- type: string
208
- message:
209
- type: string
210
- details:
211
- type: array
212
- items:
213
- type: object
214
- properties:
215
- field:
216
- type: string
217
- issue:
218
- type: string
219
-
220
- **Relationship Handling:**
221
- - 1:1 → Embed or link with reference ID
222
- - 1:N → Nested collection endpoint or link array
223
- - M:N → Separate join resource or array of references
224
-
225
- # Verification Checklist
226
-
227
- After generating the contract, verify:
228
- - [ ] All FSD use cases have corresponding endpoints
229
- - [ ] All ERD entities have schema definitions
230
- - [ ] All relationships are properly represented
231
- - [ ] Authentication is defined for protected endpoints
232
- - [ ] Error responses cover all documented error scenarios
233
- - [ ] Examples are valid against schemas
234
- - [ ] Specification validates against OpenAPI 3.0 schema
package/prompt/apply.md DELETED
@@ -1,17 +0,0 @@
1
- <!-- PROMPTER:START -->
2
- **Guardrails**
3
- - Favor straightforward, minimal implementations first and add complexity only when it is requested or clearly required.
4
- - Keep changes tightly scoped to the requested outcome.
5
- - Refer to `prompter/AGENTS.md` (located inside the `prompter/` directory—run `ls prompter` if you don't see it) if you need additional Prompter conventions or clarifications.
6
-
7
- **Steps**
8
- Track these steps as TODOs and complete them one by one.
9
- 1. Read `changes/<id>/proposal.md`, `design.md` (if present), and `tasks.md` to confirm scope and acceptance criteria.
10
- 2. Work through tasks sequentially, keeping edits minimal and focused on the requested change.
11
- 3. Confirm completion before updating statuses—make sure every item in `tasks.md` is finished.
12
- 4. Update the checklist after all work is done so each task is marked `- [x]` and reflects reality.
13
- 5. Reference `prompter list` or `prompter show <item>` when additional context is required.
14
-
15
- **Reference**
16
- - Use `prompter show <id> --json --deltas-only` if you need additional context from the proposal while implementing.
17
- <!-- PROMPTER:END -->