Repository navigation
fix(snapshot): expose a skill_dir eval under its artifact_id - #1168
Merged
Merged
Conversation
`snapshot eval` kept the dest spec's name unset, so a skill_dir candidate staged at tmp/artifact was visible as `.claude/skills/artifact/` instead of `.claude/skills/<artifact_id>/`. The demo offline agent then missed the learned rules and scored 0. Staging stays on the fixed #1150 path; only the dest spec's name is set from the snapshot id. Closes #1164
Collaborator
Author
|
Self-review (Birfy) Tip SHA: 07380bd
|
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.
Closes #1164
What changed
snapshot evalstill stages askill_dircandidate under the fixed#1150pathtmp/artifact, so an unsanitizedartifact_idcannot steer the write. The destination spec'snamewas left unset, soEvolveSpec.artifact_id()fell back to that basename (artifact) andclaude_skillwrote.claude/skills/artifact/.The demo offline agent reads
.claude/skills/csv-total/references/rules.md. After a successfuldemo→snapshot export,snapshot eval --spectherefore scored0even when the snapshot already containedCOLUMN: amount.This PR sets
name=snapshot.artifact_idon the dest spec used for re-eval, so the layout prefix becomes.claude/skills/csv-total/. Staging is unchanged.Verification at the tip
Tip SHA: 07380bd
Red first, this tip's test on
origin/main(72eabc6) without thename=line:1 failed—assert recorded["name"] == DEMO_SKILL(artifactvscsv-total).Ran:
pytest -q tests/test_snapshot.py tests/test_snapshot_artifact_id.pyat this tip →37 passedpython -m tools.changelog_fragments check→ fragments OKNot run:
pytest -q— thetestsworkflow runs it on this PRdemo→snapshot export→snapshot eval --speccycle — the new test uses the demo skill,offline_agent, and the same amount-vs-id CSV shape