Repository navigation
docs(blueprints): align F5-F7 and demo paths with the ADR-0005 escrow, approval and refund flows - #140
Merged
Conversation
… and hire states F5 Hire and pay is now the escrow path: the server prepares create_job and fund, the wallet signs each envelope unchanged, the server verifies and relays it, and the tracker confirms fund and checks the job (state Funded, client and evaluator = consumer, provider = agent wallet, USDC, budget, expired_at) before the agent runs. A cancel before paying is a reject from open, labeled "Cancelled"; an unfunded hire past expired_at shows as Expired. F6 keeps the hire funded while runtime progress (queued, running, failed) is shown, then submitted after the server-signed submit. The client approves (complete) or rejects before the approval deadline; silence ends in release. A failed run is refunded by the client's reject (primary) or claim_refund after expired_at (fallback). F7 offers rating only after completed, with no authorize_feedback step: the paid-hire rule is a completed escrow job (D5), and the hire keeps a feedback reference instead of a rated state. Both demo paths sign create_job and fund and show Funded, Submitted and Completed. Sources now cite ADR-0005 and the API contract. Closes #76
Deploying puls3 with
|
| Latest commit: |
03140ef
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://3c316353.puls3-4lw.pages.dev |
| Branch Preview URL: | https://docs-76-flows-adr0005.puls3-4lw.pages.dev |
TOMOKI977
approved these changes
Oct 8, 2026
TOMOKI977
left a comment
Contributor
There was a problem hiding this comment.
Approved. F5–F7 and both demo paths now match ADR-0005 and the relay contract in api.md:
- F5:
create_job→fund, each signed unchanged and relayed by the server, then the tracker's job check before the run. - F6: the hire stays
fundedwhile the run shows its own progress, thensubmitted→ approve/reject, orreleaseafter the deadline. - Edge paths: Cancel from
open, the derived Expired state, and the refund paths. - F7: feedback without
authorize_feedback.
Some of it describes behavior that is still post-demo work: the tracker calling release and claim_refund (#97) and the server-signed submit (#18). That's fine for a flows document.
10 tasks
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 #76
Summary
docs/blueprints/flows.mdstill described the direct SAC transfer, the six-check verification,authorize_feedbackand the #10 states. F5–F7 and both demo paths now follow ADR-0005 (D1, D4, D5, D6, D8) and the relay contract indocs/architecture/api.md(#77). F1–F4 are unchanged.F5 Hire and pay is the escrow path:
create_job, thenfund;fundand checks the job before the agent runs: stateFunded, client and evaluator = consumer, provider = agent wallet, USDC, budget,expired_at.New edge rows:
JobMismatch/JobEvidenceUnavailable: the funds stay in the escrow untilexpired_at;openhire: a reject fromopen, labeled Cancelled;expired_at: shown as Expired, with no transaction.F6 Track, result and approve:
submit;completeor rejects before the approval deadline;releaseand the hire is Completed (D4). The countdown UI comes by HackMeridian, and the window length is deferred (D3).Refund paths, each with its own edge row:
claim_refundafterexpired_at, and the hire is Expired (fallback).A reject is final (D8), and only rejects of submitted work count against the client.
F7 Rate:
authorize_feedback: the paid-hire rule is a completed escrow job (D5);HireAlreadyRatedis the only "already rated" path.Demo paths: sign
create_jobandfund, show the escrow holding the USDC, then Funded → Submitted → Approve → Completed.Header: sources now cite ADR-0005 and the API contract.
Acceptance criteria
api.mdclaim_refundafterexpired_at; F6 step 5: reject and refund)openis labeled "Cancelled" (F5 step 7, F6 step 6); nocancelled,failed,inProgressorratedhire state remainsS06-hire-detailVerification evidence
The remaining matches for the stale terms are not hire states:
I rendered every Mermaid block through mermaid.ink: all 7 diagrams return an SVG with no syntax error. F5, F6 and F7 are blocks 4, 5 and 6.
Notes for reviewers
api.md(createHire,prepareFund,submitEscrowCall,prepareComplete,prepareReject,JobMismatch,HireAlreadyRated). Where docs: update MVP flows to ADR-0005 escrow and hire states #76's deliverable 1 says "signs authorization entries", the contract decided that the wallet signs the prepared envelope unchanged (Decision A), and these flows follow the contract.