skillopt-sleep: harvest checkpoint is keyed by project, so a second --source in the same project skips its unseen sessions
维护者通常 2 天内回复
还没有人认领这个 Issue。
评估
调研方向
Read cycle.py and the state methods last_harvest_for and set_last_harvest, then trace how the selected transcript source reaches the harvest call. The issue names both checkpoint write branches: the no-tasks branch and the normal end of a stateful run. Update checkpoint handling so each source retains its own cursor while existing state can still be read; reproduce with the mock backend and confirm the second codex dry-run finds its previously unseen sessions.
由索引模型根据 Issue 内容生成。
描述
What happens
skillopt-sleep run stores one harvest checkpoint per project, whatever --source the run used. cycle.py reads state.last_harvest_for(project) before harvesting and calls state.set_last_harvest(project, started) after every stateful run (both the no-tasks branch and the normal end). So when one project is fed from several transcript sources, one night per source, every source after the first only sees sessions newer than the first run's start: its older, never-harvested sessions are skipped for good. Each source is a separate store with its own timestamps, so a single shared cursor cannot be right for all of them.
Repro (mock backend, isolated state, no model calls)
Version: main at 343db229dbd5ddaf9df6b1d5540d8bcdb2604d5c, installed with uv tool install "skillopt @ git+https://github.com/microsoft/SkillOpt", Python 3.14, macOS. --claude-home points the state at a scratch dir; P is an empty scratch project.
T=$(mktemp -d); mkdir -p $T/.claude $T/proj
common="--project $T/proj --scope all --backend mock --claude-home $T/.claude --progress"
skillopt-sleep dry-run $common --source codex # harvest done: sessions=60
skillopt-sleep run $common --source cursor # stateful; sets last_harvest[$T/proj]
skillopt-sleep dry-run $common --source codex # harvest done: sessions=0
(Our Codex sessions are CLI rollouts, so we pass --codex-home pointing at a dir whose archived_sessions/ symlinks ~/.codex/sessions/**/rollout-*.jsonl; see #282.)
The second codex dry-run harvests nothing although no codex session was ever harvested: it inherited the cursor run's checkpoint.
Expected
Each source keeps its own checkpoint.
Suggested fix
Key last_harvest by f"{project}::{transcript_source}" and fall back to the bare project key when reading existing state, or accept several --source values in one run so one checkpoint covers them together.
Workaround we use
A wrapper keeps one cursor per source in its own file and writes it into state.json before each per-source run.
- 主要语言
- Python
- 星标
- 18.2k
- 派生
- 1.7k
- 平均合并
- 4 天 1 小时
- 30 天内合并 PR
- 10
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 没有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
microsoft/SkillOpt 的其他 Issue
-
难度 4/5 3-5 天 新手友好度 25/100
维护者通常 2 天内回复
-
Clarification on Rollout Timeouts, Inference Concurrency, and Their Impact on SkillOpt Evaluation未关闭
难度 4/5 3-5 天 新手友好度 12/100
维护者通常 2 天内回复
-
难度 5/5 一周以上 新手友好度 32/100
维护者通常 2 天内回复
-
skillopt-sleep: max_tokens_per_night is defaulted and documented but never enforced可能已有人在做 @Thanatos9404 今天认领。 未关闭
难度 4/5 3-5 天 新手友好度 55/100
维护者通常 2 天内回复
-
Same unconfined `predictions/<item_id>` path pattern remains in four benchmark rollouts可能已有人在做 @adongwanai 于 7 天前认领。 未关闭
难度 3/5 1-2 天 新手友好度 72/100
维护者通常 2 天内回复
查看 microsoft/SkillOpt 的全部 Issue
相似的 Issue
-
approved Good First Issue scope: docs
难度 1/5 1 小时以内 新手友好度 85/100
hiero-ledger/hiero-sdk-python#2730 · 3 条评论 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 62/100
wemake-services/wemake-django-template#3178 · 1 个 reaction ·
维护者通常 1 天内回复
-
md/asciidoc/csv: an explicit `encoding="utf-8"` keeps a leading BOM, the auto-detect path drops it未关闭
难度 2/5 1-3 小时 新手友好度 82/100
docling-project/docling#4846 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 78/100
neurostuff/NiMARE#1181 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 78/100
pytest-dev/pytest#15180 ·
维护者通常 1 天内回复