Inspiration
Chat models answer one question at a time. Real work, like a market report or a competitor scan, takes many steps, and the person using the chat has to split up the task, check the facts, and decide whether the result is good enough. The team wanted a system that runs that loop itself and makes the cost visible.
What it does
Chat models answer one question at a time. Real work, like a market report or a competitor scan, takes many steps, and the person using the chat has to split up the task, check the facts, and decide whether the result is good enough. The team wanted a system that runs that loop itself and makes the cost visible. The About page frames the goal as a way to “give your AI tasks a budget.” The CLAUDE.md build spec states it more directly: a user gives a task and a hard budget, and the system finds, ranks, hires, verifies, and pays the agents that do the work.
What it does
A user describes a task, sets a budget and a quality bar, and Kraven runs this pipeline:
Plan: a Manager model breaks the task into capabilities and a dependency graph of subtasks. The plan is then fitted to what the market can staff within the budget. Discover and rank: candidate agents are pulled from a marketplace and filtered by capability, budget, and quality. They are ranked on quality, cost, speed, and track record, not price alone. The ranking can reuse past workflows through a workflow memory. Escrow: the budget for each subtask is locked before any agent starts work. Execute and verify: agents run their subtasks, passing outputs downstream. An independent QA step scores each result. Failed work is retried with feedback, or reassigned to another agent. Pay: escrow is released only for work that passes QA. Reputation and performance history are updated. Deliver: the final report lists its sources, a confidence score, a numeric consistency check, and the total spend.
A deterministic Circuit Breaker sits in front of every money movement. The model can propose a transaction, but the code decides whether it happens. In the code we reviewed, the Circuit Breaker blocks any transfer that exceeds the task’s remaining budget or the escrow available, is from an inactive or revoked agent, or uses an unauthorized purpose. Blocked transfers do not change balances. The demo shows an agent requesting 10,000 tokens against an 8-token authorization, which is blocked with no ledger change.
How we built it
Frontend: Next.js 16 (App Router), React 19, TypeScript, Tailwind, shadcn/ui, Three.js via React Three Fiber AI: Vercel AI SDK with Zod validation on all model output. The commit history shows Gemini as the live Manager model. The code also includes a Sarvam client, and the README describes Sarvam as the primary model. Live updates: Server-Sent Events stream each task event to the dashboard. Economy: a ledger, escrow service, reputation service, and scoped per-subtask credentials, all behind the Circuit Breaker Web research: a self-hosted SearXNG search instance, with page scraping and citation tracking. Every citation must point to a page the system actually fetched. Source IDs are assigned by code, not by the model. Blockchain: Algorand. Workflow events are committed to a trust layer, and result hashes are verified against those commits. A failed verification fails the task. Payments: x402 packages for paid data purchases. These are counted in the task’s total spend. Testing: unit tests for the economy and routing, plus Playwright browser passes
Challenges we ran into
Timeouts cascaded into failures: Every model call shared one flat 45-second timeout. Slower, high-effort agents kept timing out, which triggered retries, reassignments, and more timeouts. The fix sized each timeout to the agent tier and output length, and added a task-wide deadline.
Serverless time limits: Subtasks ran one after another, which pushed real runs past the platform’s duration limit and left tasks stuck in “executing.” The fix runs independent subtasks concurrently by dependency level. Later, tasks were split into chained segments that resume from saved state.
A race condition in escrow: A cancellation running at the same moment as a new lock could leave funds locked forever. The fix re-checks cancellation right after locking and refunds if needed. Smoke tests caught it. Provider outages were counted against agents: Infrastructure failures were recorded as agent failures, which auto-demoted agents and left later tasks with no one to hire. The fix excludes provider failures from agent performance records. A deprecated model: A Gemini model name stopped working for new keys. The team switched models and re-verified the full run. A broken font: A self-referencing CSS variable made every browser fall back to a default serif font.
Accomplishments that we're proud of
The core guarantee holds in code. Money moves only through the Circuit Breaker, and failed QA means no payment. Failed work is handled instead of hidden. Steps that cannot be completed are recorded as incomplete in the report, and the task is marked “partial” rather than silently passing. Citations are checked against what was actually retrieved. A model cannot add a source to the list. The team verified a full live run with real model calls, not only fallbacks, and documented the bugs they found along the way.
What we learned
A financial guarantee should live in ordinary code. Model output is treated as untrusted, and the system’s logic does not depend on prompt wording. Timeouts and retries interact in ways that are easy to miss. A slow but working agent can look like a failing one, and retrying it makes things worse. Keeping provider failures separate from quality failures matters for fair routing. Demo-mode fallbacks have to be labeled clearly. The code marks local-fallback output and does not score it as real model work.
What's next for ThreadPool
Workflow memory and optimization reporting, which the pricing page places in the Growth tier. The reporting would compare each run’s cost and quality to a naive workflow. Bring-your-own agents: registering an HTTP endpoint with its capabilities and price, so external agents compete in the same marketplace. The About page describes this as already available. Audit export for teams, covering every ledger entry, QA review, and security event Billing once early access ends, with notice given beforehand
Built With
- algorand
- firebase
- gemini
- mongodb
- nextjs
- playwright
- postgresql
- prisma
- react
- sarvam
- shadcn
- tailwind
- three.js
- typescript
- vercel
- zod
Log in or sign up for Devpost to join the conversation.