RFP: Bring Your Own Solver (BYOS)

RFP: Bring Your Own Solver (BYOS)

Summary

CoW DAO seeks a grantee to build a “Bring Your Own Solver” (BYOS) solver: a bonded solver that participates in the standard CoW auction and whose proposed solutions are sourced from a permissionless set of external sub-solvers. Sub-solvers submit signed routing proposals against specific order uids, collateralized by an escrow balance held by BYOS, and BYOS retains exclusive control over on-chain settlement submission. Deliverables are a solver engine, a Trampoline contract for safe sub-solver execution, a per-chain native-token escrow contract, and a public proposal API.

Background

Becoming a fully bonded CoW solver carries communication, legal, and operational overhead that only well-resourced entities can clear today. There is demand from less professionalized participants who want to bid on individual orders without that overhead: users and UIs that want execution against a baseline they have computed themselves, external parties that want to bid on individual trades without RFQ or KYC, and liquidity sources that want their pools considered in the auction. BYOS lets all three participate by collecting permissionless sub-bids and encoding them into standard CoW auction settlements. BYOS itself is bonded, liable for any damage, earns standard rewards, and should be operable as a standalone profitable business.

High-Level Design

A sub-solver computes a route for a specific order UID and submits a signed proposal to BYOS. BYOS continuously simulates pending proposals. On a /solve request, BYOS selects from proposals that still simulate successfully and crafts a settlement that transfers sellAmount from GPv2Settlement to the Trampoline, invokes the sub-solver’s interactions inside the Trampoline, and pulls buyAmount back. The Trampoline holds no protocol balance, so a malicious sub-solver cannot exfiltrate buffers or plant persistent approvals against settlement-controlled funds. Settlement reverts atomically if the promised buy amount is not delivered.

Scope

In scope: solver engine integrated with the CoW driver and autopilot, Trampoline contract, per-chain native-token escrow contract, public proposal API with EIP-712 signed submissions, reference sub-solver client, and operational runbook and monitoring. v1 targets Ethereum mainnet and Gnosis; escrow contracts must be chain-agnostic from day one. Out of scope: any BYOS-operated orderbook or order-discovery channel, pass-through of CoW rewards to sub-solvers, cross-chain escrow accounting, and the bonding capital for the BYOS solver itself.

Specification

Solver engine. Build a solver engine that bids on orders for which it holds a proposal that has passed local simulation against the reference block. When multiple proposals exist for the same order UID, the engine selects the one yielding the greatest surplus after any configured BYOS fee.

Trampoline contract. Receives sellAmount, executes arbitrary sub-solver interactions, returns buyAmount, and holds no protocol balance outside a single settlement. Native ETH wrap/unwrap must be specified explicitly. Two viable topologies: a single shared Trampoline with strict allowance hygiene, or one instance per sub-solver address. Applicants state a preference with reasoning; the final call sits with the Core Team Reviewer and grantee in M1. The Grants Council does not arbitrate technical contract topology.

Escrow contract. Per-chain, denominated in the native token of that chain. Anyone can deposit into a balance keyed by sub-solver address. Sub-solvers withdraw, subject to a cool-down period (default: 1 day; operator-configurable). BYOS holds an exclusive debit function for revert penalties and gas. All flows emit events. No cross-chain accounting in v1.

Proposal API. Public HTTP with POST /proposals (body: order_uid, interactions, valid_until, escrow_account, nonce, and an EIP-712 signature), GET /proposals/{order_uid} (metadata only, never full contents, to avoid the API becoming a leakage channel), and DELETE /proposals/{id} (cancellation by the original signer). Proposals expire at valid_until, on inclusion in a settled solution, or on the underlying order being canceled or filled by another solver. BYOS re-simulates accepted proposals continuously and silently drops those that begin reverting. EIP-712 schema, rate-limit policy, and authentication model are for the grantee to propose.

