feat: add Atlas PRD agent for product discovery
- src/prompts/atlas.ts — full Atlas system prompt (6-phase PM discovery flow) - src/tools/prd.ts — finalize_prd tool that signals PRD completion - src/agents/atlas.ts — Atlas agent config (Tier A, conversational) - src/atlas.ts — atlasChat() multi-turn session handler - server.ts — /atlas/chat, /atlas/sessions endpoints Made-with: Cursor
This commit is contained in:
1
dist/tools/index.d.ts
vendored
1
dist/tools/index.d.ts
vendored
@@ -6,6 +6,7 @@ import './coolify';
|
||||
import './agent';
|
||||
import './memory';
|
||||
import './skills';
|
||||
import './prd';
|
||||
export { ALL_TOOLS, executeTool, ToolDefinition } from './registry';
|
||||
export { ToolContext, MemoryUpdate } from './context';
|
||||
export { PROTECTED_GITEA_REPOS, PROTECTED_COOLIFY_PROJECT, PROTECTED_COOLIFY_APPS, assertGiteaWritable, assertCoolifyDeployable } from './security';
|
||||
|
||||
1
dist/tools/index.js
vendored
1
dist/tools/index.js
vendored
@@ -11,6 +11,7 @@ require("./coolify");
|
||||
require("./agent");
|
||||
require("./memory");
|
||||
require("./skills");
|
||||
require("./prd");
|
||||
// Re-export the public API — identical surface to the old tools.ts
|
||||
var registry_1 = require("./registry");
|
||||
Object.defineProperty(exports, "ALL_TOOLS", { enumerable: true, get: function () { return registry_1.ALL_TOOLS; } });
|
||||
|
||||
2
dist/tools/prd.d.ts
vendored
Normal file
2
dist/tools/prd.d.ts
vendored
Normal file
@@ -0,0 +1,2 @@
|
||||
/** Shared state — atlas.ts reads this after each turn to check if PRD was finalized. */
|
||||
export declare const prdStore: Map<string, string>;
|
||||
29
dist/tools/prd.js
vendored
Normal file
29
dist/tools/prd.js
vendored
Normal file
@@ -0,0 +1,29 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.prdStore = void 0;
|
||||
const registry_1 = require("./registry");
|
||||
/** Shared state — atlas.ts reads this after each turn to check if PRD was finalized. */
|
||||
exports.prdStore = new Map(); // sessionId → PRD markdown
|
||||
(0, registry_1.registerTool)({
|
||||
name: 'finalize_prd',
|
||||
description: 'Call this when you have finished writing the complete PRD document. Pass the full PRD markdown as content. This saves the document and signals to the user that discovery is complete.',
|
||||
parameters: {
|
||||
type: 'object',
|
||||
properties: {
|
||||
content: {
|
||||
type: 'string',
|
||||
description: 'The complete PRD document in markdown format'
|
||||
}
|
||||
},
|
||||
required: ['content']
|
||||
},
|
||||
async handler(args, ctx) {
|
||||
// Store against workspaceRoot as a unique key (each project has its own workspace)
|
||||
const sessionKey = ctx.workspaceRoot;
|
||||
exports.prdStore.set(sessionKey, String(args.content));
|
||||
return {
|
||||
saved: true,
|
||||
message: 'PRD saved. Let the user know their product requirements document is ready and the platform will now architect the technical solution.'
|
||||
};
|
||||
}
|
||||
});
|
||||
Reference in New Issue
Block a user