Autonomous · L1 native · Watching
Autonomous liquidation network on Somnia’s Agentic L1. Watcher, Scorer, Router and Executor - four agents, two execution surfaces, settled at sub-second validator consensus latency.
Pipeline
Three on-chain steps, sub-second consensus.
Every transition is an event on-chain. Scoring and routing run on Somnia’s native validator subcommittee, not on a private bot server.
- Step 01
Watcher flags an undercollateralized position
The off-chain Watcher reads LendingPool state, builds an llm-inference prompt that describes the position, and calls flagPosition. The Coordinator records the case, attaches the prompt as the request payload, and pays the Somnia validator subcommittee deposit.
function flagPosition( uint256 watcherAgentId, address user, address collateralAsset, address debtAsset, bytes calldata scorerPayload ) external nonReentrant returns (uint256 caseId); - Step 02
Somnia validators score risk via consensus
An elected 3-validator subcommittee runs llm-inference against the prompt. Validators agree on a single int256 score (clamped 0..10000) and the Coordinator's handleScorerResponse callback lands in the next second. Below-threshold scores cancel the case without penalty.
function handleScorerResponse( uint256 requestId, Response[] memory responses, ResponseStatus status, Request memory details ) external; // emits: Scored(caseId, score) - Step 03
Router routes, Executor settles, Splitter distributes
Any keeper advances the Scored case to Router with a debt-to-cover prompt. After consensus, the Executor calls execute() which runs LendingPool.liquidate, forwards the seized collateral to the Splitter, and credits +100 reputation to all four agents.
function advanceToRouter(uint256 caseId, bytes calldata routerPayload) external; function execute(uint256 caseId, uint256 executorAgentId) external; // Splitter: 60% agents (reputation-weighted) / 30% treasury / 10% bounty
Agents
Four agents, two surfaces.
Watcher and Executor live as TypeScript binaries with WSS subscriptions - sub-second event detection where latency wins liquidations. Scorer and Router run as Somnia native agents invoked through validator consensus - verifiable decisions where integrity wins trust.
- WatcherOff-chain WSS listener
- ScorerSomnia native llm-inference
- RouterSomnia native llm-inference
- ExecutorOff-chain transaction submitter
Contracts
Deployed on the Somnia testnet.
Every address below is a public on-chain contract. The Coordinator forwards agent payloads to the Somnia platform; the rest of the protocol runs as plain Solidity.
- AgentRegistry0xb2Cd…d62d
Permissionless agent registry
- Reputation0x81c6…aF56
Per-agent success / failure ledger
- Coordinator0x414B…Af80
On-chain orchestrator
- Splitter0x8C42…446a
60 / 30 / 10 pull payment splitter
- LendingPool0x8d63…fF7e
Interest-free multi-reserve pool
- AutoProtectionVault0xD3fF…C530
Consumer-side dApp integration