This document provides information for developers who want to contribute to mcpGraph or work with the source code.
- Clone the repository:
git clone https://github.com/TeamSparkAI/mcpGraph.git
cd mcpGraph- Install dependencies:
npm install- Build the project:
npm run build- Run the project:
npm startOr run in development mode (with hot reload):
npm run devnpm testThe tests use the filesystem MCP server for integration testing. The filesystem MCP server is installable via npm and can be run with npx.
The test directory is located at tests/files/ and contains various test files used by the file_utils example.
The filesystem MCP server configuration used in tests is hardcoded in the test files to use:
- Command:
npx - Args:
["-y", "@modelcontextprotocol/server-filesystem", "/path/to/tests/files"]
For more information about the filesystem MCP server, see the official repository.
- Source code is in
src/ - Build output goes to
dist/ - TypeScript configuration is in
tsconfig.json - Example configurations are in
examples/ - Tests are in
tests/
src/main.ts- Main MCP server entry pointsrc/config/- Configuration loading and validationsrc/execution/- Graph execution enginesrc/graph/- Graph validation and node registrysrc/mcp/- MCP client managementsrc/expressions/- JSONata and JSON Logic expression evaluation
The project uses TypeScript and compiles to JavaScript in the dist/ directory:
npm run buildWatch mode for development:
npm run watchTests are located in the tests/ directory and use Node.js's built-in test runner:
npm test- Design Document - Complete design and architecture
- Implementation - Implementation details and architecture