A Model Context Protocol (MCP) server that provides an AI agent interface for querying and interacting with the Succinct Network whitepaper. This server allows users to search through the whitepaper content, retrieve specific sections, and get explanations of key concepts through HTTP API endpoints.
- Search Functionality: Search for specific terms or concepts within the whitepaper
- Section Navigation: Retrieve complete sections or subsections by name
- Key Concept Explanations: Get detailed explanations of important Succinct Network concepts
- Pre-defined Prompts: Access common queries about the whitepaper
- HTTP API: RESTful endpoints for easy integration with any HTTP client
- TypeScript: Full TypeScript support with proper type definitions
- Installation
- Quick Start
- API Documentation
- Usage Examples
- Project Structure
- Development
- Testing
- Contributing
- Node.js (version 16 or higher)
- npm or yarn
- TypeScript (installed globally or as dev dependency)
git clone https://github.com/dev3Nigerian/succint-whitepaper-mcp.git
cd succinct-mcp-servernpm installnpm run buildnpm startThe server will start on http://localhost:3000 by default.
-
Install and start the server (see Installation above)
-
Test the health endpoint:
curl http://localhost:3000/health
-
Search the whitepaper:
curl -X POST http://localhost:3000/tools/call \ -H "Content-Type: application/json" \ -d '{"name":"search_whitepaper","arguments":{"query":"proof contests"}}'
-
List all available sections:
curl -X POST http://localhost:3000/tools/call \ -H "Content-Type: application/json" \ -d '{"name":"list_sections","arguments":{}}'
http://localhost:3000
GET /health
Returns server status.
Response:
{
"status": "ok",
"message": "Succinct Network MCP Server is running"
}POST /tools/list
Returns all available tools for interacting with the whitepaper.
Response:
{
"tools": [
{
"name": "search_whitepaper",
"description": "Search for information in the Succinct Network whitepaper",
"inputSchema": {
"type": "object",
"properties": {
"query": {
"type": "string",
"description": "Search query to find relevant information"
}
},
"required": ["query"]
}
}
// ... other tools
]
}POST /tools/call
Execute a specific tool with provided arguments.
Request Body:
{
"name": "search_whitepaper",
"arguments": {
"query": "proof contests"
}
}Response:
{
"content": [
{
"type": "text",
"text": "Found 2 result(s) for \"proof contests\":\n\n**Proof Contests**\nProof contests are the core mechanism..."
}
]
}Request Body:
{
"name": "get_section",
"arguments": {
"section": "Abstract"
}
}Request Body:
{
"name": "list_sections",
"arguments": {}
}Request Body:
{
"name": "get_key_concepts",
"arguments": {
"concept": "zkvm"
}
}POST /prompts/list
Returns predefined prompts for common whitepaper queries.
POST /prompts/get
Request Body:
{
"name": "whitepaper_summary"
}Available prompts:
whitepaper_summaryproof_contests_explainednetwork_architectureapplications
-
Search for "SP1":
curl -X POST http://localhost:3000/tools/call \ -H "Content-Type: application/json" \ -d '{"name":"search_whitepaper","arguments":{"query":"SP1"}}'
-
Get the Introduction section:
curl -X POST http://localhost:3000/tools/call \ -H "Content-Type: application/json" \ -d '{"name":"get_section","arguments":{"section":"Introduction"}}'
-
Explain proving pools:
curl -X POST http://localhost:3000/tools/call \ -H "Content-Type: application/json" \ -d '{"name":"get_key_concepts","arguments":{"concept":"proving pools"}}'
-
Import the Collection: Create a new Postman collection with the base URL
http://localhost:3000 -
Set up requests: Create POST requests for each endpoint with appropriate JSON bodies
-
Test: Use the examples above as request bodies
const axios = require("axios");
async function searchWhitepaper(query) {
try {
const response = await axios.post("http://localhost:3000/tools/call", {
name: "search_whitepaper",
arguments: { query },
});
console.log(response.data.content[0].text);
} catch (error) {
console.error("Error:", error.response?.data || error.message);
}
}
// Usage
searchWhitepaper("zero-knowledge proofs");import requests
import json
def search_whitepaper(query):
url = "http://localhost:3000/tools/call"
payload = {
"name": "search_whitepaper",
"arguments": {"query": query}
}
try:
response = requests.post(url, json=payload)
response.raise_for_status()
result = response.json()
print(result['content'][0]['text'])
except requests.exceptions.RequestException as e:
print(f"Error: {e}")
# Usage
search_whitepaper("proof contests")succinct-mcp-server/
βββ src/
β βββ data/
β β βββ whitepaper.ts # Whitepaper content structure
β β βββ keyConcepts.ts # Key concept definitions
β βββ utils/
β β βββ search.ts # Search utility functions
β βββ transport.ts # HTTP transport layer
β βββ index.ts # Main server implementation
βββ dist/ # Compiled JavaScript files
βββ package.json
βββ tsconfig.json
βββ README.md
src/index.ts: Main server setup with MCP handlers and tool implementationssrc/transport.ts: HTTP server using Express.js for handling REST API requestssrc/data/whitepaper.ts: Structured content from the Succinct Network whitepapersrc/data/keyConcepts.ts: Definitions and explanations of key conceptssrc/utils/search.ts: Search algorithm and relevance scoring functions
# Build the project
npm run build
# Start the server
npm start
# Development mode (build and run)
npm run dev
# Watch for changes (TypeScript compilation)
npm run watchYou can customize the server port by modifying the HttpTransport constructor in src/index.ts:
const transport = new HttpTransport(3000); // Change port hereTo add new sections or update whitepaper content:
- Edit
src/data/whitepaper.tsto add new sections - Update
src/data/keyConcepts.tsto add new concept explanations - Rebuild the project:
npm run build - Restart the server:
npm start
The search functionality can be enhanced by modifying src/utils/search.ts:
- Adjust relevance scoring weights
- Add stemming or fuzzy matching
- Implement semantic search
Use the provided cURL examples or Postman to test all endpoints.
You can create a simple test script:
// test/basic-test.js
const axios = require("axios");
async function runTests() {
const baseUrl = "http://localhost:3000";
try {
// Test health endpoint
const health = await axios.get(`${baseUrl}/health`);
console.log("β
Health check passed");
// Test search
const search = await axios.post(`${baseUrl}/tools/call`, {
name: "search_whitepaper",
arguments: { query: "SP1" },
});
console.log("β
Search test passed");
// Test section retrieval
const section = await axios.post(`${baseUrl}/tools/call`, {
name: "get_section",
arguments: { section: "Abstract" },
});
console.log("β
Section retrieval test passed");
console.log("π All tests passed!");
} catch (error) {
console.error("β Test failed:", error.message);
}
}
runTests();The server runs locally on port 3000 by default. Ensure the port is available and not blocked by firewall.
Create a Dockerfile:
FROM node:18-alpine
WORKDIR /app
COPY package*.json ./
RUN npm ci --only=production
COPY dist ./dist
EXPOSE 3000
CMD ["node", "dist/index.js"]Build and run:
docker build -t succinct-mcp-server .
docker run -p 3000:3000 succinct-mcp-serverThis server can be deployed to:
- Heroku: Add a
Procfilewithweb: node dist/index.js - Railway: Connect your GitHub repository
- DigitalOcean App Platform: Use the Node.js buildpack
- AWS/GCP/Azure: Deploy as a container or serverless function
This MCP server provides easy access to information about the Succinct Network, a decentralized protocol for zero-knowledge proof generation. Key topics covered include:
- Proof Contests: Novel auction mechanism for prover coordination
- SP1 zkVM: Zero-knowledge virtual machine for RISC-V programs
- Network Architecture: Application-specific blockchain design
- Market Structure: Economic incentives and prover decentralization
- Applications: Use cases from rollups to privacy applications
- Fork the repository
- Create a feature branch:
git checkout -b feature/amazing-feature - Commit your changes:
git commit -m 'Add amazing feature' - Push to the branch:
git push origin feature/amazing-feature - Open a Pull Request
- Follow TypeScript best practices
- Add appropriate error handling
- Update documentation for new features
- Test your changes thoroughly
This project is licensed under the MIT License - see the LICENSE file for details.
If you encounter any issues or have questions:
- Check the Issues page
- Create a new issue with detailed description
- Include error messages and steps to reproduce
Built with β€οΈ for the Succinct Network community