Repository navigation
Conversation
…ousResearch#108032) Skills mounted via skills.external_dirs were collapsed to provenance 'agent', causing the Desktop UI to badge them as 'learned' and counting them toward the starmap/journey growth. They were also mutable in place via foreground skill_manage, risking corruption of shared/team checkouts. - Add skills.external_dirs_allow_mutations (default false) and helpers is_external_dir_skill_path / is_external_dirs_writes_allowed. - Report external provenance ('external') in skill_usage.provenance and the /api/skills endpoint, render an 'external' badge in Desktop and make those skills non-editable there. - Enforce a foreground + background read-only guard in skill_manage that refuses patch/edit/delete/write_file/remove_file on external mounts unless the opt-in is set, with a local-copy hint. - Exclude external mounts from the learning-graph starmap. Co-authored-by: kyssta-exe
Duplicate of #108040 (KoNit-K, opened ~19h earlier), which fixes the same #108032 with the same mechanism: a first-class |
|
Closing as duplicate — this PR has the |
Fixes #108032.
Provenance — skills under
skills.external_dirs(e.g.~/.agents/skills) were collapsed toprovenance='agent', so Desktop badged themlearned(习得) and the starmap/journey counted shared team mounts as self-improved sediment. Now they reportexternalinskill_usage.provenance()and/api/skills, render as anexternalbadge, are non-editable in Desktop, and are excluded from the learning-graph starmap.Write guard (security) — background curator was already blocked, but foreground
skill_manage(patch/edit/write_file/remove_file/delete) mutated external checkouts in place with no permission check. Nowskill_managerefuses in-place external mutations by default, with a local-copy hint. Opt in withskills.external_dirs_allow_mutations: true(also honoursallow_external_edits/allow_external_mutationsaliases).Tests:
tests/tools/test_skill_usage.py,tests/agent/test_skill_utils.py,tests/tools/test_skill_manager_tool.py,tests/agent/test_learning_graph.py— all green; manual verification of external provenance and read-only refusal with/without the opt-in.