Skip to content

Commit 296d324

Browse files
committed
feat(mcp): add PlanAdapter and StatusAdapter with full test coverage
- Add StatusAdapter with 5 sections (summary/repo/indexes/github/health) - Add PlanAdapter with lazy initialization and GitHub issue breakdown - Add comprehensive unit tests for both adapters (>80% coverage) - Register both adapters in MCP server bin entry point - Fix fetchGitHubIssue to accept repositoryPath parameter - Update MCP server to handle date serialization and content formatting - Verified working in Cursor with dev_plan and dev_status tools
1 parent 3975303 commit 296d324

File tree

8 files changed

+2071
-5
lines changed

8 files changed

+2071
-5
lines changed

packages/mcp-server/bin/dev-agent-mcp.ts

Lines changed: 16 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
*/
66

77
import { RepositoryIndexer } from '@lytics/dev-agent-core';
8-
import { SearchAdapter } from '../src/adapters/built-in/search-adapter';
8+
import { PlanAdapter, SearchAdapter, StatusAdapter } from '../src/adapters/built-in';
99
import { MCPServer } from '../src/server/mcp-server';
1010

1111
// Get config from environment
@@ -31,6 +31,20 @@ async function main() {
3131
defaultLimit: 10,
3232
});
3333

34+
const statusAdapter = new StatusAdapter({
35+
repositoryIndexer: indexer,
36+
repositoryPath,
37+
vectorStorePath,
38+
defaultSection: 'summary',
39+
});
40+
41+
const planAdapter = new PlanAdapter({
42+
repositoryIndexer: indexer,
43+
repositoryPath,
44+
defaultFormat: 'compact',
45+
timeout: 60000, // 60 seconds
46+
});
47+
3448
// Create MCP server
3549
const server = new MCPServer({
3650
serverInfo: {
@@ -42,7 +56,7 @@ async function main() {
4256
logLevel,
4357
},
4458
transport: 'stdio',
45-
adapters: [searchAdapter],
59+
adapters: [searchAdapter, statusAdapter, planAdapter],
4660
});
4761

4862
// Handle graceful shutdown

0 commit comments

Comments
 (0)