Order discovery. BYOS does not provide one. Sub-solvers obtain orderflow through the public CoW orderbook API, direct delivery from opted-in users or UIs, or routes encoded in user app data. BYOS does not operate an orderbook, push orders to sub-solvers, or surface its proposal queue.

Safety

Sub-solvers never receive submission keys and never call settle directly; BYOS retains exclusive control over solution submission, mirroring how non co-located solvers operate under the CoW DAO bond today. The Trampoline pattern confines sub-solver interactions to a context that holds no protocol funds, so buffer exfiltration and approval backdoors against settlement-controlled balances are not possible. The escrow contract handles revert-spam: proposals are only eligible when escrow covers the worst-case penalty and gas, failed settlements debit the escrow, and undercollateralized sub-solvers are filtered out. The public endpoint requires per-source rate limits, optionally backed by an escrow-balance threshold. BYOS must introduce no new orderflow leakage beyond what already exists in the public CoW orderbook.

Economics

BYOS participates in the standard CoW reward mechanism under its own bonded solver address and retains 100% of rewards earned. A configurable fee on winning solutions (percentage of volume or surplus) defaults to 0 in v1; proposals whose surplus does not cover the fee are rejected at acceptance. Pass-through of rewards to sub-solvers is out of scope for v1. BYOS should be profitable enough to fund its own maintenance beyond M3.

Milestones

  • M1: Design and contracts. Final design document covering Trampoline topology, proposal schema, escrow interface, and fee mechanism, with the topology decision agreed with the Reviewer. Implemented Trampoline and Escrow contracts with a full test suite covering reverting sub-solver scenarios, allowance hygiene, and escrow accounting. Audit-ready package.

  • M2: Solver engine and API. BYOS engine integrated with the CoW driver and autopilot on staging. Public proposal API is live with at least one reference sub-solver client. End-to-end staging test with a real sub-solver settling testnet orders.

  • M3: Audit and mainnet. Security audit completed and findings remediated. Bonded solver onboarded on Ethereum mainnet. At least one external sub-solver is onboarded and settling live orders. Operational runbook and monitoring in place.

Payment split to be proposed by applicants with justification.

Acceptance

All deliverables landed in the agreed repositories, contracts pass audit with no unresolved high or critical findings, the engine wins and settles at least 10 live mainnet orders sourced from external sub-solvers, median /solve latency within the protocol’s solver SLO, all code under an OSI-approved open-source license compatible with the rest of the CoW stack.

Evaluation

Applications will be evaluated on demonstrated solver, contract, or DEX infrastructure work; understanding of CoW solver competition, settlement, bonding, and orderflow privacy; architecture quality (Trampoline topology, escrow design, API safety); audit track record with a named partner where applicable; operational readiness to run a bonded solver in production; clarity of milestones and acceptance evidence; timeline; and cost.

Selection Process

The Grants DAO committee is selected in coordination with the CoW core team. Two roles run the engagement:

  • Steward (Grants Committee member): coordination, administration, milestone tracking, payment.

  • Reviewer (Core Team member): technical and strategic evaluation, contract design sign-off, integration approval.

Open design decisions called out above (Trampoline topology, EIP-712 schema, rate-limit policy, auth model) are resolved between the grantee and the Reviewer. The Steward facilitates but does not arbitrate technical content. The committee may close or extend the timeline, request clarifications, select none of the proposals, or negotiate scope and budget.

How to Apply

Submit a proposal as a reply to this thread or as a separate forum post in the CoW Grants Program category using the standard Grant Application Template. Cover team background and relevant solver/contract/infrastructure experience, proposed approach including stance on Trampoline topology, milestones with payment split, budget breakdown, and references. Deadline: June 26, 2026. Questions via Discord or forum reply.

Terms

Applicants are bound by the CoW DAO Grant Agreement Terms and the Participation Agreement. Payments in stablecoins (USDC, DAI, or USDS) on Ethereum mainnet, 30 days after milestone completion. Deliverables open source under an approved license.

3 Likes