Repository navigation
spec(automation): token-wallet v3 -- the TRINET 1:1:1 split (Closes #13084) - #13085
Merged
Merged
Conversation
) Owner formula of 2026-11-02: 3 units = 1 to the provider of the service + 1 to the fund (creators, .t27 developers, builders, operations, reserves) + 1 to the first-line referrer. - SHARE_HOUSE -> SHARE_PROVIDER, SHARE_BOUNTY -> SHARE_FUND (no host imports the old names) - REFERRAL_DEPTH 1: only the direct referrer is paid - a client with no referrer: unit three is held, paid to nobody (a default until the owner names its destination) - the split stays unit-blind; the spec never prices, promises or mints $TRI - 2 new tests (13 total); the seal is stale until a post-10-27 t27c re-saves it Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
gHashTag
force-pushed
the
claude/trinet-payment-distribution-4670d9
branch
from
November 2, 2026 04:17
2495fa7 to
8fa617b
Compare
Contributor
…held default (Refs #13084) Withdraws the agent default that held unit three for a client with no referrer. Such a charge now answers SPLIT_POLICY_UNRESOLVED and may not be debited until the owner decides. A charge that is zero or not whole units answers SPLIT_REFUSED_AMOUNT instead of a split of zeros. Every accrual goes through trade_split_status, and the referral accrual takes the recipient's line, so the first-line rule constrains the amount itself. Tests: a loop over lines 0..5 (exactly one line paid), conservation over fifty accepted prices, refusals, and the unresolved no-referrer path. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…und (Refs #13084) Owner decision 2026-11-02: when the client came from nobody, unit three goes to the fund. Every client pays the same three units and nothing is held. SPLIT_POLICY_UNRESOLVED is removed; the split status depends on the amount only. fund_accrual takes two units without a referrer; referral_accrual pays nobody then. Conservation is tested for both cases. Tests not executed (no free test cell); the seal is stale and not re-saved. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Re-saved from t27c-bootstrap@0.5.2+bc19b54e6 (built from master bc19b54) at head 28a7971: spec_hash f72f8230..., tests 15 of 15, 0 failed, 0 vacuous, forced false. The previous seal (fede3e15..., 11 tests) described token-wallet v2. Refs #13084 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Contributor
PR DashboardGenerated at: 2026-11-02 06:27:41 UTC
Summary
Seal Status
|
This was referenced Nov 2, 2026
This was referenced Nov 9, 2026
Co-authored-by: Dmitrii Vasilev <gHashTag@users.noreply.github.com>
This was referenced Nov 9, 2026
Contributor
PR DashboardGenerated at: 2026-11-09 21:13:27 UTC
Summary
Seal Status
|
This was referenced Nov 9, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #13084
What
specs/automation/token-wallet.t27v3 records the owner's TRINET formula of 2026-11-02 in thethree-unit trade that already exists there (owner decision 2026-10-23), instead of a second spec:
REFERRAL_DEPTH1)Owner decisions in this PR (2026-11-02):
Nothing is held.
Agent default, not an owner rule: a charge of zero, or one that is not a whole number of
units, is refused (
SPLIT_REFUSED_AMOUNT). It is never split into zeros, and nothing is debited.The spec calls the following (
chargedis what the client paid):trade_split_status(charged)returnsSPLIT_OKorSPLIT_REFUSED_AMOUNT.trade_may_debit(charged)gates every accrual.provider_accrual(charged)returns unit one.fund_accrual(charged, has_referrer)returns one unit, or two when there is no referrer.referral_accrual(charged, has_referrer, line)goes throughreferral_line_pays(line), sothe first-line rule constrains the real accrual and not only a helper.
The split does not depend on the unit. The spec never prices, promises or mints $TRI.
Receipts
Binary
t27c-bootstrap@0.5.2+bc19b54e6(built from master bc19b54),nice -n 10, no forcedexit code. Each run was in the owner's Terminal on 2026-11-02.
specs/automation/token-wallet.t27at 28a7971, sha256f72f8230...fede3e15...REFERRAL_DEPTH= 2, sha256a236331a...The command was
t27c test-report <input>. The negative control fails the first-line test andno other test, and it fails rather than blocks, so the test constrains the accrual.
Seal: I re-saved it with
t27c seal specs/automation/token-wallet.t27 --savefrom the samebinary, at commit f3db3d3, with these values:
spec_hashsha256:f72f8230...;forcedfalse;seal_schema2.The seal has no home path and no twin.
Not in this PR
its own plan and approval.
pool.t27job split.payable.
CI context
These reds are not from this PR:
PolicyOwnLanguageseal STALE, inherited from the base (ci(gates): pin six gen-c gate jobs to ubuntu-24.04 and send the L2 list error to stderr (Refs #13058) #13061).ParsedCommandNEW conflict, identical on the base (ci: master types ratchet red -- ParsedCommand defined twice since b91295e672 #13087).This PR stays a draft, with no auto-merge.
🤖 Generated with Claude Code
Note
Low Risk
Spec and seal updates only; no host or billing code changes, though v3 defines future payment-split semantics reviewers should treat as policy.
Overview
Bumps automation::token_wallet to v3 and re-seals it (
seal_schema2, 15/15 tests ont27c-bootstrap@0.5.2). This is a spec-only change; the live bot is still documented as vending v1.The three-unit trade is renamed to the TRINET 1:1:1 model:
SHARE_PROVIDER,SHARE_FUND, andSHARE_REFERRAL, withREFERRAL_DEPTH1 so only the direct referrer can earn unit three. New split APIs gate debits and accruals: invalid charges (zero or not divisible byTRADE_UNITS) returnSPLIT_REFUSED_AMOUNTviatrade_split_status/trade_may_debitinstead of zero-filled splits;fund_accrualtakes the referral unit when the client has no referrer so the full charge is still conserved.Tests cover first-line referral rules, conservation with/without a referrer, and refusal behavior. Header comments record owner v3 policy (2026-11-02) and what remains open before any host implements the split.
Reviewed by Cursor Bugbot for commit 100bdb0. Bugbot is set up for automated code reviews on this repo. Configure here.