Svrnty plugin for nesquena/hermes-webui — single repo for every backend + brand mod (per hermes/docs/SVRNTY-PLUGIN-PROTOCOL.md)
Go to file
Svrnty 37123f570b
All checks were successful
plugin-tests / test (push) Successful in 8s
feat(plugin): STT migration via audio_attachment_processor hook (L1-L6)
Closes Phase 2.A. STT now lives entirely in the plugin via the new public-API
method `api.register_audio_attachment_processor` added to the loader hook
(Rule 1 — extended API, no forced-internal). The fork patch stays minimal
(streaming.py gains a small loop that calls registered processors; loader
adds the 1 new method).

Plugin additions:
  routes/transcribe.py            POST /api/transcribe + audio_attachment_processor
                                  - _external_stt_transcribe: multipart POST to STT endpoint
                                  - _handle_transcribe: one-shot transcription route
                                  - _transcribe_audio_attachments: voice-message processor
                                  - _parse_multipart_file: stdlib email-based multipart
                                    (Python 3.13 dropped cgi per PEP 594)
  tests/unit/test_transcribe.py   8 tests (register, processor, route, multipart parser)
  tests/evals/test_features.py    + 1 eval (audio processor signature contract)

Config (read at call time, never persisted):
  HERMES_WEBUI_STT_URL  external STT endpoint (OpenAI or WhisperX shape)
  HERMES_WEBUI_STT_KEY  optional bearer token

CONNECTION-MAP regenerated: 9 public-API · 0 forced-internal · 1 frontend.
20/20 tests PASS.

Loader API extended in hermes-webui (next commit there) — 7th method:
register_audio_attachment_processor. Streaming.py gets a small loop that
calls registered processors before _build_native_multimodal_message.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-23 10:14:29 -04:00
.github/workflows feat(plugin): initial scaffold — plugin loader entry + AST + CI workflows (P1.B/C/D) 2026-05-23 09:59:45 -04:00
routes feat(plugin): STT migration via audio_attachment_processor hook (L1-L6) 2026-05-23 10:14:29 -04:00
scripts feat(plugin): STT migration via audio_attachment_processor hook (L1-L6) 2026-05-23 10:14:29 -04:00
static feat(plugin): migrate vault UI panel + STT route stub into plugin (P2 cont.) 2026-05-23 10:06:56 -04:00
svrnty_hermes_webui_plugin feat(plugin): initial scaffold — plugin loader entry + AST + CI workflows (P1.B/C/D) 2026-05-23 09:59:45 -04:00
tests feat(plugin): STT migration via audio_attachment_processor hook (L1-L6) 2026-05-23 10:14:29 -04:00
.gitignore feat(plugin): initial scaffold — plugin loader entry + AST + CI workflows (P1.B/C/D) 2026-05-23 09:59:45 -04:00
CLAUDE.md feat(plugin): initial scaffold — plugin loader entry + AST + CI workflows (P1.B/C/D) 2026-05-23 09:59:45 -04:00
CONNECTION-MAP.md feat(plugin): STT migration via audio_attachment_processor hook (L1-L6) 2026-05-23 10:14:29 -04:00
Makefile feat(plugin): Phase 2 partial — vault_status migrated + brand skin moved + eval suite (P2.B/C, P3.A/B) 2026-05-23 10:02:47 -04:00
manifest.yaml feat(plugin): initial scaffold — plugin loader entry + AST + CI workflows (P1.B/C/D) 2026-05-23 09:59:45 -04:00
plugin.py feat(plugin): STT migration via audio_attachment_processor hook (L1-L6) 2026-05-23 10:14:29 -04:00
pyproject.toml feat(plugin): initial scaffold — plugin loader entry + AST + CI workflows (P1.B/C/D) 2026-05-23 09:59:45 -04:00
README.md feat(plugin): initial scaffold — plugin loader entry + AST + CI workflows (P1.B/C/D) 2026-05-23 09:59:45 -04:00

svrnty-hermes-webui-plugin

THE single repo holding every Svrnty modification to nesquena/hermes-webui. Loaded at runtime via the plugin loader hook patched into the fork.

Protocol contract: hermes/docs/SVRNTY-PLUGIN-PROTOCOL.md — read this before contributing.

Install

# 1. Install the plugin in the same venv as hermes-webui
pip install -e ~/workspaces/hermes/svrnty-hermes-webui-plugin

# 2. Tell hermes-webui to load it
export HERMES_WEBUI_PYTHON_PLUGIN=svrnty_hermes_webui_plugin
# or set in docker-compose.override.yml under environment:

# 3. Restart hermes-webui — endpoints under /api/* + assets under /plugins/svrnty/* land

Without HERMES_WEBUI_PYTHON_PLUGIN, hermes-webui runs vanilla (no Svrnty mods).

What's in here

Dir What
plugin.py Entry point — register(api) wires routes + static
routes/ One file per Svrnty /api/* endpoint (transcribe, vault_status, …)
static/ Brand skin: app.js, app.css, Montserrat fonts
CONNECTION-MAP.md AST-generated map of every upstream symbol this plugin touches
scripts/ Tooling — AST walker, upstream sync, boot smoke
tests/ Unit · integration · evals (each upstream-sync runs evals)
.github/workflows/ Plugin-tests · connection-map-check · upstream-drift CI

Public extension API

The plugin loader (one fork commit in hermes-webui) exposes exactly 6 methods:

api.register_route(path, method, handler)   # add /api/<path>
api.register_static(prefix, directory)      # serve files under /plugins/<prefix>/...
api.inject_script(url)                      # add <script> to index.html
api.inject_stylesheet(url)                  # add <link> to index.html
api.config_get(key, default)                # safe upstream config read
api.logger(name)                            # namespaced logger

Touching anything else in hermes-webui = a Rule 2 violation per the protocol. Document the escape hatch in CONNECTION-MAP.md under "forced internal dependencies".

Hygiene

  • make sync-upstream — one-command rebase against latest upstream + report
  • python scripts/ast-connection-map.py — regenerate the map
  • python scripts/boot-smoke.py — start + curl every plugin endpoint
  • pytest tests/ — full suite (unit + integration + evals)

Status

Component State
Loader hook in hermes-webui TBD (Phase 1)
Plugin scaffold Phase 1 in progress
Migrated features (transcribe, vault_status, brand skin) TBD (Phase 2)
Automation (drift CI, sync command, eval suite) TBD (Phase 3)
Upstream PR TBD (Phase 4)