ERC-8454 AIFi Economic Unit Framework (AIFi Unit Framework)
Draft · Other · created 2026-10-21
The AIFi Unit Framework defines units of AI economic activity, such as agents, tasks, models, and funds, using four frames, boundary, role, observation, and valuation, records them on-chain, and makes it possible to compare different valuations.
Why it is needed
Agents, executable skills, tasks, models, compute, data, and funds are increasingly being issued, traded, and composed on-chain, but each standard addressing them describes only its own individual kind. Without a common underlying language, three problems recur. First, even when two parties refer to the same agent business, the resources, licenses, and obligations it includes differ, making valuations incomparable. Second, each part of a unit plays a different economic role depending on context, yet it is given only a single permanent label (for example, staking pool, task), obscuring cost, lock-up, and control points. Third, when two assessors produce 100 and 200 for the same target, no one can tell whether that is net worth, daily yield, completion probability, or credit rating, nor in which currency, as of what point in time, or whose interest it reflects.
What to implement
event UnitRegistered(uint256 indexed unitId, address indexed controller, bytes32 boundaryHash, string descriptorURI);: Emitted when a new unit is registered and version 1 is issued.event VersionPublished(uint256 indexed unitId, uint32 indexed version, bytes32 boundaryHash, string descriptorURI, uint256 containsCount);: Announces the boundary hash and number of included units when a new version of a unit is issued.event ControllerChanged(uint256 indexed unitId, address indexed previousController, address indexed newController);: Emitted when a unit's definition controller changes.event Acknowledged(uint256 indexed unitId, uint32 indexed version, bytes32 indexed elementId, AckKind kind, address account);: Emitted when an account records a confirmation for an element of a unit version.event AcknowledgmentWithdrawn(uint256 indexed unitId, uint32 indexed version, bytes32 indexed elementId, AckKind kind, address account);: Emitted when a previously recorded confirmation is revoked.function registerUnit(address controller, bytes32 boundaryHash, string calldata descriptorURI, UnitRef[] calldata contains) external returns (uint256 unitId);: Registers a unit and issues its first version.function publishVersion(uint256 unitId, bytes32 boundaryHash, string calldata descriptorURI, UnitRef[] calldata contains) external returns (uint32 version);: The definition controller issues a new version of the unit. Fails on a frozen unit.function setController(uint256 unitId, address newController) external;: Transfers definition control authority to another account, or permanently freezes it by specifying the zero address.function acknowledge(uint256 unitId, uint32 version, bytes32 elementId, AckKind kind) external;: The message sender records a confirmation for one element of a unit version.function withdrawAcknowledgment(uint256 unitId, uint32 version, bytes32 elementId, AckKind kind) external;: Revokes a previously recorded confirmation.function unitCount() external view returns (uint256);: Returns the total number of registered units.function controllerOf(uint256 unitId) external view returns (address);: Returns the current definition controller of the unit.function isFrozen(uint256 unitId) external view returns (bool);: Returns whether the unit is frozen.function latestVersion(uint256 unitId) external view returns (uint32);: Returns the latest version number of the unit.function versionOf(uint256 unitId, uint32 version) external view returns (bytes32 boundaryHash, string memory descriptorURI, uint64 publishedAt, uint256 containsCount);: Returns the boundary hash, description document location, issuance time, and number of included units for a specific version.function containedAt(uint256 unitId, uint32 version, uint256 index) external view returns (UnitRef memory);: Looks up an included unit reference by index for a specific version.function acknowledgedAt(uint256 unitId, uint32 version, bytes32 elementId, AckKind kind, address account) external view returns (uint64);: Returns the time at which a specific account recorded that confirmation.event DescriptorRegistered(bytes32 indexed descriptorHash, bytes32 indexed descriptorKind, address indexed publisher, string uri);: Emitted when a descriptor such as a method, profile, or schema is registered.event Asserted(bytes32 indexed assertionId, uint256 indexed unitId, uint32 indexed version, AssertionKind kind, address asserter, bytes32 profileId, bytes32 contentHash, bool byController);: Emitted when a claim (characterization, observation, valuation, extension) is recorded for a unit version.event ValuationAsserted(bytes32 indexed assertionId, uint256 indexed unitId, bytes32 indexed methodId, bytes32 interestId, uint8 resultKind, int256 value, bytes32 denominationId, uint64 asOf);: When a valuation claim is recorded, announces the method, interest, and outcome value together.event ObservationAsserted(bytes32 indexed assertionId, uint256 indexed unitId, bytes32 snapshotHash, uint64 windowStart, uint64 windowEnd);: When an observation claim is recorded, announces the observation window and snapshot hash.event Revoked(bytes32 indexed assertionId, address indexed asserter);: Emitted when an asserter revokes its own claim.event Superseded(bytes32 indexed assertionId, bytes32 indexed supersededBy);: Emitted when a claim is replaced by a new claim.
In depth
Unit definition document and boundary hash
A Unit Definition is a JSON document that must include auf (data model version), kind (must be unit-definition), unit (name/summary/tags), elements, relations, ports, and authorities. validity (from/until), scale (observation window), extensions, and metadata are optional. This document's boundary hash (boundaryHash) is the value obtained by normalizing it with the JSON Canonicalization Scheme (RFC 8785), encoding it as UTF-8, and hashing it with Keccak-256, and it must match the hash recorded in the registry. Economic figures such as amounts, ratios, and prices must be encoded as decimal strings rather than JSON numbers, so that their representation does not change during normalization.
Element and Relation
An element is identified by kind (one of agent, skill, task, service, model, compute, data, financial-position, unit, or an extension kind) and ref, and elementId is keccak256(the string formed by joining kind and ref with a colon). Within a single definition, no two elements may share the same elementId. A relation specifies the parties via from/to (or, for an identity relation, a set of elements) and indicates its kind via type. Type is divided into structural (contains), rights (owns, licenses, reserves, revenue-share, holds), obligations (owes, commits, pledges), dependency (depends-on), interaction (exchanges, controls), and identity (same-claim, distinct-claim). The contains relation must form a directed acyclic graph among units.
Ports, versions, inclusion structure, freezing
A port expresses a unit's economic interface with a direction (in/out/inout) and a class (funds, resource, deliverable, right, commitment, control). A unit's version starts at 1 and increases strictly, and each version commits exactly one boundaryHash and one descriptorURI. A contains relation must point to a specific version of another unit that already exists in the same registry, and the registry verifies its existence at issuance, so the inclusion structure cannot be structurally cyclic. Once the Definition Controller becomes the zero address, that unit is frozen and can no longer issue new versions.
Limits of Authorities
The authorities object declares definitionController (none when frozen), representatives, beneficiaries, and settlementAccounts. This is merely a declaration of where actual authority lies, and this ERC does not grant that authority. Controlling a unit's definition does not automatically confer disposal rights over its elements, the right to represent the unit, or any claim on cash flows, and registries, resolvers, and consumers must not infer such rights from the controller role alone.
Rules for claim duplication and resolution
A pair of positions from different claim groups on the same side (holding or owing) becomes a single claim group if declared same-claim, or a resolved pair if declared distinct-claim. All other pairs are unresolved, and an empty or differing underlying reference alone does not prove distinction. The resolver must report every claim group that appears more than once in the tree and every unresolved pair, and must not merge or distinguish elements based solely on label, amount, or party notation. A same-claim or distinct-claim declaration becomes confirmed only once one of the position's issuer, debtor, counterparty, or controller leaves a description-endorsement acknowledgment.
The four kinds of acknowledgment
On-chain acknowledgments are fixed to four kinds: Participation, ResourceUse (resource use approval), FundOperation (fund operation approval), and DescriptionEndorsement (description approval), and resolvers or consumers must not collapse these into a single boolean. A unit definition may declare the expected acknowledgment kinds (expectedAcks) per element, and external dependency elements included via depends-on require no acknowledgment at all. An element with no expected acknowledgment is treated as asserted, not confirmed.
The assertion envelope and its kinds
The four kinds of assertion, characterization, observation, valuation, and extension, share the same on-chain envelope (kind, unitId, version, profileId, contentHash, contentURI, validity period, supersedes, asserter, status). Assertions are split into Controller Assertions, which are self-descriptions, and Third-Party Assertions, which are external evaluations; a signature or transaction proves only provenance, not that the conclusion is correct. An asserter may withdraw its own assertion at any time and may replace a prior assertion with a new assertion of the same kind.
The valuation receipt and result kinds
A valuation receipt holds subject, interest, snapshot, method, inputs, and result. result.kind is one of monetary, interval, distribution, scenario, vector, conditional, score, grade, not-valuable, insufficient-evidence, or not-applicable, and scores and grades must not be recorded as monetary values. Two receipts can be compared only if the subject version, boundary, interest, perspective, currency unit, valuation time, and horizon match, and the methods are either identical or declared comparable. A receipt that sums unresolved position pairs into a point value is treated as inconsistent and must be reported as an interval or as insufficient-evidence. This ERC is currently in Draft status; it has not been finalized and may still change or be withdrawn.