Skip to content

chore(skills): clean up PR #862 + feat(docs): add search to Docusaurus#1053

Merged
teknium1 merged 2 commits into
mainfrom
hermes/hermes-c877bdeb
Mar 12, 2026
Merged

chore(skills): clean up PR #862 + feat(docs): add search to Docusaurus#1053
teknium1 merged 2 commits into
mainfrom
hermes/hermes-c877bdeb

Conversation

@teknium1

@teknium1 teknium1 commented Mar 12, 2026

Copy link
Copy Markdown
Contributor

Changes

1. Skills cleanup (follow-up to PR #862 by @arceus77-7)

hermes_cli/skills_hub.py:

  • Removed unnecessary isinstance(bundled_manifest, dict) guard — _read_manifest() always returns Dict[str, str], so set(_read_manifest()) suffices.

tests/hermes_cli/test_skills_hub.py:

  • Extracted repeated hub-dir monkeypatching (8 lines × 3 tests) into a shared hub_env pytest fixture.
  • Added three_source_env fixture for source-classification tests.
  • Added _read_manifest monkeypatch to test_do_list_initializes_hub_dir (previously fragile).
  • Added test coverage for --source hub and --source builtin filters.
  • Extracted _capture() helper to reduce boilerplate.

2. Docusaurus search

Adds @easyops-cn/docusaurus-search-local (v0.55.1) for offline full-text search:

  • Search bar in the navbar (Ctrl/Cmd+K shortcut)
  • Search index built at build time — no Algolia or external services needed
  • Highlights matched terms on the target page when clicking a result
  • Dedicated /search page for expanded results
  • Configured to match existing docs routing (docsRouteBasePath: '/')

Test plan

pytest tests/hermes_cli/test_skills_hub.py -n0 -v  # 5 passed
pytest tests/ -n0 -q                               # 3153 passed
cd website && npx docusaurus build                  # Builds successfully, search index generated

Follow-up to PR #862 (local skills classification by arceus77-7):

- Remove unnecessary isinstance guard on _read_manifest() return value —
  it always returns Dict[str, str], so set() on it suffices.
- Extract repeated hub-dir monkeypatching into a shared pytest fixture (hub_env).
- Add three_source_env fixture for source-classification tests.
- Add _read_manifest monkeypatch to test_do_list_initializes_hub_dir
  (was fragile — relied on empty skills list masking the real manifest).
- Add test coverage for --source hub and --source builtin filters.
- Extract _capture() helper to reduce console/StringIO boilerplate.

5 tests, all green.
Add @easyops-cn/docusaurus-search-local (v0.55.1) for offline/local
full-text search across all documentation pages.

- Search bar appears in the navbar (Ctrl/Cmd+K shortcut)
- Builds a search index at build time — no external service needed
- Highlights matched terms on target page after clicking a result
- Dedicated /search page for expanded results
- Blog indexing disabled (blog is off)
- docsRouteBasePath set to '/' to match existing docs routing
@teknium1 teknium1 changed the title chore(skills): clean up PR #862 — simplify manifest guard, DRY up tests chore(skills): clean up PR #862 + feat(docs): add search to Docusaurus Mar 12, 2026
@teknium1 teknium1 merged commit 5a4348d into main Mar 12, 2026
1 check passed
angelburgosrosado pushed a commit to angelburgosrosado/hermes-agent that referenced this pull request Apr 27, 2026
…c877bdeb

chore(skills): clean up PR NousResearch#862 + feat(docs): add search to Docusaurus
02356abc pushed a commit to 02356abc/hermes-agent that referenced this pull request May 14, 2026
…c877bdeb

chore(skills): clean up PR NousResearch#862 + feat(docs): add search to Docusaurus
olympus-terminal pushed a commit to olympus-terminal/hermes-agent that referenced this pull request May 16, 2026
…c877bdeb

chore(skills): clean up PR NousResearch#862 + feat(docs): add search to Docusaurus
Egavasyug pushed a commit to Egavasyug/hermes-agent that referenced this pull request Jun 10, 2026
…c877bdeb

chore(skills): clean up PR NousResearch#862 + feat(docs): add search to Docusaurus
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant