OpenPIL
Public interest petitions, with a public records
Created on 18th October 2026
•
OpenPIL
Public interest petitions, with a public records
The problem OpenPIL solves
The problem it solves
Public Interest Litigation gives people a way to bring civic concerns before a court, but the progress of a petition can be hard for the public to follow. Filing details, who is responsible for review, deadlines, extensions, and decisions may be scattered across systems or difficult to verify independently. That makes it harder to understand what happened and when.
OpenPIL demonstrates a shared, queryable record for that lifecycle. Petitioners can submit a petition in Markdown; a registered court takes ownership of its review record; and the review deadline, any extension, and the eventual decision can be inspected as linked records. Anyone can browse petitions and check the recorded creator, current owner, court registration, timeline, and status. This makes public scrutiny and record checking easier without relying only on one operator's account of events.
What people can use it for
- Browse public petitions and filter them by court, title, or status.
- Read a petition alongside its review timeline, deadline, extensions, and recorded decision.
- Submit a synthetic petition and see its review record created and assigned to a registered court in one transaction.
- Inspect the underlying Arkiv records and verify how the app derived a petition's status.
- Explore how expiring review leases and public ownership history could support accountability in a civic process.
Scope
OpenPIL is a demonstration, not an official court filing service. Its sample petitions, court, and identities are synthetic. A recorded petition or decision does not establish legal validity, truth, government adoption, or who personally made a decision. The public demo court uses a shared demonstration key. Use synthetic content only; petition text, reasons, titles, court codes, dates, and wallet addresses are public on Arkiv.
Challenges I ran into
Challenges I ran into
Anonymous RPC limits made the live feed unreliable
The app initially made several independent reads, and Tiramisu began returning HTTP 429 responses. Anonymous query cost limits also affected WebSocket setup, so adding a live subscription did not solve the read problem.
I changed the browser to load one paginated OpenPIL snapshot, derive the screens and counts from it, and reuse it with a short freshness window. Browser reads now pass through a same-origin server proxy that holds the RPC access key. WebSocket events are treated as refresh hints, not as a source of truth. See use-openpil-snapshot.ts, clients.ts, and app/api/arkiv/route.ts.
Entity predictions and atomic filing needed careful reconciliation
A petition filing creates both a petition and a review, then transfers review ownership to the court. I used predictEntityKeys so the review can reference the petition in the same batch, and compare the returned keys with the predictions. The UI does not treat an uncertain write as success; the saved transaction and resulting records can be checked before retrying. See file-petition.ts.
Expiration extensions were easy to misread
A relative extension duration targets an expiry from the current block. It does not mean “add this many days to the existing expiry,” and can fail when the entity already lasts longer. Keep alive therefore reads the current entity and extends to its current expiry plus 30 days of blocks. Review extensions calculate a target deadline and extend the review lease in the same batch as the reason record and deadline patch. See keep-alive.ts and extend-review.ts.
Queries had to preserve Arkiv attribute types
A query using a bare bigint can encode a different integer cell type from a stored u64 attribute and quietly return no match. I made the model and query code use matching typed values and documented the exact query contract for independent reproduction. See model.ts, queries/page.ts, and arkiv/schema.md.
More observed integration issues and reproduction notes are in arkiv/friction.md.
Link to a twitter post explaining your project (or post with the video)
Tracks Applied (4)
Censorship Resistance
Open Source
Security
Best Indian Use Case
Technologies used
Cheer Project
Cheering for a project means supporting a project you like with as little as 0.0025 ETH. Right now, you can Cheer using ETH on Arbitrum, Optimism and Base.
