Commit Graph

6 Commits

Author SHA1 Message Date
Svrnty
8b6c810f4a Add Canvas command surface 2026-05-28 21:44:02 -04:00
Svrnty
c0ff59097c Embed umbrella graph in workspace panel
Some checks failed
plugin-tests / test (push) Failing after 5s
upstream-drift / drift (push) Failing after 5s
2026-05-26 06:34:50 -04:00
Svrnty
80420e0d01 feat(plugin): sidebar nav buttons for Adwright + BTE (v0.5.0)
Some checks failed
plugin-tests / test (push) Failing after 5s
JP feedback: floating BTE launcher + always-visible Adwright panel were
"very fucked up" UX. Replaced with proper hermes-webui sidebar integration.

New static/svrnty_nav.js:
- Injects 2 nav-tab buttons into .sidebar-nav matching the existing
  data-panel + nav-tab + has-tooltip pattern
- Adwright: bullseye icon (marketing intelligence)
- BTE: sparkle/palette icon (creative studio)
- Wraps window.switchPanel to add main.svrnty-showing-{adwright,bte}
  classes so our panels participate in the existing main-view show/hide
  system without editing upstream panels.js
- Dispatches "svrnty:panel-switch" CustomEvent so panel modules can
  lazy-init / open / close based on which panel is active

Adwright panel:
- adwright.css: hidden by default; shows only when main has
  .svrnty-showing-adwright. When showing, occupies full main width
  and hides all other main children (chat etc).
- adwright.js: no change to mount logic (already mounted inside <main>).

BTE panel:
- bte.js: removed _installLauncher (no more floating bottom-right button).
  Init now listens for svrnty:panel-switch events to open/close the
  overlay. Defensively removes any stale .svrnty-bte-launcher DOM nodes
  from prior plugin versions.
- bte.css: launcher styles replaced with display:none !important.

manifest.yaml: bumped 0.4.0 → 0.5.0, svrnty_nav.js added to assets in
the correct load order (after app.js, before adwright.js + bte.js).
CONNECTION-MAP regenerated.

Karpathy 4 rules: no upstream edit, smallest possible wrap of switchPanel
to keep our panels coexisting with native panels (chat, tasks, kanban,
etc), CSS-only visibility (no DOM thrashing).

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-24 12:45:01 -04:00
Svrnty
0b19fdd7d0 feat(plugin): Adwright + BTE Command Center panels (v0.4.0)
Some checks failed
plugin-tests / test (push) Failing after 5s
Two new tool panels surfaced inside hermes-webui via inject_script/
inject_stylesheet. Both vanilla JS + CSS, no frameworks, WebUI CSS-vars
only (no hardcoded colors), light/dark inherits free.

## Adwright panel (static/adwright.{js,css} + routes/adwright.py)

5 tabs: Overview · Cycles · Audience · Targeting · Connections.
Layout: 60/40 panel/chat split via CSS :has() selector.
Always-visible, soft-disabled when active profile isn't `cmo*`.

Action wiring (READ path — agent-mediated per governance):
1. Panel button → fires custom event
2. Handler synthesizes /adwright <cmd> chat message
3. Posts via existing btnSend pathway → message visible in chat
4. CMO sees + calls mcp_adwright_<tool>
5. Panel polls /api/adwright/last-panel-update for structured payload
6. Mock payload returned v1; real session-DB reader plugs in when
   adwright-mcp gains writer

Connections WRITE path (governance exception, NO secrets in chat):
- POST /api/adwright/provision-creds with form fields
- Plugin invokes credctl set <key> via stdin (value never on argv)
- Allowlist enforced (defense-in-depth on key names)
- Auth-gated by WebUI session cookie

Skin: .svrnty-aw-* class prefix, window.SvrntyAdwright JS namespace,
guard against double-load, scoped MutationObserver.

## BTE Command Center panel (static/bte.{js,css} + routes/bte_proxy.py)

Content-mode pills (Polished/UGC/Photorealistic/Artistic) × media toggle
(Image/Video — Video disabled v1 pending Phase 4e) × recipe family picker
(Hero Shot/Lifestyle Shot/Photoshoot/Recipe Sheet/Montage Catalog) per
canonical PLANB-RECIPE-TAXONOMY. SKU picker, variant stepper 1-12,
single/batch toggle, [Generate] button.

Asset grid with streaming thumbnails, asset detail (full-res + rate +
comment + "Use in Adwright cycle" deep link). Embedded CMO chat right rail
for re-orienting generations ("make next batch warmer / less white space").

BTE proxy route (/api/bte/proxy) with whitelisted paths
(requestPhotoshoot, assetGrid, recipeStats, assets/{id}/thumb, etc.)
prevents browser-side CORS to BTE :6001.

Skin: .svrnty-bte-* class prefix, window.SvrntyBTE JS namespace.

## Wiring

manifest_version: 0.2.0 → 0.4.0
assets registered:
- /plugins/svrnty/adwright.{js,css} + static/adwright/
- /plugins/svrnty/bte.{js,css} + static/bte/
routes registered:
- GET /api/adwright/last-panel-update (panel update channel)
- POST /api/adwright/provision-creds (governance-exception write)
- GET/POST /api/bte/proxy (BTE REST proxy with allowlist)

Karpathy 4 rules: agents reported every deviation with rationale (Python
venv interp for hermes mcp add, missing aggregate connections-status RPC
composed from two verifies, mock panel-update v1 with locked frontend
protocol so real session-DB reader is a drop-in swap), verified asset
serving + plugin route registration before claiming complete, surfaced
open questions instead of silently choosing.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-24 12:12:27 -04:00
Svrnty
adc4c98cf8 docs: ship 6 polish fixes — manifest sync + LICENSE + CHANGELOG + .env.example + README + integration test
All checks were successful
plugin-tests / test (push) Successful in 5s
Closes the documentation gap surfaced by the compliance audit. Plugin now
passes the "well organized + well documented" bar in addition to the
"protocol §10 compliant" bar.

Changes:
  manifest.yaml    bump plugin_version 0.1.0 → 0.2.0 · routes status: live ·
                   audio_processors section added · public_api adds
                   register_audio_attachment_processor · tested_versions
                   appended (v0.51.117, v0.51.118) · current_local synced
  README.md        Status table flipped from "TBD" to "live" everywhere ·
                   forced internal deps + test count surfaced
  .env.example     declares the 4 env vars the plugin reads at runtime
                   (HERMES_WEBUI_PYTHON_PLUGIN · HERMES_WEBUI_STT_URL/_KEY ·
                   BTE_BASE_URL · BTE_TENANT_ID)
  CHANGELOG.md     v0.1.0 (scaffold + vault + brand) · v0.2.0 (STT + mic +
                   loader API extension)
  LICENSE          proprietary, contact jp@svrnty.io; clarifies that runtime
                   integration with hermes-webui (MIT) is permitted
  tests/integration/test_loader_contract.py
                   3 real assertions against the adjacent fork — 7-method
                   contract, register-our-plugin end-to-end, noop-when-env-unset

29/29 tests PASS (was 26; +3 integration).

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-23 11:02:28 -04:00
Svrnty
4264c6cbe8 feat(plugin): initial scaffold — plugin loader entry + AST + CI workflows (P1.B/C/D)
THE single repo holding every Svrnty modification to nesquena/hermes-webui per
the SVRNTY-HERMES Plugin Protocol PRD (hermes/docs/SVRNTY-PLUGIN-PROTOCOL.md).
This scaffold is the empty vessel; Phase 2 migrates the existing fork
modifications (STT, vault status, brand skin) into it.

Contents:
  plugin.py                          register(api) entry; reads 6-method
                                     contract; wires static + routes
  svrnty_hermes_webui_plugin/        package wrapper for pip install
  manifest.yaml                      plugin name · version · upstream pin
  pyproject.toml                     pip-installable
  routes/__init__.py                 placeholder until Phase 2 migration
  static/                            placeholder for brand skin migration
  CONNECTION-MAP.md                  AST-generated; 4 public API calls, 0 forced
  scripts/ast-connection-map.py      AST walker; modes: regen · --check · --diff
  tests/{unit,integration,evals}/    skeleton for Phase 3 eval suite
  .github/workflows/
    plugin-tests.yml                 push: unit + integration + map check
    connection-map-check.yml         PR: regen + diff vs committed
    upstream-drift.yml               daily cron: detect new upstream tags +
                                     run matrix (activates when Gitea runner
                                     registered on Svrnty infra)

Karpathy 4 rules in CLAUDE.md; every subagent inherits them via the workspace
contract.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-23 09:59:45 -04:00