ERC-1491 Human Capital Accounting Standard (HUCAP) (Human Cost Accounting Standard (Like Gas but for humans))

Stagnant · Signatures & auth · created 2018-10-12

Proposes a standard for tracking human capital data such as experience, reputation, and qualifications inside Ethereum smart contracts, using the beliefs, desires, and intentions (BDI) of people (agents) and a PGP key-signing web of trust.

Why it is needed

Because the Ethereum Virtual Machine (EVM) only handles deterministic state transitions, there was no way to standardize indeterminate information like a person's intentions or capabilities on chain. Oracle requests that fetch external data are ultimately just another deterministic transaction and cannot represent changes in a person's beliefs, desires, and intentions (BDI) as they actually occur. ERC-20, ERC-721, and ERC-1155 standardized asset tokens, but there was no common interface for evaluating an individual's capabilities, output, and knowledge base together, so each project had to manage reputation and qualifications its own way. This raises the market search cost of evaluating people and makes it harder for new knowledge and innovation to flow naturally into the blockchain ecosystem.

What to implement

In depth

Design based on the BDI model

This standard carries the belief-desire-intention (BDI) model proposed by Michael Bratman directly into a smart contract structure. BDI is a planning-theory framework used in agent-based modeling to explain future-directed intentions; it explains that desire and intention are distinguished by whether there is a 'commitment,' and that this commitment creates the temporal persistence of a plan and the hierarchical structure of sub-plans. The original text presents as its design rationale the idea that blockchain's cryptographic security structure can be extended directly to a PKI web-of-trust hierarchy, and that, just as ERC-20/721/1155 succeeded in standardizing asset tokens, human capability can likewise be handled through a standard interface.

Querying agent state and public data

iam() returns whether the call target is an agent and its IS state, index() returns the BDI index, and ringLength() and keyId() return the number of keys in the PGP keyring and the public key ID, respectively. merits() returns five values at once, experience_, reputation_, talent_, index_, and hash_, summarizing the agent's accumulated achievements. kbase() returns the knowledge certification stage expressed as the KBase enum. All of these functions are declared view, so they only query state and never change it.

Setting and querying desire and intention

desire(bytes1) and intention(bool) query, respectively, the pro-attitude value identified by bytes1 and the conduct-controlling pro-attitude value distinguished by bool. getDesire(bytes1) and getIntention(bool) additionally return whether the value is set, along with the state (IS) and figures. setbdi(bytes1 _desire, Desire _goal) and setbdi(Intention _service) set desire and intention respectively, and are restricted by onlyDoer. intention(bool _intention, IERC_HUCAP_TYPES.IS _state) is a function that sets intention and state together, and flipIntention() toggles the intention state.

The PGP web-of-trust key signing scheme

The Web-of-trust Extension Interface defines the PGP standard's signature types (KEY_CERTIFICATION, SIGN_DATA, ENCRYPT_COMMUNICATIONS, ENCRYPT_STORAGE, SPLIT_KEY, AUTHENTICATION, MULTI_SIGNATURE, etc.) and certificate types (GENERIC, PERSONA, CASUAL, POSITIVE, SUBKEY_BINDING, KEY_REVOCATION, etc.) as masked bytes32 constants. Trust level is represented by a Clearance struct with eight tiers: Zero, Unknown, Generic, Poor, Casual, Partial, Complete, and Ultimate. Together with the main interface's sign(address)/sign(), revoke(address)/revoke(), and trust(Trust), the extension's flipTo(address) and toggle(address) handle registering, revoking, setting trust on, and toggling the activation of an agent's keys, and every call is recorded via the LogCall event.

Knowledge certification stages and talent data

The User Defined Types Extension Interface defines the KBase enum with nine stages, PRIMARY, SECONDARY, TERTIARY, CERTIFICATION, DIPLOMA, LICENSE, BACHELOR, MASTER, and DOCTORATE, each marked in comments with weights of 1, 2, 4, 8, 16, 32, 64, 128, and 256 respectively. setbdi(KBase, bytes32 _country, bytes32 _cAuthority, bytes32 _score, uint _year) sets this certification information by taking in country, certifying authority, score, and year. The Human Capital Accounting Extension's getTalents(bytes32 _talent) returns four frequency values, talentK_, talentI_, talentR_, and talentF_, and talent values are incremented or decremented via incTalent()/decTalent().

Agent lifecycle and the track-user extension

The IS enum distinguishes an agent's role and activity status across seven states: CLOSED, CREATOR, CURATOR, ACTIVE, INACTIVE, RESERVED, and PROVER. In the Human Capital Accounting Extension Interface, initAgent(Doers _address) initializes a new agent under the onlyControlled restriction, getAgent(bytes32 _uuid) looks up an address by uuid, and getAgent(address _address) returns four values: keyid_, state_, active_, and myDoers_. isDoer(address) returns the IS state of that address, and the three overloads of setAgent set the key ID, state (IS), and activity status (bool) respectively. setAllPromises(bytes32 _serviceId) batch-updates every agent's intention (number of services rendered).

Still a stalled draft

This proposal is in Stagnant status, and the Rationale, Backwards Compatibility, Test Cases, and Implementation sections are all left empty as [WIP], so discussion has stalled with no further progress. The specification body also never shows where access-control modifiers such as onlyOwner, onlyDoer, ProxyKey, ProxyBDI, and onlyControlled, or types such as Doers, Trust, Desire, and Intention, are actually defined, and many functions' @dev comments trail off at "For the purpose of," leaving them unfinished.

Original ERC · ← ERCs