Skip to content

fix: preserve requested rate calculation and output columns - #330

Draft
seyoung4503 wants to merge 2 commits into
fix/sql-selected-summaryfrom
fix/sql-rate-projection
Draft

seyoung4503 wants to merge 2 commits into
fix/sql-selected-summaryfrom
fix/sql-rate-projection

Conversation

@seyoung4503

@seyoung4503 seyoung4503 commented Nov 26, 2026 •

Copy link
Copy Markdown
Collaborator

Two completed failed cases show distinct output-contract failures: a stored rate differs from the requested count ratio by floating-point rounding, and an otherwise correct one-measure result includes an extra label column. The official comparator remains unchanged.

Strengthen two existing shared rules: calculate a requested rate from matching source counts unless a stored measure is explicitly selected; project only requested measures when entity selection does not itself request labels. Preserve identifiers for explicit entity/detail reports. No schema names, expected outputs, question IDs or automatic SQL replacements are introduced into the product.

Validation: 260 root tests passed, 1 skipped; diff clean. Ruff passes with the existing BLE001 in the untouched enrichment exception handler excluded. Fresh Codex MCP runs on only bird000 and bird002 completed (gpt-6.2-sol/high, ChatGPT login): 2/2 repaired under the unchanged official scorer. Both queries now compute the requested ratio from source counts; bird002 projects only the requested measure. Full MCP traces, final answers, manifests, settings, scores and source hashes are committed under bench/accuracy/mcp-review-results/rate-projection-30f20bd. Gold and grade feedback do not enter prompts. The larger previous-failure run remains immutable at revision 7aadca6. No full accuracy claim. Stacked on #329; targeted repair results are available; full-set accuracy remains unverified and no causal isolation from stochastic variation is claimed.

Reuse: existing BASE_INSTRUCTIONS -> MCP and internal harness; two existing rules replaced, net zero lines, no new function.

Principle Result Evidence
Reuse O Shared prompt and existing benchmark runner
Cause O Stored-rate float drift; extra projected label
Logging/errors N/A Runtime paths unchanged
Environment/configuration N/A No new values
Comments O No issue-number comments
Verification O 260 passed, 1 skipped; baseline lint exception disclosed
Authorization O Draft PR only
Call path O Shared instruction -> MCP initialization -> SQL generation
Sync/async N/A No new I/O

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant