-
-
What the checker caught: F3 claimed a MAX_DELAY cap, and the two reasons it was rejected and sent back.
-
The evidence for F1: src/scheduler.ts lines 13 to 21 highlighted, with the quoted text marked.
-
The app mid-run on issue #41: the trace fills in, and the checker has just rejected claim F3.
-
The landing page's limits: it proves where a claim comes from, not that its reasoning is right.
-
The finished triage note for #41: kind, labels, and the first findings, each marked Checked with its cited lines.
-
The landing page: the headline, and the product running sample issue #41 in the painted hero panel.
The story
Say you maintain a small open source library, and forty new issues came in this week. A triage bot writes a confident note: the bug is in this function, this duplicates issue 27. You cannot tell which parts are true, so you check every line by hand, and the bot saved you nothing. Triage Desk does not ask you to trust the note: every claim shows its evidence, and claims that fail are thrown out before you read them. Each claim carries a quote and a location, and a deterministic checker that no model call can overrule removes any claim whose cited lines do not contain what it says. The draft reply is held to the same rule. In the scripted demo, the model claims a MAX_DELAY cap that does not exist; the checker rejects it with the reason, and the corrected claim passes. The limit: the checker proves where a claim comes from, not that its reasoning is right, and no real model run is shown. Next busy evening, you read only claims that already showed their evidence.
Try it in one minute
Open https://bananatruck.github.io/triage-desk/app/ and press Run triage with "Scripted sample" and issue #41 selected. Watch the trace fill in, then click any evidence button in the note (for example src/scheduler.ts:13-21) to see the cited lines with the quote highlighted. The scripted sample needs no key and calls no model: its model replies were written by hand and are replayed through the real pipeline, and the app says so on every screen. The repository it triages, ferryq, and all of its issues are synthetic, written for this project. No live model run is shown anywhere in this submission, including the video and the screenshots.
Inspiration
Maintainers of small open source projects get more issues than they can read carefully. AI triage bots help with volume, but they write confident notes ("this is caused by X in file Y", "duplicate of #12") that a maintainer has to re-check by hand, which defeats the point. We wanted a triage agent whose every statement can be checked in one click, and which throws away statements that do not check out before a human ever sees them.
What it does
Given a new issue and a snapshot of the repository (its files, earlier issues and label set), Triage Desk runs a small pipeline of agent steps:
- Classify: kind (bug, feature, question, docs), component, a one-sentence summary and search terms.
- Investigate: the model calls four tools (
search_code,read_file,search_issues,get_issue) and reports findings as claims, each with evidence: file lines plus a quote, or an earlier issue plus a quote. - Check: a deterministic checker rejects any claim whose quote is not at the cited place, or that mentions a code identifier, number, file path or issue number that its evidence does not contain. Rejections go back to the model with the exact reasons, once; claims still wrong are dropped and listed.
- Duplicates: BM25 retrieval picks up to three earlier issues; the model judges each as duplicate, related or unrelated, with a claim quoting that issue, checked the same way.
- Draft: labels from the repository's own label set, and a first reply that may cite only verified claims. A reply checker rejects any code name, number, line, file path or issue number in the reply that the claims it cites do not back; a reply that still fails after one revision is marked "Do not post as is".
The result is a triage note where every claim has a "checked" badge and opens its evidence: the cited lines with the quote highlighted, or the earlier issue. The whole run is a trace (every model call, retry, rate-limit wait, schema rejection, tool call and result, checker verdict) that the app shows live, steps through, replays, and saves as JSON. The same pipeline runs from the command line, and a snapshot command builds a snapshot of your own repository from a local checkout and gh issue list output, which the command line or the web app can then triage live with your own key.
How we built it
- TypeScript, no runtime dependencies. A static web app (Vite, no framework) on GitHub Pages, and a command line that runs the TypeScript sources directly on Node 22.
- One narrow model interface.
ModelClient.complete()has two implementations: an OpenAI-compatible chat completions client that uses the user's own key, and a scripted client that replays hand-written replies and refuses to run out of order, so a sample cannot drift from the pipeline unnoticed. - Typed step contracts. A small runtime schema validator with static types checks every model reply and every tool argument. Invalid replies go back with path-precise errors (for example
result.kind: expected one of bug, feature, question, docs, other, got "defect"), at most twice, then the run fails with a typed error the UI shows. - Failure handling. HTTP 429 waits exactly the
Retry-Aftertime; 5xx, network errors and timeouts back off exponentially with jitter; a refused key is never retried. A client-side rate gate, a per-run model-call budget, a per-request timeout and cancellation bound every run. Tool errors (an unknown file, a range past the end) go back to the model as results it can act on. - Retrieval. BM25 over overlapping 24-line windows of every file and over earlier issues, with identifiers split on camelCase and snake_case.
- Prompt injection. Issue text and tool results are fenced as data. A model steered by a hostile issue still cannot cite a quote, file, line, identifier, number or issue that is not there; it can still draw a wrong conclusion from a correct quote, which the checker does not catch.
- Tests. 160 Vitest tests in 15 files cover the validator, retrieval, every tool, every checker rule, retries with a fake clock, the rate gate, the step runner, all three scripted samples end to end, a live run against a fake endpoint (including a check that the key never appears in the trace or note), the note, saved runs, the command line, the static server used by the smoke test, and the clock that paces the landing page's walkthrough. A browser smoke test drives the production build in Chromium at 1440 and 390 pixels wide (68 checks: the landing page's walkthrough, its pause control and its reduced-motion still, a keyboard-only run, evidence dialog and focus return, the status announcement of a rejected claim, live mode against a fake endpoint, loading a snapshot). GitHub Actions runs lint, type-check, tests, build and the smoke test on every push.
How it was made: Triage Desk was built by AI coding agents directed by the author, all of it inside the Dec 1 to Dec 7 sprint window; the first commit is from 2026-12-01 and no code existed before it.
Against the judging criteria
Every figure below comes from this repository and can be re-run.
- Technical architecture and engineering depth. A pipeline of four model steps with a deterministic checker between each step and the next, a typed schema for every reply and tool argument, retries that honour
Retry-After, a client-side rate gate, a per-run call budget, a timeout and cancellation. The checker, schema validator, BM25 retrieval and retry logic are written here with no runtime dependencies. 160 Vitest tests in 15 files and a 68-check browser smoke test pass on every push in GitHub Actions. - Innovation and originality. The agent's output is not trusted as text: every claim carries a quote and a location, and a checker that no model call can overrule removes claims whose evidence does not contain what they say. The draft reply is held to the same rule: every code name, number, line, file path and issue number in it must come from a claim it cites. Rejections go back to the model with the exact reasons, and the whole exchange is visible in the trace.
- Real-world utility and scalability. A
snapshotcommand builds a snapshot of any local checkout plusgh issue listoutput, which the command line or the web app can triage with the user's own key for any OpenAI-compatible endpoint. Measured once on a 2-core Intel Xeon at 2.30 GHz with Node 22: indexing a synthetic snapshot of 2,000 files of 150 lines (31.2 MB) took 3.8 s, a code search over it 81 ms, and an issue search over 5,000 issues 4 ms. The app never posts anything; a maintainer reads the note and decides. - Execution and demo clarity. The live site runs the scripted sample with no key in one click, labelled as hand-written replies on every screen. The video shows a real production build: a rate limit waited out, a schema rejection, a checker rejection corrected, and a reply rejected and rewritten.
Challenges we ran into
- Making the checker strict enough to catch invented details without rejecting honest claims. It checks the quote location and the identifiers, numbers, paths and issue numbers a claim mentions; it deliberately does not judge reasoning, and the note says "checked", not "true".
- Keeping the scripted sample honest. Its replies are labelled as hand-written everywhere, faults it raises are labelled as scripted, and the tests pin every verdict so a change in the sample repository that breaks a citation fails CI.
- Feedback loops that end. Every turn of a step either finishes, spends a tool call or spends an invalid reply, so every run terminates within a stated budget.
Accomplishments that we're proud of
- The demo shows a model's invented claim (a
MAX_DELAYcap that does not exist) rejected by the checker with a precise reason, sent back, and replaced by a claim that passes, all visible in the trace. - Zero runtime dependencies: the schema validator, BM25, retries, rate gate and checker are a few hundred lines each, with tests.
What we learned
Checking where a claim comes from is cheap, deterministic and catches a lot; checking whether the claim follows is a different, harder problem, and it is better to say so plainly than to imply it.
What's next
- A measured evaluation with real models on real repositories: how many claims the checker rejects, and how many of those were really wrong.
- Fetching a repository snapshot straight from GitHub, and posting the note as a draft comment after a human approves it.
- An entailment check for the reply's prose, clearly marked as a model judgement rather than a deterministic check.
Limits
- The checker proves location, not reasoning. A claim that quotes the right line and draws the wrong conclusion in plain words passes.
- The draft reply is checked for what it names (code names, numbers, lines, paths, issue numbers), not for what its plain words say; it must be read before posting. The app never posts anything.
- Live mode is tested only against fake endpoints; it has not been run against a real provider by this project, and prompt quality with real models is unmeasured.
- Snapshots are held in memory (up to 2,000 text files of up to 200 KB each); retrieval is BM25 only.
Built With
- ai-agents
- bm25
- github
- github-actions
- llm
- node.js
- playwright
- typescript
- vite
- vitest