Presto: Royalty Recovery Engine
How do you keep one royalty lead from being paid twice?
Say a tool finds a gap between a songwriter’s catalog and a royalty registry and turns it into a lead. Later the matcher improves, so you scan the same catalog again. Now there are two leads for one catalog row. If each can be paid and invoiced on its own, the same recovery gets billed twice.
Presto’s recovery engine had exactly this bug, and the fix says a lot about how the workflow treats money. Presto has no customers and no recovered dollars yet, and its accuracy on production data hasn’t been measured. Everything below describes a prototype checked against tests, synthetic data and one official sample file.
Case page: /projects/presto-royalty-recovery-engine. Public site: prestorecovery.com. The engine’s repository is private.
Registries pay on what is registered, not on what is owed
Songwriters and labels get paid through registries. The MLC (Mechanical Licensing Collective) pays on compositions, and SoundExchange pays on recordings. If a registry’s share for a work is missing, marked unclaimed, or lower than the share the partner believes it owns, that’s money left unclaimed.
The public site walks through one synthetic example. A song called “After the Last Train”, written by Sam Ortiz, carries the same title, writer and ISWC (the work’s identifier) in both sources. The label’s catalog expects a 50% share. The registry snapshot shows 25%. That 25-point gap becomes a lead held for a person to review.
One gap is easy to spot by hand. The hard part is doing it across a bulk registry feed with inconsistent identifiers, explaining every lead, and making sure the workflow around it can’t lose or duplicate money. I built the engine’s matcher, the ingester for the MLC’s bulk feed, the crash-recoverable workflow, an on-chain proof of packet integrity and the demo site, as the software engineer on a three-person founding team from July to September 2026.
Blank means unknown
The first rule is about what not to compute. The MLC’s bulk feed uses the DDEX BWARM format. The DDEX spec never says claimed and unclaimed shares add up to 100, so the engine never computes 100 - unclaimed. An unclaimed row gets a blank claimed share. If writer shares add up to more than 100, the engine emits the share blank and counts a warning instead of clamping it.
The project’s own learnings put it plainly. In a recovery product, a fabricated lead is worse than a missed one. Inferring a share nobody observed tells a customer they’re owed money they may not be owed.
Matching, and when to stop and ask a person
The matcher works in three steps:
| Step | What happens |
|---|---|
| Exact pass | Try the ISRC (recording identifier), then the ISWC. More than one hit is ambiguous. A single hit whose other identifier disagrees is a conflict. |
| Fuzzy pass | Only when there’s no exact hit. Score the title paired with every writer on the registry record. Require a best score of at least 0.85. |
| Near-tie guard | If the runner-up scores within 0.03 of the best, mark it ambiguous and send it to a human. |
Every lead carries its match type, its confidence, the runner-up’s confidence, the reason it’s a candidate, and a blocking reason when there is one. A reviewer can see why the lead exists without rerunning anything.
Two identities per lead
Back to the double-payment bug. Each lead originally had one id, candidate_id. Before re-scans were allowed, an id collision made overlapping leads impossible, so “one lead per catalog row” held by accident. Then the id was scoped to the run, so a better matcher could re-scan the same catalog and produce new leads instead of being refused. That removed the accidental guarantee. Every money step was keyed on candidate_id, so the same row could now be paid and invoiced twice.
The fix gives every lead a second identity:
candidate_idis run-scoped. It hashes the run id with the catalog row, so each scan’s leads are its own.entry_keyis run-independent. It identifies the catalog row itself.
Recording a payment is refused if any other lead with the same entry_key is already paid. The invoice step does that check on its own, and also refuses if an invoice file already exists for any sibling. The second guard has its own test, which forces a lead to “paid” without going through the payment step. The project’s lesson from this was to fix the invariant explicitly and test each guard on its own.
The workflow is also built to survive a crash. State is written to a temp file and swapped in with an atomic replace, so a crash leaves the old file or the new one, never half of each. Every change goes to an append-only journal, and an exclusive lock stops two processes from editing one workspace.
Presto itself doesn’t move money, submit portal claims, store credentials or operate wallets. It prepares claim packets that a person files through official portals.
How it was checked
The recovery package is about 5,400 lines of standard-library Python with 225 unit tests, run in CI on Python 3.10 through 3.13.
The most useful check was real data. Every test fixture was synthetic until I ran the ingester on DDEX’s free 42 KB official BWARM sample, which is heavily scrubbed but real. It found seven parser defects. One of them would have reported ten fully claimed works as recovery candidates. All seven are fixed, and the sample now ingests cleanly. It yields 10 works, skips 0, and every one sits at a 100% claimed share.
There’s also a match-accuracy benchmark, but its ground truth is synthetic. At the 0.85 threshold, on 72 positives and 56 negatives, it scored precision 1.000, recall 0.556 and a false positive rate of 0.000. That’s evidence the fuzzy matcher tolerates typos without false matches on synthetic data. It isn’t production accuracy, and it can’t be quoted as accuracy.
What’s still open
The real-data evidence is thin. Every ISWC and IPI (an identifier for writers and other rights holders) in the official sample is blank, so the exact-identifier path has never seen real data. The sample’s unclaimed-share file is 0 bytes, so the unclaimed branch hasn’t seen real data either. SoundExchange publishes no bulk file and its terms forbid automated collection, so SoundExchange rows have to be produced by hand.
The demo on the public site is a scripted AI review on synthetic data. The site says the team is looking for design partners and testing success-based pricing, and that it would start with one catalog run as a controlled experiment. Two items from the project’s own “what I’d do differently” list point at the next test. Get real data in front of the parser earlier, and measure memory and latency on a full feed before settling the indexing design. A first partner catalog with real identifiers would be the first time the exact-match path, and the double-payment guards, run on anything but synthetic rows.