opencastle 0.5.1 → 0.6.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 (63) hide show
  1. package/dist/cli/adapters/claude-code.d.ts +2 -2
  2. package/dist/cli/adapters/claude-code.d.ts.map +1 -1
  3. package/dist/cli/adapters/claude-code.js +2 -2
  4. package/dist/cli/adapters/claude-code.js.map +1 -1
  5. package/dist/cli/adapters/cursor.d.ts +2 -2
  6. package/dist/cli/adapters/cursor.d.ts.map +1 -1
  7. package/dist/cli/adapters/cursor.js +2 -2
  8. package/dist/cli/adapters/cursor.js.map +1 -1
  9. package/dist/cli/adapters/vscode.d.ts +2 -2
  10. package/dist/cli/adapters/vscode.d.ts.map +1 -1
  11. package/dist/cli/adapters/vscode.js +2 -2
  12. package/dist/cli/adapters/vscode.js.map +1 -1
  13. package/dist/cli/detect.d.ts +18 -0
  14. package/dist/cli/detect.d.ts.map +1 -0
  15. package/dist/cli/detect.js +428 -0
  16. package/dist/cli/detect.js.map +1 -0
  17. package/dist/cli/gitignore.d.ts.map +1 -1
  18. package/dist/cli/gitignore.js +0 -2
  19. package/dist/cli/gitignore.js.map +1 -1
  20. package/dist/cli/init.d.ts.map +1 -1
  21. package/dist/cli/init.js +17 -3
  22. package/dist/cli/init.js.map +1 -1
  23. package/dist/cli/mcp.d.ts +2 -2
  24. package/dist/cli/mcp.d.ts.map +1 -1
  25. package/dist/cli/mcp.js +2 -2
  26. package/dist/cli/mcp.js.map +1 -1
  27. package/dist/cli/prompt.d.ts +3 -0
  28. package/dist/cli/prompt.d.ts.map +1 -1
  29. package/dist/cli/prompt.js +96 -0
  30. package/dist/cli/prompt.js.map +1 -1
  31. package/dist/cli/stack-config.d.ts +3 -3
  32. package/dist/cli/stack-config.d.ts.map +1 -1
  33. package/dist/cli/stack-config.js +16 -5
  34. package/dist/cli/stack-config.js.map +1 -1
  35. package/dist/cli/types.d.ts +20 -1
  36. package/dist/cli/types.d.ts.map +1 -1
  37. package/dist/cli/update.d.ts.map +1 -1
  38. package/dist/cli/update.js +6 -0
  39. package/dist/cli/update.js.map +1 -1
  40. package/package.json +1 -1
  41. package/src/cli/adapters/claude-code.ts +5 -3
  42. package/src/cli/adapters/cursor.ts +5 -3
  43. package/src/cli/adapters/vscode.ts +5 -3
  44. package/src/cli/detect.ts +483 -0
  45. package/src/cli/gitignore.ts +0 -3
  46. package/src/cli/init.ts +18 -3
  47. package/src/cli/mcp.ts +4 -3
  48. package/src/cli/prompt.ts +123 -0
  49. package/src/cli/stack-config.ts +19 -6
  50. package/src/cli/types.ts +21 -1
  51. package/src/cli/update.ts +7 -0
  52. package/src/dashboard/node_modules/.vite/deps/_metadata.json +6 -6
  53. package/src/orchestrator/agents/api-designer.agent.md +1 -1
  54. package/src/orchestrator/agents/content-engineer.agent.md +1 -1
  55. package/src/orchestrator/agents/database-engineer.agent.md +1 -1
  56. package/src/orchestrator/agents/developer.agent.md +1 -1
  57. package/src/orchestrator/agents/performance-expert.agent.md +1 -1
  58. package/src/orchestrator/agents/researcher.agent.md +16 -0
  59. package/src/orchestrator/agents/reviewer.agent.md +2 -4
  60. package/src/orchestrator/agents/team-lead.agent.md +41 -63
  61. package/src/orchestrator/agents/ui-ux-expert.agent.md +1 -1
  62. package/src/orchestrator/mcp.json +16 -8
  63. package/src/orchestrator/prompts/bootstrap-customizations.prompt.md +53 -6
@@ -23,19 +23,52 @@ Without customizations, agents operate blind — they don't know the project's t
23
23
 
24
24
  ## Pre-Existing Stack Info
25
25
 
26
- Before starting discovery, check for **`.opencastle.json`** in the project root. If it exists and contains a `stack` field, the user already declared their CMS, database, project management, and notifications tool during `opencastle init`. Use these as confirmed facts — skip re-detecting them and focus discovery on the project-specific details (IDs, schemas, config values).
26
+ Before starting discovery, check for **`.opencastle.json`** in the project root. If it exists, it contains a combined `repoInfo` field from `opencastle init` that merges two sources:
27
+
28
+ 1. **Auto-detected tooling** — the init command scanned config files, `package.json` dependencies, and directory structures
29
+ 2. **User-declared choices** — the user selected CMS, database, project management, and notifications via the interactive questionnaire
30
+
31
+ The result is a single unified view of the project's tech stack:
27
32
 
