@locusai/mcp 0.1.6 → 0.1.7

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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,13 @@
1
1
  # @locusai/mcp
2
2
 
3
+ ## 0.1.7
4
+
5
+ ### Patch Changes
6
+
7
+ - - Workflow improvements
8
+ - Updated dependencies
9
+ - @locusai/shared@0.1.7
10
+
3
11
  ## 0.1.6
4
12
 
5
13
  ### Patch Changes
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@locusai/mcp",
3
- "version": "0.1.6",
3
+ "version": "0.1.7",
4
4
  "type": "module",
5
5
  "main": "src/index.ts",
6
6
  "dependencies": {
@@ -1,7 +1,6 @@
1
1
  import type { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
2
2
  import { z } from "zod";
3
3
  import { apiGet, apiPatch, apiPost, error, success } from "../api.js";
4
- import { projectDir } from "../config.js";
5
4
  import { ROLE_PROMPTS, type Sprint, type Task } from "../types.js";
6
5
 
7
6
  export function registerKanbanTools(server: McpServer): void {
@@ -178,69 +177,6 @@ export function registerKanbanTools(server: McpServer): void {
178
177
  }
179
178
  );
180
179
 
181
- // Commit changes
182
- server.registerTool(
183
- "kanban.commit",
184
- {
185
- title: "Commit Task Changes",
186
- description:
187
- "Create a git commit with the task ID in the message. Call this BEFORE moving to VERIFICATION to save your work.",
188
- inputSchema: {
189
- taskId: z.number(),
190
- additionalMessage: z.string().optional(),
191
- },
192
- },
193
- async ({ taskId, additionalMessage }) => {
194
- try {
195
- const task = await apiGet<Task>(`/tasks/${taskId}`);
196
-
197
- if (!task.title) {
198
- return error("Task not found");
199
- }
200
-
201
- // Build commit message
202
- let commitMessage = `Task #${taskId}: ${task.title}`;
203
- if (additionalMessage) {
204
- commitMessage += `\n\n${additionalMessage}`;
205
- }
206
-
207
- // Execute git commands
208
- const addProc = Bun.spawn(["git", "add", "-A"], {
209
- cwd: projectDir,
210
- stdout: "pipe",
211
- stderr: "pipe",
212
- });
213
- await addProc.exited;
214
-
215
- const commitProc = Bun.spawn(["git", "commit", "-m", commitMessage], {
216
- cwd: projectDir,
217
- stdout: "pipe",
218
- stderr: "pipe",
219
- });
220
- const exitCode = await commitProc.exited;
221
- const stdout = await new Response(commitProc.stdout).text();
222
- const stderr = await new Response(commitProc.stderr).text();
223
-
224
- if (exitCode !== 0) {
225
- return success({
226
- success: false,
227
- error: stderr || "Git commit failed",
228
- hint: "Make sure there are staged changes to commit",
229
- });
230
- }
231
-
232
- return success({
233
- success: true,
234
- message: `Committed changes for Task #${taskId}`,
235
- commitMessage,
236
- output: stdout,
237
- });
238
- } catch (e) {
239
- return error(String(e));
240
- }
241
- }
242
- );
243
-
244
180
  // Check acceptance criteria
245
181
  server.registerTool(
246
182
  "kanban.check",
package/src/types.ts CHANGED
@@ -27,42 +27,39 @@ export interface Sprint {
27
27
  export const ROLE_PROMPTS: Record<string, string> = {
28
28
  FRONTEND: `## Frontend Implementation Guidelines
29
29
 
30
- ### Design & Aesthetics
31
- - **Visual Excellence**: Create stunning, premium interfaces. Use vibrant colors, glassmorphism, and smooth animations. Avoid generic or flat designs.
32
- - **Modern Typography**: Use curated fonts (e.g., Inter, Roboto, Outfit). Avoid browser defaults.
33
- - **Dynamic Interactions**: Add hover effects, micro-animations, and fluid transitions to make the UI feel alive.
34
- - **Responsiveness**: Ensure flawless rendering across all device sizes.
30
+ ### Locus Design Aesthetics
31
+ - **Visual Excellence**: Create stunning, premium interfaces. Use vibrant, harmonious color palettes (avoid generic colors).
32
+ - **Glassmorphism & Depth**: Use subtle backgrounds, blurred overlays, and soft shadows to create depth.
33
+ - **Dynamic Interactions**: Implement smooth transitions, hover effects, and micro-animations for a responsive feel.
34
+ - **Typography**: Use modern, readable fonts (Inter, Roboto, Outfit). Ensure perfect hierarchy and spacing.
35
35
 
36
36
  ### Technical Standards
37
- - **Component-Driven**: Build small, reusable components. Use props for customization.
38
- - **State Management**: Keep state local where possible; use global state only when necessary.
39
- - **Clean Code**: Use semantic HTML, proper naming, and avoid inline styles (use CSS classes/variables).
40
- - **Performance**: Optimize images and minimize re-renders.
37
+ - **Component-Driven**: Build modular, reusable components with clear prop interfaces.
38
+ - **Modern CSS**: Use Vanilla CSS with variables for the design system. Avoid ad-hoc utilities.
39
+ - **Performance**: Optimize assets and minimize re-renders.
41
40
 
42
41
  ### Workflow Rules (CRITICAL)
43
- 1. **Branching**: A git branch is automatically created when task moves to IN_PROGRESS.
44
- 2. **Working**: Implement the task, check all acceptance criteria in the task.
45
- 3. **Committing**: Use \`kanban.commit\` when work is ready to save your changes.
46
- 4. **Completion**: Move task to **VERIFICATION** using \`kanban.move(taskId, "VERIFICATION")\`.
47
- 5. **NEVER move to DONE**: The system will reject direct DONE transitions. Only the manager can approve to DONE.
48
- 6. **If Rejected**: Check task comments for feedback, fix issues, commit again, and move back to VERIFICATION.`,
42
+ 1. **Implementation**: Build the feature based on the technical draft and acceptance criteria.
43
+ 2. **Verification**: Run \`bun run lint\` and \`bun run typecheck\`. Use \`ci.run(taskId, "quick")\` to validate your changes.
44
+ 3. **Submission**: Use \`kanban.check\` to mark items as done, then move to **VERIFICATION** using \`kanban.move(taskId, "VERIFICATION")\`.
45
+ 4. **NEVER move to DONE**: Only the manager can approve a task to DONE.
46
+ 5. **Rejection**: If rejected, review feedback in task comments and resubmit.`,
49
47
 
50
48
  BACKEND: `## Backend Implementation Guidelines
51
49
 
52
50
  ### Architecture & Quality
53
- - **Modularity**: Keep concerns separated (routes, controllers, services, db).
54
- - **Type Safety**: Use strict TypeScript types. Avoid \`any\`.
55
- - **Error Handling**: Gracefully handle errors and return standard HTTP status codes.
51
+ - **Modularity**: Use a strict Controller-Service-Repository pattern.
52
+ - **Type Safety**: Ensure 100% type coverage. Avoid \`any\`. Use Zod for validation.
53
+ - **Error Handling**: Use the centralized error handling middleware and return semantic HTTP status codes.
56
54
 
57
- ### Security & Performance
58
- - **Input Validation**: Validate all incoming data (zod/joi).
59
- - **Efficiency**: Optimize database queries and avoid N+1 problems.
55
+ ### Security & Efficiency
56
+ - **Data Integrity**: Use transactions where necessary. Optimize queries to avoid N+1 problems.
57
+ - **Security**: Sanitize all inputs and follow least privilege principles.
60
58
 
61
59
  ### Workflow Rules (CRITICAL)
62
- 1. **Branching**: A git branch is automatically created when task moves to IN_PROGRESS.
63
- 2. **Working**: Implement the task, check all acceptance criteria in the task.
64
- 3. **Committing**: Use \`kanban.commit\` when work is ready to save your changes.
65
- 4. **Completion**: Move task to **VERIFICATION** using \`kanban.move(taskId, "VERIFICATION")\`.
66
- 5. **NEVER move to DONE**: The system will reject direct DONE transitions. Only the manager can approve to DONE.
67
- 6. **If Rejected**: Check task comments for feedback, fix issues, commit again, and move back to VERIFICATION.`,
60
+ 1. **Implementation**: Implement core logic and endpoints according to the draft.
61
+ 2. **Verification**: Run \`bun run lint\` and \`bun run typecheck\`. Use \`ci.run(taskId, "quick")\` to validate your changes.
62
+ 3. **Submission**: Use \`kanban.check\` to mark items as done, then move to **VERIFICATION** using \`kanban.move(taskId, "VERIFICATION")\`.
63
+ 4. **NEVER move to DONE**: Only the manager can approve a task to DONE.
64
+ 5. **Rejection**: If rejected, review feedback in task comments and resubmit.`,
68
65
  };