refactor(skills): decompose netclaw-operations + reconcile identity-vs-memory routing#1485
Merged
Aaronontheweb merged 2 commits intoJun 25, 2026
Conversation
e44793f to
b5e1231
Compare
6021c01 to
0781454
Compare
…s-memory routing Decompose the 1,148-line netclaw-operations skill into a hybrid layout (netclaw-dev#1115): keep safety-critical, high-frequency guidance inline (tool-argument validation, large-output handling, the full approval-prompts section, identity routing) and move the long-tail manuals into references/*.md, surfaced on demand via skill_read_resource. SKILL.md drops to 346 lines. Activation is unaffected -- it keys off the frontmatter description, which is unchanged. Validated against the local-tier model (Qwen3.6-35B-A3B): the skill_read_resource second hop fires ~80% of runs, which is why high-value content stays inline rather than being fully externalized. Reconcile the identity-vs-memory routing rule to openspec/specs/ netclaw-agent-memory: durable user facts and preferences are memory documents (store_memory); identity files (SOUL.md/AGENTS.md) define the agent. The binary AGENTS.md memory-triage table, skill-authoring, and netclaw-operations had all routed user "preferences" to SOUL.md, contradicting the spec and netclaw-memory -- the model correctly used store_memory and failed the eval. Align AGENTS.md, skill-authoring, netclaw-memory, and the ops Identity section. Evals: add skill_progressive_disclosure (verifies the skill_read_resource second hop via a reference-only detail) and repurpose memory_identity_preference_routing to assert the spec-correct invariant (routed to memory, never an identity-file edit). Bump versions: netclaw-operations 2.16.0, netclaw-memory 1.5.0, skill-authoring 1.7.1.
The publish_skills.yml post-upload validation only spot-checked the first skill's SKILL.md URL, so a reference (files[]) object that failed to resolve would not be caught. Now that netclaw-operations ships as a multi-file skill, also fetch the first files[] URL from the generated manifest and assert HTTP 200 -- self-verifying that progressive-disclosure reference files publish to R2 end-to-end.
0781454 to
ab4d3a1
Compare
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.
Summary
Decomposes the 1,148-line
netclaw-operationsskill into a hybrid progressive-disclosure layout (a variant of #1115) and reconciles the identity-vs-memory routing rule toopenspec/specs/netclaw-agent-memory.Part 1 — Decompose
netclaw-operations(#1115)SKILL.mddrops 1,148 → 346 lines. Safety-critical / high-frequency guidance stays inline (tool-argument validation, large-output handling, the full approval-prompts section, identity routing); the long-tail manuals move intoreferences/*.md, surfaced on demand viaskill_read_resource.Why hybrid, not the full split #1115 sketched: I gated the decomposition on whether the local-tier model (
Qwen3.6-35B-A3B) reliably does theskill_load → skill_read_resourcetwo-hop. It does ~80% of runs (3/5 clean, 1/5 after thrashing, 1/5 bypassed to a web fetch of the source). For long-tail detail that's fine; for distilled guidance with no external fallback a missed hop = lost guidance — so the high-value content stays inline.Mechanism verified end-to-end (no runtime/feed changes needed):
description(unchanged) — the split does not affect activation (SkillRegistry.GenerateIndex/Search).references/*.mdare auto-discovered (SkillScanner.EnumerateResources) and surfaced byskill_load;skill_read_resourcereads them (scoped toreferences//scripts//assets/).Part 2 — Reconcile identity-vs-memory routing
Per
openspec/specs/netclaw-agent-memory, durable user facts & preferences are memory documents (store_memory); identity files (SOUL.md/AGENTS.md) define the agent. The binaryAGENTS.mdmemory-triage table,skill-authoring, andnetclaw-operationshad all routed user "preferences" →SOUL.md, contradicting the spec andnetclaw-memory. The model correctly usedstore_memoryand failed the old eval. Aligned all four sources.Part 3 — Evals
skill_progressive_disclosure— verifies theskill_read_resourcesecond hop via a reference-only detail (the reminder auto-disable threshold/alert name).memory_identity_preference_routingto assert the spec-correct invariant: routed to memory, never an identity-file edit. 5/5 on the local-tier model.Version bumps:
netclaw-operations2.17.0,netclaw-memory1.5.0,skill-authoring1.7.1. (2.17.0 rather than 2.16.0 because #1481 independently took 2.16.0 ondev; this PR is rebased past it and folds its sub-agent-liveness wording intoreferences/scheduling.md.)Verification
Full rebuild + 55-case eval suite vs
Qwen3.6-35B-A3B(spark1): tool-calling 8/8, identity 4/4, grounding 3/3, multi-turn 7/7 — no regressions from the split or the always-loadedAGENTS.mdchange.memory_identity_preference_routing5/5 (refined assertion). Remaining suite movement is small-sample model nondeterminism in untouched categories.skill_progressive_disclosurelands ~70–80% — the intended ongoing signal for the two-hop read (and the reason for the hybrid layout).CI
This is the first multi-file skill, so I hardened
publish_skills.yml: the post-upload validation previously only spot-checked the first skill'sSKILL.mdURL. It now also fetches afiles[](reference) URL from the generated manifest and asserts HTTP 200 — self-verifying that progressive-disclosure reference files actually publish to R2 end-to-end, not just the top-levelSKILL.md.Verified the full publish chain on this branch:
generate-skill-manifest.shemitsnetclaw-operationsv2.17.0 with all 10references/*.mdinfiles[](each withpath/sha256/sizeBytes/url) and an upload-list entry per file;publish_skills.ymluploads every upload-list entry to R2; the consumer (SkillFeedManifest/SystemSkillSyncService) readsfiles[]with matching field names and downloads + sha256-verifies each reference atomically.Closes #1115.