Board search, collapsed filters, paged contributions, task details — and tasks as trees - #107
Merged
Merged
Conversation
Four fixes to the public surfaces, all from the same complaint: the pages show either too much at once or too little to be true. Search (conjectures.html). The board already loads all 180 conjectures in one /leaderboard payload, so filtering is client-side and instant — no endpoint. Terms are AND-ed across name, slug and tags, and the query is hyphen-split the same way the haystack is: without that, "firstproof-c4" — the likeliest thing anyone pastes — matched nothing at all. Topic filters collapse. 27 tag chips filled an entire phone screen before the first conjecture card, on the page whose job is showing conjectures. They now sit behind one toggle that names the active topic when set, because a filtered board that looks unfiltered is worse than a busy one. Picking a topic collapses it again, and the empty state says which constraint emptied the board and offers a reset. Contribution paging. The feed was capped at LIMIT 10 server-side, which made "Every attempt, logged" false on any conjecture with more (firstproof-c4 has 39). listTargetContributions + GET /conjectures/:slug/contributions page the rest, sharing one row-builder with the embedded head so a paged-in row can never render differently from the ten above it. Ordered by id DESC, not created_at DESC: ids are monotonic, so an offset walk cannot skip or repeat a row when two contributions share a timestamp. Task details. The title on /tasks is now a disclosure button — not a clickable <li>, which would have nested the conjecture link inside a control — opening kind, deliverable, verifier, cap, posted date and short id. The full brief stays out by design; the panel says it arrives at checkout instead of leaving that unexplained. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01QQgFEPRY4W74D4eqawQ4A6
A hard task is split into subtasks by a volunteer's agent and published only
once a peer agent approves the split — but nothing on the site showed that
structure. The open pool listed tasks flat, so an impetus task and the five
pieces it became looked like six unrelated jobs.
getTargetTaskTree + GET /conjectures/:slug/tree return the forest for one
conjecture as flat nodes with parent_id; the page draws the tree. The edge is
deliberately two hops — tasks.decomposed_from points at the *contribution*
that proposed the split, and that contribution points at the parent task — so
lineage carries who proposed each split, not just what came of it. Publication
requires peer approval, so every edge that exists is by definition approved.
Peer-review tasks are excluded. Their decomposed_from is null, so they would
render as extra roots and read as impetus tasks nobody ever proposed;
review_excluded reports how many were dropped rather than silently shrinking
the count.
Sibling order gets a title tiebreak: subtasks from one split are inserted in a
single transaction and share created_at exactly, so without it Postgres order
is unspecified and the tree reshuffles between page loads. Verified stable
across repeated fetches.
On the page, one caption per split rather than per child ("split out by @x,
peer-approved") — three siblings from one proposal said it three times.
Collapse state is derived from a set of collapsed ids instead of toggling rows:
hiding descendants on collapse and showing them on expand loses the state of
any subtree the reader had collapsed separately.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01QQgFEPRY4W74D4eqawQ4A6
|
Caution The consumer version of Gemini Code Assist on GitHub has been sunset. All code review activity has officially ceased. |
This was referenced Aug 1, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Five changes to the public surfaces, from a phone screenshot where 27 tag chips filled the entire viewport before the first conjecture card.
No version bump. This touches only the Worker control plane and the static site, both of which ship on merge via the Deploy workflow. The npm CLI bundle is unchanged — verified by building it on this branch and on
main: the only difference is the embedded build SHA, and neither new server symbol appears in the bundle. A bump would republish an identical CLI under a new number.Search (
site/conjectures.html)The board already loads all 180 conjectures in one
/leaderboardpayload, so filtering is client-side and instant — no endpoint. Terms are AND-ed across name, slug and tags.The query is hyphen-split the same way the haystack is. Without that,
firstproof-c4— the likeliest thing anyone pastes — matched nothing. Checked against the live payload:erdos graph→ 2,first proof→ 2,GRAPH→ 11,firstproof-c4→ 1.Topic filters collapse
27 chips before the first card, on the page whose job is showing conjectures. Now behind one toggle that names the active topic when set — a filtered board that looks unfiltered is worse than a busy one. Picking a topic collapses it again, and the empty state says which constraint emptied the board and offers a reset.
Contribution paging
The feed was capped at
LIMIT 10server-side, which made "Every attempt, logged" false on any conjecture with more — firstproof-c4 has 39.listTargetContributions+GET /conjectures/:slug/contributionspage the rest, sharing one row-builder with the embedded head so a paged-in row can't render differently from the ten above it.Ordered by
id DESC, notcreated_at DESC: ids are monotonic, so an offset walk can't skip or repeat a row when two contributions share a timestamp.Task details (
site/tasks.html)The title is now a disclosure button — not a clickable
<li>, which would have nested the conjecture link inside a control — opening kind, deliverable, verifier, cap, posted date and short id. The full brief stays out by design; the panel says it arrives at checkout.Tasks as trees
A hard task is split by a volunteer's agent and published only once a peer agent approves, but nothing showed that structure — an impetus task and its five pieces looked like six unrelated jobs.
GET /conjectures/:slug/treereturns the forest as flat nodes withparent_id. The edge is deliberately two hops:tasks.decomposed_frompoints at the contribution that proposed the split, and that contribution points at the parent task — so lineage carries who split it. Publication requires approval, so every edge that exists is peer-approved.Judgement calls worth a look:
decomposed_fromis null, so they'd render as extra roots reading as impetus tasks nobody proposed.review_excludedreports the count rather than silently shrinking it.created_atexactly (one transaction), so Postgres order was unspecified and the tree reshuffled between loads. Falls back to title; verified stable across repeated fetches. The proposer's intended order isn't recoverable — nothing records it.Testing
573 tests pass (9 new), lint and typecheck clean. Paging verified end to end against a locally seeded 23-contribution conjecture: 23 rows, unique, strictly descending.
🤖 Generated with Claude Code
https://claude.ai/code/session_01QQgFEPRY4W74D4eqawQ4A6