Repository navigation
answers-draft: model-drafted answers files, promote flow, five promoted sources - #8
Merged
Merged
Conversation
…tained claude CLI, promote flow, expects for weather/current and water/tides, five promoted sources sourcetool answers-draft writes a draft answers file from a live sample with every path and type verified on every row before it is written (draft_meta records tool, model, is_local=false, prompt sha); answers-promote moves a reviewed draft into answers/. Promoted: nhl-club-schedule, openf1-sessions, nvd-cves-keyword, fdc-food-search, sec-companyfacts; three drafts held, nine spec-gap rejections and the review notes under answers/_drafts; weekly job installs the app parsers' dependencies.
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.
Round 19, Phase 2a (rest): the drafting half of the authoring loop, plus the first expectations and five new answered sources. Follows #7.
What changes
sourcetool answers-draft ID ... [--model sonnet|opus|haiku] [--force]— the operator'sclaudeCLI drafts an answers file for a curated source from its live sample; code decides whether it is right. The prompt holds the closed answers spec (rendered from the module constants), the record, its subcategory's keywords and expected components, and a bounded structural sketch of the sample fenced as untrusted data; it never includes a labeled, held-out or sealed ask set. The reply is parsed as JSON and run through the same validators as a hand-written file (answer_problems,check_sampleon every row, the kind-served lints), plus two drafting rules the data tests enforce (every value answer declares its window; noutcflag on a path whose values carry a zone). One retry carries the problems back. A passing draft lands inanswers/_drafts/<id>.jsonwithdraft_meta {tool, model, is_local: false, prompt_sha, date}; a failing one in<id>.rejected.jsonwith the problems. Nothing under_drafts/is served.sourcetool answers-promote ID ...re-verifies a draft against a fresh live sample and moves it intoanswers/.sourcetool/claudecli.pymirrors the app's containment for one stateless completion: empty-toolset agent,--setting-sources "",--strict-mcp-config,--no-session-persistence, content over stdin with heading-forgery quoting, private 0700 working directory, no ANTHROPIC_* keys in the environment, process-group kill at 300 s. Publisher-side only;is_localis false in every draft._lacksalready recognises): weather/current[temperature, conditions], water/tides[tide, start_time].cryptographyandnumpy; both are now installed (found by running the drafter against the CSV sources).The first drafting round (18 keyless sources without answers)
Every draft was read by eye against the live sample; the validator proves paths and types, never ordering or window semantics (two passing drafts were wrong by ordering and were corrected by hand). Notes in
answers/_drafts/REVIEW.md, skips inanswers/_skipped.md.-.19, padded cells and units rows, US dates, split year/month columns, positional pair rows, id-only results, keys with spaces, text products. Listed in REVIEW.md as spec v1.3 candidates; each needs the app's engine to agree first.Verified
sourcetool checkclean;answers-check --lint0 problems (the keyword baseline shrank 474 → 471: the promoted files speak to three more keywords); 265 tests (10 new for drafting, promotion, the sketch, the prompt's inputs, the CLI event parser and command shape, draft_meta validation); the five promoted files passed a fresh live check at promotion.