Repository navigation
perf(count): drive scoped counts from the assignee/priority cohort - #218
Merged
Merged
Conversation
sd count --assignee X --priority P put both filters in OPTIONAL + FILTER after the work-item type triple. Quipu evaluates a pattern that holds a type triple in written order, so every count scanned every seed before narrowing: on a copy of the live board, sd count --assignee franklin --priority 1 --by status took ~4.5s per query and two queries, and was killed at 5s (aegis-efa, blocking the burn-down in aegis-7mm). An explicit assignee and a single non-default priority are now required triples placed before the type triple. Each is equivalent to the form it replaces: the FILTER already rejected rows without the value, and the default priority 2 keeps the old form. Other filters and callers are unchanged; filter_fields still returns the same constraints. Refs aegis-efa Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_014TTLDAEqq5Whc7qUZsJMUM
… snapshot Refs aegis-efa Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_014TTLDAEqq5Whc7qUZsJMUM
Refs aegis-efa Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_014TTLDAEqq5Whc7qUZsJMUM
Merged
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.
Summary
sd count --assignee X --priority Pput both filters inOPTIONAL { … } FILTER(…)after the work-item type triple. Quipu evaluates a pattern that holds a type triple in written order, so every scoped count scanned every seed before narrowing to the cohort. On a copy of the live board,sd count --assignee franklin --priority 1 --by statussends two such queries and took about 10.7s; the live command is killed at 5s, which blocks the burn-down that needs this count.--assigneebecomesVALUES ?assignee { <principal/X> "X" } ?s <agent> ?assignee, and a single non-default--prioritybecomes a required constant triple. Both go before the type triple, in all four branches (main/ephemeral, with/without a stored status).FILTERalready rejected rows without the value, andVALUESkeeps both stored assignee forms. The default priority 2 (applied to seeds without one), priority ranges and--unassignedkeep the old form.countuses the leading position;filter_fieldsstill returns the same constraints for every other caller.Evidence
On a restored copy of the live board, through a loopback read-only
quipu-server0.16.6:sd count --assignee franklin --priority 1 --by status: 20/20 runs, p50 0.19s, p95 0.30s (before: 10.7s uncapped; killed at 5s live).--by status}) against sd 0.10.0: 35 byte-identical; the other is a count that sd 0.10.0 could not finish inside the server's 10s limit (now 49, matching its own by-status breakdown). Every count is faster; the heaviest went from 10.1s to 3.5s.--assigneewith--unassigned, priority ranges) pass with this change and on unchanged main.cargo fmt --check,cargo clippy --all-targets -- -D warningsand a release build pass.Demo: no recording — the observable change is query latency with identical output; the before/after timings and the differential above are the evidence.
Refs aegis-efa.
🤖 Generated with Claude Code
https://claude.ai/code/session_014TTLDAEqq5Whc7qUZsJMUM
Bead: aegis-efa
Overlap preflight: dc9b3e3e3ad91177897f733dc6ecadf673b4d4237d3c1a4ff0da51985a2f4df2