ERC-8240: Trust Infrastructure for Agents and Assets

Hi everyone,

Update — Composability map & predictive layer

As the agent economy grows across multiple ERCs, here’s how ERC-8240 relates to each — not as a competitor, but as a composable quality layer that plugs on top.

ERC-8004 (Trustless Agents): Identity + reputation. ERC-8240 adds continuous quality scoring (0–100, 15 min refresh, multi-evaluator) and predictive trajectory. An agent registered via 8004 gets a portable identity. ERC-8240 measures if that agent is good — and predicts if it will stay good. We built an adapter: getQualityForAgent(registry, agentId) returns score, trend, volatility, timestamp. 29 tests passing.

ERC-8183 (Agentic Commerce): Escrow and payments. ERC-8240 gates the payment by quality: escrow releases only if the agent’s score meets the threshold. Quality-proportional payments — AAA agents earn more than BB agents. Composable via our TrustGatedPayment primitive.

ERC-7943 (Universal RWA Interface): Defines the RWA token interface. ERC-8240 scores the quality of that token: custodian health, NAV integrity, compliance drift, basket contagion. Different layers — 7943 wraps the asset, 8240 measures it.

ERC-8210 (Agent Assurance): Assurance and insurance. ERC-8240 adds the predictive dimension: TrendOracle detects behavior trajectory, EarlyWarningEngine flags risk 48h before incidents, ForecastRegistry provides verifiable predictions with accuracy tracking. Assurance reacts. Prediction prevents.

ERC-8118 (Agent Authorization): Authorization decisions. ERC-8240 gates authorization by quality score. An agent’s permissions are tied to its lifecycle state, driven by the quality score. Score drops → permissions restricted automatically.

ERC-8203 (Agent Off-Chain Settlement): Off-chain settlement. ERC-8240 adds on-chain quality verification as a settlement condition. Before settlement executes, the quality score is checked.

The pattern: ERC-8004 says WHO the agent is. ERC-8183 PAYS the agent. ERC-8118 AUTHORIZES the agent. ERC-8240 says if the agent is GOOD — and predicts if it will STAY good. Same subject, different layers. All composable.

What’s new since the composability post:

  • ERC-8240 — official number assigned (was PR #1705). Preamble update incoming.
  • TrendOracle (P8) completed: trend direction, momentum, volatility, projections from 24-slot on-chain ring buffer (~5,000 gas per write). 32 tests.
  • TrendOracleConsumer mixin: adapters auto-switch between inline fallback and external TrendOracle. Backwards-compatible.
  • Public repo: github.com/nicobernad/alia-agents (interfaces + deployment addresses)
  • ERC-8004 adapter + BAP-578 hook + ERC-8183 gate + ERC-7943 scorer: 133 tests passing
  • Total: 55 contracts, 1,082 tests, 0 failures, 3 chains (Base + Gnosis + BNB)

Feedback welcome — especially from teams building on these standards. The quality layer is designed to plug into what you’ve already built, not replace it.

1 Like