Skip to content

fix(skills): preload pinned guidance without requiring skills tools - #116315

Open
s0xn1ck wants to merge 1 commit into
NousResearch:mainfrom
s0xn1ck:fix/pinned-skills-without-tools
Open

s0xn1ck wants to merge 1 commit into
NousResearch:mainfrom
s0xn1ck:fix/pinned-skills-without-tools

Conversation

@s0xn1ck

@s0xn1ck s0xn1ck commented Sep 19, 2026

Copy link
Copy Markdown

Summary

Follow-up to merged #92048. Configured skills.auto_load is startup guidance, not a callable capability. Include its full body when skills tools are unavailable, including sessions with zero tools. The skills index remains tool-gated; this change enables no tools.

Remove only the tool-availability condition in _auto_load_parts. Preserve internal-fork suppression, ignore-rules handling, existing profile resolution, missing/disabled-skill behavior, resolve-once caching and canonical-name explicit-preload deduplication.

Configured skill text is sent to the chosen model even with skills tools disabled. Operators should not pin secrets or untrusted instructions. This does not change skill text's established prompt authority or any tool permissions.

Regression coverage

  • No tools and unrelated tools: full pinned body exactly once, tool names unchanged.
  • Explicit preload excludes already auto-loaded canonical names.
  • Config and skill mutation after initial resolution leaves rebuilt prompt bytes unchanged.
  • Separate synthetic homes retain their own cached skill bodies.
  • Ignore-rules and internal forks suppress automatic guidance with and without skills tools.
  • New single-profile CLI integration test exercises real CLI construction, background preload/finalization, agent initialization, conversation loop and OpenAI SDK JSON serialization through httpx.MockTransport. Both zero-tools and unrelated-tools cases verify full pinned content in the existing system/developer prefix, stable prefix bytes and unchanged callable schemas. Socket connections are blocked; auxiliary metadata, credentials, MCP discovery and security installation are stubbed as unrelated boundaries.

Verification

Reviewed snapshot base: 4fda3bbdca947ebbff3f0c573881a578c3673d5d.

Test-first on unchanged production source: auto-load tests produced 2 failed, 4 passed, specifically missing full pinned content with zero/unrelated tools.

Independent review ran the canonical runner with a clean temporary HOME and isolated dependency interpreter:

bash scripts/run_tests.sh \
  tests/hermes_cli/test_cli_pinned_skills_wire.py \
  tests/agent/test_skills_auto_load.py \
  tests/agent/test_system_prompt.py \
  tests/agent/test_prompt_builder.py \
  tests/agent/test_prompt_caching.py \
  tests/agent/test_prompt_cache_boundary.py \
  tests/agent/test_prompt_cache_scope.py \
  tests/hermes_cli/test_cli_preloaded_skills.py \
  -j 4 --file-retries 0

Result: 267 passed, 0 failed, 1 skipped across eight files. Four serialized provider requests were captured in-process; no real model/authentication endpoint was contacted. git diff --check passed.

Full repository suite and lint checks on the new request-capture test were not run. Earlier checks on the two original changed files passed ruff check; their formatting checks also fail on unchanged upstream, so broad formatting churn is excluded.

This is a single-profile in-process integration test, not an installed executable/argparse smoke test. Concurrent CLI ContextVar propagation is a separate unresolved issue and is not fixed or validated here. Independent review found no material correctness issue in this minimal production delta; this is not release certification. Maintainer agreement on treating configured guidance independently of tool availability remains a policy decision.

@alt-glitch alt-glitch added type/bug Something isn't working P3 Low — cosmetic, nice to have comp/agent Core agent runtime: loop, agent_init, prompt builder, context-compression, responses endpoint tool/skills Skills system (list, view, manage) area/config Config system, migrations, profiles sweeper:risk-caching Sweeper risk: may break/degrade prompt caching or cache-key stability (invariant) sweeper:risk-compatibility Sweeper risk: may break existing users, config, migrations, defaults, or upgrades labels Sep 19, 2026
@whyyagswhy

Copy link
Copy Markdown

Independent verification on the PR head (9bdbd7f): skills auto-load plus pinned-skills wire suites 10/10 green on Linux. Preloading pinned guidance without skills tools keeps startup behavior intact. No findings.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/config Config system, migrations, profiles comp/agent Core agent runtime: loop, agent_init, prompt builder, context-compression, responses endpoint P3 Low — cosmetic, nice to have sweeper:risk-caching Sweeper risk: may break/degrade prompt caching or cache-key stability (invariant) sweeper:risk-compatibility Sweeper risk: may break existing users, config, migrations, defaults, or upgrades tool/skills Skills system (list, view, manage) type/bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants