Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,28 @@ dist
*.zip
test_file.txt
.DS_Store

# Benchmark and evaluation artifacts
.mcpbr_state/
eval_results_*/
monitoring_logs/
*.log
.monitor_pid
.vm_ip
*_output.log
BENCHMARK_*.md
MCP_TOOL_CALL_ANALYSIS.md
BUG_FILED_SUMMARY.md
SUPERMODEL_MCP_INVESTIGATION.md
CURRENT_RUN_STATUS.md
current_status_report.txt
MORNING_BRIEFING.md
OVERNIGHT_SUMMARY.md
START_HERE.md
.claude_notes
mcpbr-*.yaml
*-benchmark*.sh
*-monitor*.sh
*-comparison*.sh
setup-*.sh
reconnect.sh
13 changes: 7 additions & 6 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
],
"dependencies": {
"@modelcontextprotocol/sdk": "^1.0.1",
"@supermodeltools/sdk": "^0.3.8",
"@supermodeltools/sdk": "^0.6.0",
"archiver": "^7.0.1",
"ignore": "^7.0.5",
"jq-web": "^0.6.2",
Expand Down
5 changes: 3 additions & 2 deletions src/server.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js';
import { StdioServerTransport } from '@modelcontextprotocol/sdk/server/stdio.js';
import { Configuration, DefaultApi } from '@supermodeltools/sdk';
import { Configuration, DefaultApi, SupermodelClient } from '@supermodeltools/sdk';
import createSupermodelGraphTool from './tools/create-supermodel-graph';
import { ClientContext } from './types';
import { CallToolRequestSchema, ListToolsRequestSchema } from '@modelcontextprotocol/sdk/types.js';
Expand Down Expand Up @@ -96,8 +96,9 @@ Example:
logger.debug('Default workdir:', this.defaultWorkdir);
}

const api = new DefaultApi(config);
this.client = {
graphs: new DefaultApi(config),
graphs: new SupermodelClient(api),
};

this.setupHandlers();
Expand Down
11 changes: 5 additions & 6 deletions src/tools/create-supermodel-graph.ts
Original file line number Diff line number Diff line change
Expand Up @@ -754,11 +754,6 @@ async function fetchFromApi(client: ClientContext, file: string, idempotencyKey:
// Log the request details
logRequest(apiUrl, 'POST', fileSize, idempotencyKey);

const requestParams = {
file: fileBlob as any,
idempotencyKey: idempotencyKey,
};

// Start progress logging
console.error('[Supermodel] Starting codebase analysis...');

Expand All @@ -772,7 +767,11 @@ async function fetchFromApi(client: ClientContext, file: string, idempotencyKey:
}, 15000);

try {
const response = await client.graphs.generateSupermodelGraph(requestParams);
// SupermodelClient handles polling automatically
const response = await client.graphs.generateSupermodelGraph(
fileBlob as any,
{ idempotencyKey }
);
const duration = Date.now() - startTime;

// Clear progress interval
Expand Down
4 changes: 2 additions & 2 deletions src/types.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { DefaultApi } from '@supermodeltools/sdk';
import { SupermodelClient } from '@supermodeltools/sdk';
import { Tool } from '@modelcontextprotocol/sdk/types.js';

export interface ClientContext {
graphs: DefaultApi;
graphs: SupermodelClient;
}

export type ContentBlock =
Expand Down