-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathllms-full.txt
More file actions
203 lines (180 loc) · 5.13 KB
/
llms-full.txt
File metadata and controls
203 lines (180 loc) · 5.13 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
# Execution Protocol — Full LLM Context
Version: 1.0.0
Endpoint: https://achillesalpha.onrender.com/ep
Built by: Achilles / Project Olympus
Hackathon: Synthesis x Bankr 2026
## What is EP?
Execution Protocol is a pre-execution validation layer for autonomous AI agents.
Before any agent takes any action with real-world consequences, it calls EP.
EP checks the proposal against a registered policy set and returns a
cryptographic proof_hash if valid. This proof_hash is the agent's authorization
to proceed. Without it, the action must not execute.
## Why EP exists
AI agents are black boxes. They say they validated. They say they checked policy.
There is no enforcement layer. EP provides cryptographic proof that an action
was validated before execution, and confirmed after. On-chain. Immutable.
## Architecture
```
Agent → POST /ep/validate → PolicyEngine → proof_hash
Agent executes action with proof_hash
Agent → POST /ep/confirm → On-chain confirmation
Anyone → GET /ep/proof/:hash → Public verification
```
## Authentication
All mutation endpoints require `X-Agent-Key` header.
Read-only endpoints (GET /ep/proof/:hash, GET /ep/status) require no auth.
## Endpoints
### POST /ep/validate
Validate a proposed action against a policy set.
Request:
```json
{
"proposal_id": "unique-uuid",
"agent_id": "achilles-main",
"asset": "BNKR",
"direction": "buy",
"amount_usd": 25,
"entry_price": 0.0005,
"stop_loss": 0.00045,
"take_profit": 0.00065,
"leverage": 1,
"policy_set_id": "olympus-v1",
"chain": "base"
}
```
Response:
```json
{
"valid": true,
"risk_score": 0.35,
"violations": [],
"proof_hash": "0xabc123...",
"plan_summary": "Buy 25 USD of BNKR on Base at 0.0005 with 1x leverage",
"timestamp": "2026-03-16T12:00:00Z"
}
```
Fields:
- valid: boolean — whether the action passes all policy checks
- risk_score: 0.0-1.0 — composite risk assessment
- violations: string[] — list of policy violations (empty if valid)
- proof_hash: keccak256 hash of the validation — your authorization to proceed
- plan_summary: human-readable description of what was validated
- timestamp: ISO 8601 timestamp
### POST /ep/swarm/validate
Validate an action in a multi-agent swarm context.
Same request body as /ep/validate, plus:
```json
{
"swarm_id": "olympus-swarm-1",
"swarm_role": "executor",
"swarm_context": {
"total_agents": 12,
"total_exposure_usd": 500,
"max_single_agent_pct": 25
}
}
```
Enforces:
- Per-agent exposure limits within swarm
- Aggregate swarm exposure caps
- Role-based action authorization
### GET /ep/proof/:hash
Public proof lookup. No auth required.
Response:
```json
{
"proof_hash": "0xabc123...",
"agent_id": "achilles-main",
"action": "buy BNKR",
"valid": true,
"risk_score": 0.35,
"timestamp": "2026-03-16T12:00:00Z",
"on_chain": {
"network": "base-sepolia",
"contract": "0xf1e16d3e5B74582fC326Bc6E2B82839d31f1ccE8",
"tx": null
}
}
```
### GET /ep/status
Service health check. No auth required.
Response:
```json
{
"status": "operational",
"version": "1.0.0",
"uptime": 86400,
"network": "base-sepolia",
"contracts": {
"attestRegistry": "0xC36E784E1dff616bDae4EAc7B310F0934FaF04a4",
"feeCollector": "0xFF196F1e3a895404d073b8611252cF97388773A7",
"epCommitment": "0xf1e16d3e5B74582fC326Bc6E2B82839d31f1ccE8"
},
"stats": {
"totalValidations": 0,
"totalExecutions": 0,
"totalProofs": 0
}
}
```
## On-Chain Contracts (Base Sepolia)
| Contract | Address |
|----------|---------|
| ATTEST Registry | 0xC36E784E1dff616bDae4EAc7B310F0934FaF04a4 |
| Fee Collector | 0xFF196F1e3a895404d073b8611252cF97388773A7 |
| EPCommitment | 0xf1e16d3e5B74582fC326Bc6E2B82839d31f1ccE8 |
## Policy Sets
Policy sets define what an agent is allowed to do.
### olympus-v1 (default)
- max_single_trade_usd: 100
- max_daily_volume_usd: 500
- max_leverage: 3
- allowed_assets: [BNKR, ETH, USDC, USDT]
- allowed_chains: [base, base-sepolia]
- require_stop_loss: true
- max_risk_score: 0.7
## Error Codes
- 400: Invalid request body
- 401: Missing or invalid X-Agent-Key
- 403: Policy violation (action rejected)
- 404: Proof hash not found
- 429: Rate limited
- 500: Internal error
## Rate Limits
- Validate: 60 requests/minute per agent
- Proof lookup: 120 requests/minute
- Status: 30 requests/minute
## Integration Example
```javascript
const response = await fetch('https://achillesalpha.onrender.com/ep/validate', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
'X-Agent-Key': 'your-key'
},
body: JSON.stringify({
proposal_id: crypto.randomUUID(),
agent_id: 'my-agent',
asset: 'BNKR',
direction: 'buy',
amount_usd: 25,
entry_price: 0.0005,
stop_loss: 0.00045,
take_profit: 0.00065,
leverage: 1,
policy_set_id: 'olympus-v1',
chain: 'base'
})
});
const result = await response.json();
if (result.valid) {
// Proceed with action, attach proof_hash to ledger
console.log('Authorized:', result.proof_hash);
} else {
console.log('Rejected:', result.violations);
}
```
## Source
GitHub: https://github.com/achilliesbot/execution-protocol
Live: https://achillesalpha.onrender.com/ep
Twitter: @AchillesAlphaAI