About the project
AegisAgent
Paranoid pre-sign security gate for Tether WDK agent wallets — natural language in, audited calldata out. WDK signs only after approval.
Tracks: WDK · General
---
What we built
AegisAgent is a dual-agent validation pipeline that sits between an AI planner and a WDK wallet:
- Planner (Execution Agent) — Gemini Flash turns user intent into a structured transaction proposal (contract, function, args, calldata).
- RAG (ChromaDB) — Retrieves verified ERC-20 / Uniswap / Aave ABIs and security invariants.
- Paranoid Gatekeeper — Gemini Pro adversarially audits every field; assumes the planner is wrong or under attack.
- WDK layer — Only if APPROVED, exports a
wdk_sign_requestfor@tetherto/wdkand enforces it viaregisterPolicy. - Executor — Simulates approved transactions (optional testnet broadcast).
Core idea: The planner is not trusted. WDK only sees calldata the gatekeeper explicitly approved.
---
Why it matters
WDK lets AI agents hold self-custodial wallets and move money on-chain. That creates real risk:
- Hallucinated function names that don't exist on real ABIs
- Unlimited token approvals to attacker addresses
- Prompt-injection hidden in user intent
AegisAgent answers: who validates the agent before the wallet signs?
---
How it works
1. Plan (Execution Agent)
- Input: natural-language intent (e.g. "Transfer 1 USDC to 0x…")
- Output: structured TransactionProposal — target contract, function, args, hex calldata, gas, value
- The planner is fast but not trusted
2. Retrieve (RAG)
- ChromaDB stores ABI fragments and security invariants
- Examples: no zero-address transfers, reject invented method names, flag unlimited approvals
- Retrieved facts are injected into the auditor prompt
3. Audit (Paranoid Gatekeeper)
- Cross-checks proposal vs RAG facts
- Returns APPROVED or REJECTED with vulnerabilities, confidence, and grounded facts
- Design principle: prefer REJECTED when uncertain
4. WDK sign layer (only if APPROVED)
Three integration layers:
A — API payload
POST /pipeline/executereturnswdk_sign_request:to,data,value,chain_id,approval_token- Shown in the UI under Dispatch → WDK sign request
B — Node bridge
integrations/wdk/sign-approved.mjsruns the full Aegis pipeline, then calls@tetherto/wdk+@tetherto/wdk-wallet-evm
C — Policy hook
integrations/wdk/aegis-policy.mjsuses WDKregisterPolicy()to ALLOW only Aegis-approved calldata and DENY everything else
5. Execute (simulation)
- Web3.py simulates approved txs (
eth_call/ gas estimate) - Optional testnet broadcast if keys are configured
---
Live demo
UI: https://cd32ec25.aegis-agent-eu5.pages.dev API health: https://instant-disclaimers-requirement-followed.trycloudflare.com/health GitHub: https://github.com/anishreddy3/aegis-agent
Try these scenarios in the UI:
- Valid ERC-20 transfer → Gatekeeper APPROVED → WDK sign request shown in Dispatch
- Hallucinated method (
safeTransferWithPermitAndStake) → REJECTED → no WDK payload - Drain / injection (unlimited approve to attacker) → REJECTED → no WDK payload
Enable Fast audit in Advanced options if Pro audit is slow.
---
WDK terminal demo (optional)
cd integrations/wdk && npm install AEGIS_API_URL=https://instant-disclaimers-requirement-followed.trycloudflare.com npm run sign-approved
Expected: Gatekeeper APPROVED → simulate.sendTransaction → ALLOW
Tech stack
- Backend: FastAPI, Python
- Agents: Gemini Flash (planner) + Gemini Pro (gatekeeper)
- RAG: ChromaDB
- Chain: Web3.py simulation
- WDK:
@tetherto/wdk,@tetherto/wdk-wallet-evm,registerPolicy - Deploy: NeevCloud CPU VM + Cloudflare Quick Tunnel (API), Cloudflare Pages (UI)
Documentation
- README: https://github.com/anishreddy3/aegis-agent
- WDK integration guide: https://github.com/anishreddy3/aegis-agent/blob/main/integrations/wdk/README.md
Contract address
N/A — this is an agent validation + WDK signing gate, not an on-chain protocol contract.
Hacki