Read-only web UI for browsing Hermes brain backends: SQLite fact store and markdown brain wiki.
  • TypeScript 88.8%
  • CSS 8.7%
  • JavaScript 2%
  • Dockerfile 0.5%
Find a file
Clawlter Agent cd6cd8788c
All checks were successful
Build and publish container image / Build Docker image and publish package tags (pull_request) Successful in 3m38s
CI / Validate lint, types, tests, and production build (pull_request) Successful in 3m39s
Build and publish container image / Build Docker image and publish package tags (push) Successful in 2m22s
CI / Validate lint, types, tests, and production build (push) Successful in 4m28s
feat(docker): add runtime healthcheck
2026-04-29 03:51:30 +00:00
.forgejo/workflows ci(container): publish docker image tags 2026-04-15 16:26:14 +00:00
public feat(ui): build hermes brain web browser 2026-04-15 16:05:13 +00:00
scripts ci(container): publish docker image tags 2026-04-15 16:26:14 +00:00
src feat(docker): add runtime healthcheck 2026-04-29 03:51:30 +00:00
tests feat(docker): add runtime healthcheck 2026-04-29 03:51:30 +00:00
.dockerignore feat(ui): build hermes brain web browser 2026-04-15 16:05:13 +00:00
.gitignore feat(ui): build hermes brain web browser 2026-04-15 16:05:13 +00:00
docker-compose.yml feat(ui): build hermes brain web browser 2026-04-15 16:05:13 +00:00
Dockerfile feat(docker): add runtime healthcheck 2026-04-29 03:51:30 +00:00
eslint.config.mjs feat(ui): build hermes brain web browser 2026-04-15 16:05:13 +00:00
next-env.d.ts feat(ui): build hermes brain web browser 2026-04-15 16:05:13 +00:00
next.config.ts feat(ui): build hermes brain web browser 2026-04-15 16:05:13 +00:00
package-lock.json fix(ui): improve pane layout and graph responsiveness 2026-04-15 18:49:48 +00:00
package.json fix(ui): improve pane layout and graph responsiveness 2026-04-15 18:49:48 +00:00
README.md feat(docker): add runtime healthcheck 2026-04-29 03:51:30 +00:00
tsconfig.json feat(ui): build hermes brain web browser 2026-04-15 16:05:13 +00:00
vitest.config.ts feat(ui): build hermes brain web browser 2026-04-15 16:05:13 +00:00

hermes-brain-web

hermes-brain-web is a read-only web UI for two mounted knowledge backends:

  • a SQLite fact store
  • a markdown brain wiki

It does not bundle Hermes internals, and it does not copy brain data into the repository or image. The container only reads mounted data and renders a browser-oriented UI on top.

What it does

  • Browse all facts in the SQLite fact store.
  • Browse all pages in the markdown brain wiki.
  • Inspect metadata, tags, and relationship context for the selected record.
  • Follow an interactive knowledge graph from the detail pane into connected records.
  • Browse full graph overviews with lightweight edge interaction so dense wiki graphs remain pannable.
  • Pivot from fact-store entities into the facts that reference them.
  • Run entirely against read-only mounts.

Stack

  • Next.js 16
  • React 19
  • TypeScript
  • better-sqlite3 for local read-only SQLite access
  • gray-matter for wiki frontmatter parsing
  • Vitest + Testing Library for behavior-focused tests

Runtime contract

The app expects these environment variables inside the container:

  • HERMES_BRAIN_SQLITE_PATH=/data/memory/memory_store.db
  • HERMES_BRAIN_WIKI_ROOT=/data/wiki
  • PORT=3000

The SQLite file and wiki directory can both be mounted read-only. The Docker image includes a healthcheck that calls GET /api/health; the endpoint returns 200 only when the runtime config is valid, the SQLite fact store is readable with the expected schema, and the wiki root is a readable directory.

Run with Docker Compose

  1. Edit docker-compose.yml and replace the placeholder host paths.
  2. Start the app:
docker compose up --build
  1. Open http://localhost:3000.

Example volume bindings:

volumes:
  - /absolute/path/to/memory_store.db:/data/memory/memory_store.db:ro
  - /absolute/path/to/wiki/brain:/data/wiki:ro

Container publishing

Forgejo Actions builds the Docker image in CI for pull requests and publishes it to the Forgejo container registry for deployable refs.

Publishing rules:

  • pushes to main publish code.mehalter.com/clawlter/hermes-brain-web:dev
  • published releases tagged like v1.2.3 publish:
    • code.mehalter.com/clawlter/hermes-brain-web:v1.2.3
    • code.mehalter.com/clawlter/hermes-brain-web:v1
    • code.mehalter.com/clawlter/hermes-brain-web:latest
  • pull requests build the image without pushing it

The publish workflow expects a Forgejo Actions secret named PACKAGE_TOKEN with permission to push packages for the owning user.

Local development

Install dependencies:

npm ci

Run the app:

HERMES_BRAIN_SQLITE_PATH=/absolute/path/to/memory_store.db \
HERMES_BRAIN_WIKI_ROOT=/absolute/path/to/wiki/brain \
npm run dev

Quality checks

npm run lint
npm run typecheck
npm test
npm run build

Testing philosophy

The tests focus on behavior rather than brittle snapshots:

  • config parsing verifies the container contract
  • SQLite loader tests verify fact/entity/bank normalization
  • wiki loader tests verify frontmatter parsing and bidirectional wiki-link extraction
  • graph builder tests verify neighborhood construction for facts, entities, and wiki pages
  • UI tests verify backend switching and graph-driven browsing behavior

Repository safety

  • This repository contains no brain data.
  • The app is read-only by design.
  • Authentication is intentionally out of scope so you can put it behind your own reverse proxy or auth gateway.

Notes on the wiki parser

The wiki browser reads markdown files recursively, parses YAML frontmatter, extracts [[wiki-links]], and computes incoming/outgoing relationships in memory. It excludes the top-level index.md from the page corpus so the curated wiki landing page does not dominate graph results.