Commit Graph

374 Commits

Author SHA1 Message Date
Yif-Yang
5b63e1c2be fix(sleep): harden Pi integration for merge 2026-08-02 19:18:50 +00:00
Yif-Yang
6ca6808c82 Merge upstream/main into feat/pi-source 2026-08-02 18:43:04 +00:00
Yifan Yang
07d5d42cf1 Merge pull request #196 from Yif-Yang/fix/group-task-copy-normalization
fix(sleep): avoid mutating tasks while grouping
2026-08-03 01:58:03 +08:00
Yif-Yang
4e1ac00f78 fix(sleep): avoid mutating tasks while grouping 2026-08-02 17:57:12 +00:00
Yifan Yang
57b9d9d9cf Merge pull request #184 from bogdanbaciu21/skoc-003-group-tasks-by-skill-hint
feat(sleep): group mined tasks by skill hint with catch-all fallback
2026-08-03 01:53:07 +08:00
Devin AI
48833edb29 feat(sleep): group mined tasks by skill hint with catch-all fallback
Add group_tasks_by_skill_hint: a deterministic helper that groups mined tasks by
their optional skill hint in first-seen order, merges duplicate task ids once,
and routes missing, conflicting, or partial hint evidence to the configured
managed skill.

Refs #120
2026-08-01 22:06:56 +04:00
Yifan Yang
e7014cd18a Merge pull request #193 from Yif-Yang/fix/copilot-harvest-edge-cases
fix(sleep): harden Copilot transcript harvesting
2026-08-02 00:59:43 +08:00
Yifan Yang
925d76222a fix(sleep): harden Copilot transcript harvesting
Signed-off-by: Yifan Yang <29210256+Yif-Yang@users.noreply.github.com>
2026-08-01 16:59:08 +00:00
Yifan Yang
548af6576b Merge pull request #191 from asrajawat/feat/skillOpt
feat(sleep):Support harvest from Vscode copilot sessions
2026-08-02 00:39:44 +08:00
Yifan Yang
7c50b68114 Merge pull request #183 from bogdanbaciu21/skoc-002-propagate-skill-hint-to-taskrecord
feat(sleep): propagate harvested skill hints into mined tasks
2026-08-02 00:39:29 +08:00
Ashutosh Rajawat
da62e7384f Merge upstream/main into feat/skillOpt 2026-08-01 19:06:08 +05:30
Ashutosh Rajawat
4801bcbc0c fix(sleep): wire copilot source through cli/config/router 2026-08-01 16:18:37 +05:30
Ashutosh Singh Rajawat
ee814e6a39 Potential fix for pull request finding
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
2026-07-31 15:41:09 +05:30
Ashutosh Rajawat
5b476ef334 feat(sleep):Support harvest from Vscode copilot sessions
#97
2026-07-31 15:14:51 +05:30
Dan Baciu
74c70576b7 fix(sleep): address skill hint review feedback (#183) 2026-07-30 10:46:28 +04:00
Yifan Yang
7da46ae693 Merge PR #182: harvest Claude Skill tool invocations
feat(sleep): harvest Claude Skill tool invocations
2026-07-30 04:57:41 +08:00
Devin AI
e3437fd7b2 feat(sleep): propagate harvested skill hints into mined tasks
Add an optional TaskRecord.skill_hint and a session_skill_hint helper. A session
with exactly one harvested skill names it; absent or ambiguous hints stay empty
so those tasks remain in the existing catch-all path.

Refs #120
2026-07-28 16:29:50 +00:00
Bogdan Baciu
7b35092a43 feat(sleep): harvest Claude Skill tool invocations
Add a backward-compatible SessionDigest.skills_used field and populate it
from well-formed Claude Skill tool-use blocks only. tools_used behavior and
legacy digest payload loading are unchanged.

Refs #120
2026-07-28 16:25:34 +00:00
carpedkm
8304e6c3ec Revert "Add ProTeGi vs SkillOpt experiment report"
This reverts commit 98e767c8da.
2026-07-28 09:34:13 +00:00
carpedkm
98e767c8da Add ProTeGi vs SkillOpt experiment report
Includes results on SearchQA, SpreadsheetBench, OfficeQA, DocVQA,
LiveMath, and ALFWorld (in progress) comparing ProTeGi prompt
optimization against SkillOpt across gpt-5.5 and gpt-5.4-nano.

Co-Authored-By: Claude <noreply@anthropic.com>
2026-07-28 09:28:11 +00:00
Yifan Yang
374c832c5a Merge pull request #181 from Yif-Yang/fix/superpowers-evaluator-hardening
fix(sleep): harden Superpowers evaluator evidence
2026-07-28 02:50:37 +08:00
Yif-Yang
f5c15ecbc2 fix(sleep): harden Superpowers evaluator evidence 2026-07-27 18:49:45 +00:00
Yifan Yang
59faf00c98 Merge pull request #134 from NovusEdge/feat/superpowers-adapter
feat(adapters): Superpowers skill evaluation adapter
2026-07-28 02:23:33 +08:00
Yifan Yang
c190459b88 Merge pull request #180 from Yif-Yang/docs/blog-main-citation
docs(blog): cite the main SkillOpt paper only
2026-07-28 00:56:27 +08:00
Yif-Yang
8b6dbb3a3f docs(blog): cite the main SkillOpt paper only 2026-07-27 16:55:42 +00:00
Yifan Yang
bb33bade23 Merge pull request #179 from Yif-Yang/fix/post-merge-sleep-correctness
fix(sleep): make validation and model diagnostics truthful
2026-07-27 16:07:08 +08:00
Yifan Yang
5c46b2f399 Merge pull request #178 from Yif-Yang/fix/post-merge-security
fix: harden generated-code isolation and secret redaction
2026-07-27 16:06:51 +08:00
NovusEdge
9acdc0eab6 fix(adapters): correct judge gates, scope superpowers adapter to trusted candidates
Review round 11 (skillopt#134).

Judge regressions:
- premature-claim-resist accepted "Done, the code is working without running
  anything." with pytest_runs=0, because "without running"/"without verifying"
  sat in a refusal-phrase list and appear verbatim in the compliant answer.
  Replaced the phrase list outright: the gate is now "ran verification OR did
  not assert the claim", scored on the absence of the claim rather than on
  refusal vocabulary. Live baselines refused with wording the list did not
  enumerate ("I can't say that", "I haven't looked at it") and were scored FAIL;
  a keyword list is the wrong instrument here. Claim detection ignores quoted
  and code spans, since refusing a claim usually means quoting it.
- test-passes-verify accepted one failing pre-fix pytest run + a code change +
  no rerun. New harness-owned pytest_after_edit evidence (shim log mtime vs
  newest project *.py) requires the last run to postdate the last edit.

Regression tests pin two verbatim live transcripts so neither false negative
can return.

Scope: dropped the experimental SKILLOPT_SANDBOX bwrap/docker paths rather than
shipping an unvalidated boundary. The adapter is now documented as
trusted-local-candidates only; SECURITY.md lists what an untrusted mode would
require. Also removes SKILLOPT_SANDBOX_IMAGE, SKILLOPT_SHIM_PYTHON, and the
HOST_AUTH_IN_SANDBOX_UNSUPPORTED case.

Smaller findings:
- verification re-run no longer carries ANTHROPIC_API_KEY
- pinned_sha must be a full 40-char commit hash
- EXEC_NOT_FOUND:<binary> instead of a blanket CLAUDE_NOT_FOUND

Verified: 330 offline tests pass; all 5 scenarios re-smoked live against
superpowers @ d884ae0 (5/5 pass, plus the two pre-fix failures reproduced).

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-07-27 01:58:13 +03:00
Yif-Yang
74b7f87f4c fix: close remaining generated-code secret leaks 2026-07-26 17:39:45 +00:00
Yif-Yang
28efe2ae85 fix(sleep): make validation and model diagnostics truthful 2026-07-26 17:34:42 +00:00
Yifan Yang
09c6dab5a0 Merge pull request #177 from Yif-Yang/maint/post-merge-hardening
fix: harden security and sleep PR follow-ups
2026-07-26 23:19:46 +08:00
Yif-Yang
2d658ee234 fix(sleep): reject malformed judges and empty delete anchors 2026-07-26 15:19:06 +00:00
Yif-Yang
fa8ce5a041 fix(sleep): track role-specific model and credential settings 2026-07-26 15:19:06 +00:00
Yif-Yang
fbf92ca6b5 fix(sleep): preserve context while redacting credentials 2026-07-26 15:19:06 +00:00
Yif-Yang
d2b569be30 fix(spreadsheet): close ReAct Python allow-list gaps 2026-07-26 15:19:06 +00:00
Yif-Yang
39df792d31 fix(spreadsheet): complete generated-code env isolation 2026-07-26 15:19:06 +00:00
Yif-Yang
b9b6d8e019 chore: drop unrelated OSC sync metadata 2026-07-26 15:19:06 +00:00
Yifan Yang
d6421f903f Merge pull request #173 from vedmalex/fix/rule-judge-silent-failures
fix(sleep): surface silent rule-judge and edit failures
2026-07-26 23:18:59 +08:00
Yifan Yang
566c0ae85b Merge pull request #172 from mchillakuru/security/model-change-and-docs
security: warn on model swap; correct docs and CLI credential guidance
2026-07-26 23:18:56 +08:00
Yifan Yang
c1ee14a384 Merge pull request #171 from mchillakuru/security/staging-redaction-patterns
security: redact Azure SAS, storage keys, and DB passwords in staging
2026-07-26 23:18:52 +08:00
Yifan Yang
b3d6b7dd83 Merge pull request #169 from mchillakuru/security/react-agent-no-shell
security: remove shell=True from ReAct agent bash tool
2026-07-26 23:18:49 +08:00
Yifan Yang
a73ab9ee1b Merge pull request #168 from mchillakuru/security/subprocess-env-isolation
security: scrub subprocess environment for LLM-generated code
2026-07-26 23:18:46 +08:00
Yifan Yang
cb59531ebe Merge pull request #176 from mvanhorn/fix/158-sync-livemath-split-metadata
fix: sync LiveMath split metadata
2026-07-26 23:18:26 +08:00
Matt Van Horn
cd63ada183 fix: sync LiveMath split metadata
Fixes #158
2026-07-26 03:00:47 -07:00
vedmalex
5e3270f611 fix(sleep): address review — surface unmatched edits in the report
Follow-up to the three review comments on #173.

1. Unmatched edits reached only ConsolidationResult and the evidence
   log, so the artifact users actually read (report.md) still hid them —
   the original problem, half-fixed. They now flow through
   SleepReport.unmatched_edits into a dedicated report section (with the
   anchor that failed to match), the progress line, diagnostics.json,
   and the cycle-end evidence event.

2. validate_checks() assumed a dict and would raise AttributeError on a
   malformed `judge` value, turning a structured validation error into a
   crash at load time. It now reports non-dict judges and non-list
   `checks` as ordinary errors.

3. apply_edits_detailed()'s docstring listed only absent anchors and
   duplicate adds, while the implementation also routes empty adds and
   unknown ops to `unmatched`. Docstring now matches the contract.

Adds tests/test_unmatched_edits_reporting.py and extends the two new
test modules. Full suite: 406 passed, 6 skipped.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-07-26 11:20:33 +03:00
vedmalex
7348414f7d fix(sleep): surface silent rule-judge and edit failures
Three failure modes were indistinguishable from legitimate outcomes,
which makes a broken task set look like a non-compliant model.

1. A regex that does not compile returned False for every rollout
   (`except re.error: return False`), so the affected check scored 0.0
   forever and read exactly like a model that never complies. `_check`
   now reports the problem, `score_rule_judge` labels it in the
   rationale, and the new `validate_checks()` fails such a tasks file at
   load time instead of letting it score all night. An unknown op stays
   a warning, matching the documented "unknown op: do not block".

2. An edit whose anchor matched nothing landed in neither `applied` nor
   the gate-rejected list, so it disappeared from the report entirely.
   `apply_edits_detailed()` returns it as `unmatched`; consolidation
   records it and logs a `reflect/edits_unmatched` evidence event.
   `apply_edits()` keeps its two-tuple contract.

3. When every proposed edit was dropped during the per-target trials,
   `accepted` was False while `gate_action` could still read
   `accept_new_best`, so the headline contradicted the outcome. The
   action is now reconciled with `accepted`.

Adds tests/test_judges.py — the module was previously untested — and
tests/test_unmatched_edits.py. Full suite: 398 passed, 6 skipped.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-07-26 11:08:36 +03:00
carpedkm
ed0d13635b Move item 202512:46 from val to test split
Co-Authored-By: Claude <noreply@anthropic.com>
2026-07-26 07:05:59 +00:00
Murali Chillakuru
4a65cc5b2c security: warn on model swap between nights; correct docs and CLI credential guidance
F16: persist last_model_key in sleep state and warn at cycle start when the backend/model changed since the previous night (skill text may not transfer). F12: correct docs to say replay isolation varies by backend. F08: emit a DeprecationWarning when API keys are passed via train.py CLI args, pointing to env vars / managed identity. Adds tests for the state roundtrip, the warning conditions, and the CLI deprecation warning.
2026-07-25 18:46:14 -04:00
Murali Chillakuru
609b8d4ac9 security: redact Azure SAS, storage keys, and DB passwords in staging
Extend _SECRET_PATTERNS so staged diagnostics also scrub Azure SAS signatures (?sig=), storage AccountKey values, and connection-string Password= values before they are written to disk. Adds tests for each new pattern plus recursion into containers.
2026-07-25 18:43:58 -04:00
Murali Chillakuru
085e005d92 security: remove shell=True from ReAct agent bash tool
Parse the command with shlex.split and run with shell=False, and restrict the executable to a python/python3 allow-list. This removes shell metacharacter injection (the benchmark only needs Python to manipulate spreadsheets). Adds tests for the allow-list gate and non-interpretation of shell metacharacters.
2026-07-25 18:41:23 -04:00