@robosystems/mcp 0.2.8 → 0.2.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +15 -112
- package/index.js +8 -2
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
[](https://www.npmjs.com/package/@robosystems/mcp)
|
|
4
4
|
[](https://opensource.org/licenses/MIT)
|
|
5
5
|
|
|
6
|
-
Official MCP (Model Context Protocol) client adapter for connecting AI agents to RoboSystems Financial Knowledge Graph API. Access comprehensive financial data including accounting transactions, financial reports, and advanced graph analytics through the Model Context Protocol.
|
|
6
|
+
Official MCP (Model Context Protocol) client adapter for connecting AI agents to the RoboSystems Financial Knowledge Graph API. Access comprehensive financial data including accounting transactions, financial reports, and advanced graph analytics through the Model Context Protocol.
|
|
7
7
|
|
|
8
8
|
## Features
|
|
9
9
|
|
|
@@ -14,21 +14,9 @@ Official MCP (Model Context Protocol) client adapter for connecting AI agents to
|
|
|
14
14
|
- **Automatic retry logic** with exponential backoff
|
|
15
15
|
- **Real-time progress tracking** for long-running operations
|
|
16
16
|
|
|
17
|
-
## Installation
|
|
18
|
-
|
|
19
|
-
```bash
|
|
20
|
-
npm install @robosystems/mcp
|
|
21
|
-
```
|
|
22
|
-
|
|
23
|
-
Or run directly with npx:
|
|
24
|
-
|
|
25
|
-
```bash
|
|
26
|
-
npx @robosystems/mcp
|
|
27
|
-
```
|
|
28
|
-
|
|
29
17
|
## Quick Start
|
|
30
18
|
|
|
31
|
-
Add to your
|
|
19
|
+
Add to your MCP servers configuration:
|
|
32
20
|
|
|
33
21
|
```json
|
|
34
22
|
{
|
|
@@ -38,8 +26,8 @@ Add to your Claude Desktop configuration:
|
|
|
38
26
|
"args": ["-y", "@robosystems/mcp"],
|
|
39
27
|
"env": {
|
|
40
28
|
"ROBOSYSTEMS_API_URL": "https://api.robosystems.ai",
|
|
41
|
-
"ROBOSYSTEMS_API_KEY": "
|
|
42
|
-
"ROBOSYSTEMS_GRAPH_ID": "
|
|
29
|
+
"ROBOSYSTEMS_API_KEY": "rfs...",
|
|
30
|
+
"ROBOSYSTEMS_GRAPH_ID": "kg..."
|
|
43
31
|
}
|
|
44
32
|
}
|
|
45
33
|
}
|
|
@@ -48,108 +36,23 @@ Add to your Claude Desktop configuration:
|
|
|
48
36
|
|
|
49
37
|
## Environment Variables
|
|
50
38
|
|
|
51
|
-
| Variable | Description |
|
|
39
|
+
| Variable | Description | Example |
|
|
52
40
|
|----------|-------------|---------|
|
|
53
|
-
| `ROBOSYSTEMS_API_URL` | The RoboSystems API endpoint | `
|
|
54
|
-
| `ROBOSYSTEMS_API_KEY` | Your API key |
|
|
55
|
-
| `ROBOSYSTEMS_GRAPH_ID` | The graph database ID to connect to | `
|
|
56
|
-
|
|
57
|
-
## Configuration Details
|
|
58
|
-
|
|
59
|
-
### Connection Pooling
|
|
60
|
-
- **Maximum Connections**: 5 concurrent SSE connections (hardcoded)
|
|
61
|
-
- **Connection TTL**: 30 seconds before automatic cleanup
|
|
62
|
-
- Connections are reused across requests for better performance
|
|
63
|
-
|
|
64
|
-
### Smart Caching
|
|
65
|
-
Cache TTL values per tool type:
|
|
66
|
-
- **`get-graph-schema`**: 1 hour (3600 seconds)
|
|
67
|
-
- **`get-graph-info`**: 5 minutes (300 seconds)
|
|
68
|
-
- **`describe-graph-structure`**: 30 minutes (1800 seconds)
|
|
69
|
-
- **Other tools**: 5 minutes (300 seconds) default
|
|
70
|
-
|
|
71
|
-
### Timeouts
|
|
72
|
-
- **SSE Timeout**: 5 minutes for streaming operations
|
|
73
|
-
- **Metrics Logging**: Every 5 minutes
|
|
74
|
-
|
|
75
|
-
## Available Tools
|
|
76
|
-
|
|
77
|
-
### Core Query Tools
|
|
78
|
-
- **`read-graph-cypher`**: Execute read-only Cypher queries on the graph database
|
|
79
|
-
- Supports streaming for large result sets
|
|
80
|
-
- Automatic result aggregation
|
|
81
|
-
- Progress tracking for complex queries
|
|
82
|
-
|
|
83
|
-
### Schema & Information Tools
|
|
84
|
-
- **`get-graph-schema`**: Retrieve the complete database schema
|
|
85
|
-
- Returns node types and relationship definitions
|
|
86
|
-
|
|
87
|
-
- **`get-graph-info`**: Get basic information about the graph
|
|
88
|
-
- Includes node counts, relationship counts, and metadata
|
|
89
|
-
|
|
90
|
-
- **`describe-graph-structure`**: Get natural language description of the graph
|
|
91
|
-
- AI-friendly format for better understanding
|
|
92
|
-
|
|
93
|
-
## Technical Details
|
|
94
|
-
|
|
95
|
-
### Response Formats
|
|
96
|
-
The MCP server automatically handles multiple response formats:
|
|
97
|
-
- **JSON**: Standard synchronous responses
|
|
98
|
-
- **SSE (Server-Sent Events)**: Real-time streaming for long operations
|
|
99
|
-
- **NDJSON**: Newline-delimited JSON for batch processing
|
|
100
|
-
- **Queued**: Queued operations with status polling
|
|
101
|
-
|
|
102
|
-
## Integration Examples
|
|
103
|
-
|
|
104
|
-
### Claude Desktop
|
|
105
|
-
```json
|
|
106
|
-
{
|
|
107
|
-
"mcpServers": {
|
|
108
|
-
"robosystems": {
|
|
109
|
-
"command": "npx",
|
|
110
|
-
"args": ["-y", "@robosystems/mcp"],
|
|
111
|
-
"env": {
|
|
112
|
-
"ROBOSYSTEMS_API_URL": "https://api.robosystems.ai",
|
|
113
|
-
"ROBOSYSTEMS_API_KEY": "your-api-key-here",
|
|
114
|
-
"ROBOSYSTEMS_GRAPH_ID": "your-graph-id"
|
|
115
|
-
}
|
|
116
|
-
}
|
|
117
|
-
}
|
|
118
|
-
}
|
|
119
|
-
```
|
|
120
|
-
|
|
121
|
-
### Local Development
|
|
122
|
-
```json
|
|
123
|
-
{
|
|
124
|
-
"mcpServers": {
|
|
125
|
-
"robosystems-local": {
|
|
126
|
-
"command": "npx",
|
|
127
|
-
"args": ["-y", "@robosystems/mcp"],
|
|
128
|
-
"env": {
|
|
129
|
-
"ROBOSYSTEMS_API_URL": "http://localhost:8000",
|
|
130
|
-
"ROBOSYSTEMS_API_KEY": "your-api-dev-key-here",
|
|
131
|
-
"ROBOSYSTEMS_GRAPH_ID": "your-dev-graph-id"
|
|
132
|
-
}
|
|
133
|
-
}
|
|
134
|
-
}
|
|
135
|
-
}
|
|
136
|
-
```
|
|
137
|
-
|
|
138
|
-
## Usage Examples
|
|
41
|
+
| `ROBOSYSTEMS_API_URL` | The RoboSystems API endpoint | `https://api.robosystems.ai` |
|
|
42
|
+
| `ROBOSYSTEMS_API_KEY` | Your API key | `rfs...` |
|
|
43
|
+
| `ROBOSYSTEMS_GRAPH_ID` | The graph database ID to connect to | `kg...` or `sec` |
|
|
139
44
|
|
|
140
|
-
|
|
45
|
+
## API Reference
|
|
141
46
|
|
|
142
|
-
-
|
|
143
|
-
-
|
|
144
|
-
- **Explore relationships**: "How are companies connected to their financial reports?"
|
|
145
|
-
- **Run complex analyses**: "Find companies with revenue growth over 20% in the last year"
|
|
47
|
+
- [RoboSystems](https://robosystems.ai)
|
|
48
|
+
- [MCP API documentation](https://api.robosystems.ai/docs#tag/MCP)
|
|
146
49
|
|
|
147
50
|
## Support
|
|
148
51
|
|
|
149
|
-
-
|
|
150
|
-
-
|
|
151
|
-
-
|
|
152
|
-
-
|
|
52
|
+
- [Issues](https://github.com/RoboFinSystems/robosystems-mcp-client/issues)
|
|
53
|
+
- [Discussions](https://github.com/RoboFinSystems/robosystems/discussions)
|
|
54
|
+
- [Projects](https://github.com/RoboFinSystems/robosystems/projects)
|
|
55
|
+
- [Wiki](https://github.com/RoboFinSystems/robosystems/wiki)
|
|
153
56
|
|
|
154
57
|
## License
|
|
155
58
|
|
package/index.js
CHANGED
|
@@ -624,9 +624,9 @@ class RoboSystemsMCPClient {
|
|
|
624
624
|
}
|
|
625
625
|
|
|
626
626
|
async function main() {
|
|
627
|
-
const baseUrl = process.env.ROBOSYSTEMS_API_URL || '
|
|
627
|
+
const baseUrl = process.env.ROBOSYSTEMS_API_URL || 'https://api.robosystems.ai'
|
|
628
628
|
const apiKey = process.env.ROBOSYSTEMS_API_KEY
|
|
629
|
-
const graphId = process.env.ROBOSYSTEMS_GRAPH_ID
|
|
629
|
+
const graphId = process.env.ROBOSYSTEMS_GRAPH_ID
|
|
630
630
|
|
|
631
631
|
if (!apiKey) {
|
|
632
632
|
console.error('ROBOSYSTEMS_API_KEY environment variable is required')
|
|
@@ -634,6 +634,12 @@ async function main() {
|
|
|
634
634
|
process.exit(1)
|
|
635
635
|
}
|
|
636
636
|
|
|
637
|
+
if (!graphId) {
|
|
638
|
+
console.error('ROBOSYSTEMS_GRAPH_ID environment variable is required')
|
|
639
|
+
console.error('Please set ROBOSYSTEMS_GRAPH_ID in your MCP configuration')
|
|
640
|
+
process.exit(1)
|
|
641
|
+
}
|
|
642
|
+
|
|
637
643
|
console.error(`RoboSystems MCP Client v${PACKAGE_VERSION}`)
|
|
638
644
|
console.error(`Connecting to ${baseUrl} for graph ${graphId}`)
|
|
639
645
|
console.error(`API Key: ${apiKey.substring(0, 10)}...`)
|