28
33
  ```json
29
34
  {
35
+ "repoInfo": {
36
+ "packageManager": "pnpm",
37
+ "monorepo": "nx",
38
+ "language": "typescript",
39
+ "frameworks": ["next", "astro"],
40
+ "databases": ["prisma", "supabase"],
41
+ "cms": ["sanity"],
42
+ "deployment": ["vercel"],
43
+ "testing": ["playwright", "vitest"],
44
+ "cicd": ["github-actions"],
45
+ "styling": ["css-modules", "tailwind"],
46
+ "auth": ["next-auth", "supabase-auth"],
47
+ "pm": ["linear"],
48
+ "notifications": ["slack"],
49
+ "mcpConfig": true,
50
+ "configFiles": ["nx.json", "package.json", "tsconfig.json", "vercel.json"]
51
+ },
30
52
  "stack": {
31
- "cms": "sanity", // sanity | contentful | strapi | none
32
- "db": "supabase", // supabase | convex | none
33
- "pm": "linear", // linear | jira | none
34
- "notifications": "slack" // slack | teams | none
53
+ "cms": "sanity",
54
+ "db": "supabase",
55
+ "pm": "linear",
56
+ "notifications": "slack"
35
57
  }
36
58
  }
37
59
  ```
38
60
 
61
+ **Use `repoInfo` to:**
62
+ - Skip re-scanning for technologies already listed — go straight to reading their config files
63
+ - Pre-fill the tech stack table in `project.instructions.md`
64
+ - Know which `stack/` config files to create (e.g., if `repoInfo.databases` includes `"prisma"`, create `stack/prisma-config.md`)
65
+ - Know which `project/` config files to create (e.g., if `repoInfo.pm` includes `"linear"`, create `project/linear-config.md`)
66
+ - Identify `configFiles` to read for deep inspection (Phase 1.3)
67
+
68
+ **`stack` vs `repoInfo`:** The `stack` field holds the raw user questionnaire answers (used internally for MCP server filtering and skill selection). The `repoInfo` field is the combined view you should use for discovery — it includes everything from `stack` plus all auto-detected tooling.
69
+
70
+ **Still verify:** `repoInfo` detects presence, not configuration details. You still need to read the actual config files for schemas, IDs, routes, etc.
71
+
39
72
  The skill matrix (`customizations/agents/skill-matrix.md`) will already have the `cms` and `database` rows pre-filled based on this selection. The appropriate task management skill (`task-management` for Linear, `jira-management` for Jira) and notifications skill (`slack-notifications` for Slack, `teams-notifications` for Teams) will already be installed. Verify they are correct and fill in any remaining empty rows.
40
73
 
41
74
  ## Workflow
@@ -46,7 +79,8 @@ Explore the project systematically. Gather facts — don't assume.
46
79
 
47
80
  #### 1.1 Project Overview
48
81
 
49
- - **First**: Read `.opencastle.json` if it exists — note the `stack.cms` and `stack.db` values
82
+ - **First**: Read `.opencastle.json` if it exists — note `stack` choices and `repoInfo` detections
83
+ - If `repoInfo` is present, use it as your starting inventory — skip re-scanning for the technologies it already lists
50
84
  - Read `README.md`, `package.json`, and any workspace config (`nx.json`, `turbo.json`, `pnpm-workspace.yaml`, `lerna.json`)
51
85
  - Identify: monorepo vs single app, package manager, language, framework(s)
52
86
  - List all apps and libraries with their purpose
@@ -227,6 +261,19 @@ For each file created, report:
227
261
 
228
262
  End with a summary of what was discovered, what was generated, and what (if anything) needs manual input (e.g., Linear team IDs that require API access to discover).
229
263
 
264
+ After your summary, suggest next steps:
265
+
266
+ ### Suggested Next Steps
267
+
268
+ Now that your project is configured, here's what you can do:
269
+
270
+ 1. **Review the generated files** — Scan `customizations/` for any `<!-- TODO: verify -->` comments and fill in missing values (e.g., Linear team IDs, Supabase project IDs)
271
+ 2. **Commit the customizations** — `git add .github/customizations/ && git commit -m "chore: bootstrap OpenCastle customizations"`
272
+ 3. **Implement a feature** — Use the **"Implement Feature"** prompt to have the Team Lead orchestrate a full feature build with task tracking, delegation, and verification
273
+ 4. **Fix a bug** — Use the **"Bug Fix"** prompt for structured triage, root cause analysis, and fix with Linear tracking
274
+ 5. **Brainstorm first** — Not sure how to approach something? Use the **"Brainstorm"** prompt to explore requirements and trade-offs before committing to a plan
275
+ 6. **Create a task spec** — Use the **"Generate Task Spec"** prompt to create `opencastle.tasks.yml` for autonomous overnight runs with `npx opencastle run` CLI command.
276
+
230
277
  ## Guidelines
231
278
 
232
279
  - **Discover, don't assume.** Read actual config files. Don't guess that the project uses Supabase because it's a Next.js app.