Skip to content

Skip households with no applicable outputs; tighten program-note tests - #311

Draft
MaxGhenis wants to merge 3 commits into
mainfrom
lane/evaluator-empty-households
Draft

MaxGhenis wants to merge 3 commits into
mainfrom
lane/evaluator-empty-households

Conversation

@MaxGhenis

@MaxGhenis MaxGhenis commented Dec 3, 2026 •

Copy link
Copy Markdown
Contributor

Fixes #286, #306 and #284.

New test: test_run_no_tools_eval_skips_households_without_applicable_outputs.

A Codex lane (GPT-6.2 Sol) wrote the patch, and Claude read it against main before applying it. Claude dropped one test from the lane's patch, which regex-matched the #284 comment's wording. The tests were not run locally; CI runs pytest -m "not slow" and the app's bun test. ruff check and ruff format --check pass on the changed Python files.

🤖 Generated with Claude Code

- The synchronous evaluator skips a household whose requested outputs
  expand to nothing, instead of sending an empty list that the JSON
  prompt builder fails on (#286).
- The Failure Modes tests check all three summary-only notes render
  outside the disclosure, and that the mixed fixture's notes carry a
  federal bullet and no TANF note (#306).
- hardestCases' doc comment says unparsed answers count only on
  positive-dollar references (#284; comment only).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@vercel

vercel Bot commented Dec 3, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
policybench-site Ready Ready Preview Dec 3, 2026 5:25am UTC

Request Review

run_no_tools_eval now counts progress against the model-household pairs
that have at least one applicable output, and counts resumed checkpoint
rows only when they belong to that set. A run that finishes its
applicable work prints a final 100% line, including a resume that loads
every pair from the checkpoint.

The Head Start regression checks the worker's arguments, the final
progress line on a fresh and a resumed run, and that stale checkpoint
rows for a skipped household or another model do not inflate the count.
The hardestCases comment says positive reference amounts, which covers
pounds as well as dollars.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This PR skips households with no applicable outputs, so the first API
request now goes to the first household that has some. Round 2 found
that the resume sidecar still took its initial completion budget from
the first household in the manifest, which records the budget of a
request that is never sent. The sidecar now records the budget for the
first household with applicable outputs, or null when no household has
any. The full manifest stays in the resume identity.

Sidecars written before this change recorded the empty-request budget
when the first household had no outputs. _validate_resume_metadata
accepts such a sidecar when treatment is the only mismatch, the first
household has no applicable outputs, and the stored treatment equals the
legacy computation, so existing runs still resume.

The Head Start test now stubs resolve_policyengine_bundles so it no
longer depends on installed PolicyEngine packages. A new parametrized
test covers the budget with and without an applicable household, a
changed repair cap, and a resume that rewrites the budget.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

This branch was successfully deployed

1 active deployment
Preview — 9999a51e Deployed Dec 3, 2026 by vercel[bot]
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.

Tighten two Failure Modes program-note tests Skip households with no applicable outputs in the synchronous evaluator

1 participant