Skip to content

Commit 3ab12fd

Browse files
authored
Merge pull request #8 from Moonsong-Labs/notlesh/release-analysis-continuation
Release analysis continuation
2 parents b676266 + cd352a1 commit 3ab12fd

File tree

10 files changed

+1550
-140
lines changed

10 files changed

+1550
-140
lines changed

CLAUDE.md

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,9 @@ substrate-mcp/
1515
├── CLAUDE.md # This file - development guidance
1616
└── src/
1717
├── main.rs # Entry point with tokio async runtime
18-
└── server.rs # MCP server implementation with tool routing
18+
├── server.rs # MCP server implementation with tool routing
19+
└── substrate/ # Substrate client implementation
20+
└── client.rs # RPC client for interacting with nodes
1921
2022
## Development Commands
2123
@@ -63,9 +65,11 @@ This server follows the standard MCP communication pattern:
6365
### Current State
6466
The server currently has:
6567
- Basic MCP server infrastructure set up
66-
- One placeholder tool: `say_hello` that returns "Hello, World! From substrate MCP"
67-
- Server info indicating it's for "Tools and Prompts to work with Substrate based blockchains"
68-
- Only tools capability enabled (prompts and resources disabled)
68+
- Several functional tools:
69+
- `fetch_and_analyze_release`: Fetches and analyzes Polkadot SDK releases (downloads PRDocs and generates summaries)
70+
- `chain_storage_bisect`: Finds storage changes between blocks
71+
- Server info indicating it's for Substrate-based blockchain development
72+
- Both tools and resources capabilities enabled
6973
- Server name: "substrate-mcp" (version 0.1.0)
7074

7175
### Adding New Tools
@@ -96,6 +100,7 @@ The project can be installed via:
96100
- Local build: `cargo build --release`
97101

98102
For Claude Code configuration, see README.md for detailed setup instructions.
103+
99104
## Substrate Integration Guidelines
100105

101106
### Preferred Crates

Cargo.lock

Lines changed: 71 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,12 @@ indoc = "2.0.6"
99
tokio = { version = "1", features = ["full"] }
1010
serde = { version = "1", features = ["derive"] }
1111
serde_json = "1"
12+
serde_yaml = "0.9"
13+
toml = "0.8"
1214
anyhow = "1"
1315
reqwest = { version = "0.12", features = ["json"] }
16+
chrono = { version = "0.4", features = ["serde"] }
17+
dirs = "5.0"
1418

1519
# For RPC client functionality
1620
jsonrpsee = { version = "0.20", features = ["http-client", "ws-client", "macros"] }

README.md

Lines changed: 1 addition & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -23,42 +23,6 @@ For the `subxt_execute` tool, install the subxt CLI:
2323
cargo install subxt-cli
2424
```
2525

26-
## Configuration
27-
28-
### RPC Endpoints
29-
The server uses a `rpc_endpoints.json` configuration file to manage RPC endpoints. This file is automatically created with default endpoints if it doesn't exist.
30-
31-
The configuration includes:
32-
- **Network name**: Human and LLM-friendly identifier (e.g., "polkadot", "kusama")
33-
- **URL**: WebSocket endpoint URL
34-
- **Description**: Detailed description of the network
35-
36-
Example configuration:
37-
```json
38-
{
39-
"endpoints": [
40-
{
41-
"name": "polkadot",
42-
"url": "wss://rpc.polkadot.io",
43-
"description": "Polkadot mainnet - The main Polkadot relay chain"
44-
},
45-
{
46-
"name": "westend",
47-
"url": "wss://westend-rpc.polkadot.io",
48-
"description": "Westend testnet - Public test network for Polkadot"
49-
},
50-
{
51-
"name": "local",
52-
"url": "ws://localhost:9944",
53-
"description": "Local development node - Substrate node running on your machine"
54-
}
55-
],
56-
"default_endpoint": "westend"
57-
}
58-
```
59-
60-
You can customize this file to add your own endpoints or modify existing ones.
61-
6226
## Available Tools
6327

6428
### Event Querying
@@ -75,7 +39,7 @@ You can customize this file to add your own endpoints or modify existing ones.
7539
- **`subxt_execute`** - Use subxt CLI to decode and explore Substrate blockchain data. Useful for analyzing chain metadata, generating type-safe Rust code, and understanding runtime APIs.
7640

7741
### Documentation
78-
- **`get_polkadot_sdk_release_prdocs`** - Get all documented changes for a given polkadot-sdk release.
42+
- **`fetch_and_analyze_release`** - Fetches and analyzes a Polkadot SDK release by downloading all PRDoc files and generating analysis summaries (manifest, crate changes, audience breakdown). Files are saved to `~/.substrate-mcp/{project}/releases/{release}/pr-docs/` and the tool returns the path for further exploration.
7943

8044
## Usage with Claude Code
8145

src/lib.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
pub mod polkadot_sdk_releases;
22
pub mod prompts;
3-
pub mod public_endpoints;
43
pub mod resources;
54
pub mod server;
65
pub mod substrate;

src/main.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ use tokio::io::{stdin, stdout};
44

55
mod polkadot_sdk_releases;
66
mod prompts;
7-
mod public_endpoints;
87
mod resources;
98
mod server;
109
mod substrate;

0 commit comments

Comments
 (0)