-
Notifications
You must be signed in to change notification settings - Fork 1
Getting Started
Rajamohan J edited this page Mar 5, 2026
·
1 revision
Get ATP running in under 30 seconds.
| Tool | Version | Install |
|---|---|---|
| Rust | 1.75+ | curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh |
| Protobuf | 3.x+ |
brew install protobuf or apt install protobuf-compiler
|
Add to your Cargo.toml:
[dependencies]
atp-sdk = { git = "https://github.com/rajamohan1950/AgentTransportProtocol" }git clone https://github.com/rajamohan1950/AgentTransportProtocol.git
cd AgentTransportProtocol
export PROTOC=$(which protoc)
cargo build --workspace
cargo test --workspace # 280 tests, all passingCreate a new Rust project:
cargo new my-agent-app
cd my-agent-appAdd the dependency:
# Cargo.toml
[dependencies]
atp-sdk = { git = "https://github.com/rajamohan1950/AgentTransportProtocol" }Write your program:
// src/main.rs
fn main() {
// Run the full benchmark — 50 agents, 10K tasks, 7 scenarios
atp_sdk::benchmark();
// Find the best route for a coding task
atp_sdk::route("coding");
// Compress context data
atp_sdk::compress(b"your context data here...", "analysis");
// Create a cryptographic identity and sign a message
atp_sdk::sign(b"hello world");
// Check network trust for a skill
atp_sdk::trust("coding");
}Run it:
cargo runThat's it. No config files. No setup. No structs to create. Just call the function.
For production code, use the "noun" functions that return typed results:
fn main() {
// Get structured benchmark data
let report = atp_sdk::bench(10_000);
println!("ATP cost: ${:.4}", report.atp().unwrap().avg_cost_per_task);
// Get route details
let route = atp_sdk::find_route("coding");
if route.quality > 0.9 {
println!("High quality route found: {}", route.pattern);
}
// Get compression metrics
let comp = atp_sdk::shrink(b"data...", "analysis");
println!("Compressed {}x", comp.ratio);
// Create an identity
let agent = atp_sdk::agent();
let sig = agent.sign(b"message");
assert!(agent.verify(b"message", &sig));
println!("Agent DID: {}", agent.did());
}# Default: 50 agents, 10K tasks
cargo run --release -p atp-bench
# Custom parameters
cargo run --release -p atp-bench -- --agents 100 --tasks 50000 --seed 123
# JSON output (for pipelines)
cargo run --release -p atp-bench -- --output json
# CSV output (for spreadsheets)
cargo run --release -p atp-bench -- --output csv
# Single scenario
cargo run --release -p atp-bench -- --scenario atp- Architecture Overview — Understand the five layers
- SDK API Reference — Complete function reference
- Benchmarks — Detailed performance analysis
- Python SDK — Use ATP from Python
ATP Wiki
Getting Started
Architecture
- Architecture Overview
- Layer 1: Identity and Trust
- Layer 2: Capability Handshake
- Layer 3: Context Compression
- Layer 4: Economic Routing
- Layer 5: Fault Tolerance
Reference
More