Add venue-neutral transaction composition - #26
Merged
Conversation
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.
Summary
Why
This implements roadmap item 4: a client-local transaction-composition boundary that is independent of whether a future fill originates from RFQ, DLOB, or AMM routing. It lets multiple independently prepared legs be assembled atomically without introducing a remote RFQ wire format or venue-specific PSET ownership.
The staging model prevents aggregate validation and final assembly from silently diverging: a validated route owns the exact prepared legs and network fee it composes. Cross-contribution blinding uses exact outpoints, and payer inputs must belong exclusively to the wallet contribution.
Safety boundaries
This remains a provisional normalization/composition API. Route validation authorizes declared trade claims, not wallet change, ancillary-output net effects, per-asset balance, proofs, sighash policy, or signing. Each participant must still validate the complete blinded transaction before signing.
Issuance contributions, output aggregation, remote quote validity/provenance, and AMM/DLOB-specific covenant delta/finalizer models remain deliberately deferred.
Confidential input rangeproofs are copied into the dedicated Elements PSET field so they survive serialized participant handoffs.
Validation
nix develop .#default --command just ci-checksnix develop .#default --command just regtest-rfq-settlementNeed help on this PR? Tag
@codesmith-botwith what you need. Autofix is disabled.