Skip to content

locomoki/tomorrows-front-page

Repository files navigation

Tomorrow's Front Page

Tomorrow's Front Page – Hero

A Hermes-first creative intelligence workflow that turns a topic, source scope, horizon, audience, and risk posture into a synthetic future-facing newspaper front page. Hermes Agent orchestrates the semantic workflow. MiroFish runs remotely in Docker on Hetzner. Kimi K2.6 powers both Hermes Agent and the MiroFish backend.

Hermes owns source ingestion, seed-bundle construction, and final editorial synthesis. The Node backend handles deterministic MiroFish HTTP client I/O — multipart uploads, long timeouts, retries, polling, and structured evidence logging.

Hackathon Submission

Submission assets:

Architecture

flowchart LR
  UI[React zine/front-page UI] --> API[Node/Express local API]
  API -->|Chat Completions only| Hermes[Hermes Agent API\nhttp://localhost:8642/v1]
  Hermes --> Skills[Custom Hermes Skills]
  Skills --> Source[source-ingestion]
  Skills --> Seed[seed-builder]
  Skills --> MF[mirofish-wrapper]
  Skills --> Synth[front-page-synthesizer]
  API -->|real MiroFish client I/O| MiroFish[MiroFish API\ndefault hosted or localhost:5001]
  API --> Artifacts[artifacts/<run-id>/]
Loading

Prerequisites

  • Node.js 20+
  • npm 10+
  • Hermes Agent installed and configured
  • Optional: local MiroFish backend; otherwise the hosted default https://mirofish-api.ep0bxf.easypanel.host is used

Configure Hermes

Hermes API server docs specify enabling the API server and starting the gateway:

# ~/.hermes/.env
API_SERVER_ENABLED=true
API_SERVER_KEY=change-me-local-dev

hermes gateway run
# or, on older docs/versions: hermes gateway

The API server should listen on http://127.0.0.1:8642, with OpenAI-compatible /v1/chat/completions and /v1/models endpoints.

Copy env defaults:

cp .env.example .env

Key vars:

HERMES_BASE_URL=http://localhost:8642/v1
HERMES_MODEL=hermes-agent
HERMES_API_KEY=change-me-local-dev
MIROFISH_BASE_URL=https://mirofish-api.ep0bxf.easypanel.host
MIROFISH_PROJECT_ID=none
MIROFISH_TIMEOUT_MS=300000
MIROFISH_MAX_RETRIES=3
MIROFISH_POLL_ATTEMPTS=12
DEMO_MODE=false

Install dependencies

npm install

Install/adapt Hermes skills

bash scripts/install-hermes-skills.sh

This copies project skills into ~/.hermes/skills/tomorrows-front-page/*/SKILL.md. Restart hermes gateway run after installing so Hermes refreshes its skill index.

Run locally

Terminal 1:

hermes gateway run

Terminal 2:

npm run dev

Open the Vite URL, usually http://localhost:5173.

Verification

npm run verify

The script checks Node, dependencies, artifact writability, Hermes /v1/models, MiroFish client helper tests, backend startup, frontend build, and optional MIROFISH_BASE_URL reachability.

Generated artifacts

Each run writes:

  • artifacts/<run-id>/seed-bundle.json
  • artifacts/<run-id>/mirofish-run.json
  • artifacts/<run-id>/front-page.md
  • artifacts/<run-id>/front-page.html
  • artifacts/<run-id>/run-log.ndjson
  • artifacts/<run-id>/hermes-raw-output.txt when Hermes returns raw content

Demo fallback

Normal runs require Hermes. For UI-only offline testing:

DEMO_MODE=true npm run dev

DEMO_MODE=true is explicitly separated in apps/api/src/demoMode.js; it does not call Hermes or MiroFish and marks outputs as fallback data.

Troubleshooting

Hermes endpoint unavailable

  • Confirm API_SERVER_ENABLED=true in ~/.hermes/.env.
  • Start hermes gateway run.
  • Check HERMES_BASE_URL=http://localhost:8642/v1.
  • If auth is enabled, set HERMES_API_KEY to the same value as API_SERVER_KEY.

MiroFish backend unavailable

Set MIROFISH_BASE_URL to a reachable MiroFish API, or use the hosted default. If unavailable, mirofish-run.json will still include attempted requests/responses/errors and status="unavailable" or partial; it must not silently skip because MIROFISH_PROJECT_ID=none.

Malformed Hermes JSON

The backend strips common markdown JSON fences. If parsing still fails, it saves hermes-raw-output.txt and marks the run failed with Malformed Hermes JSON.

CORS issues

The browser talks to the local Node API through Vite's proxy. Hermes CORS is not required because the browser never calls Hermes directly.

Source references used

About

Turn any topic into tomorrow's front page. Hermes-first agents, MiroFish simulation, React zine UI.

Topics

Resources

Stars

Watchers

Forks

Contributors

Languages