The Chronicle is the browser-based record of a world. It runs beside the game server and reads the same SQLite databases through read-only paths. It never connects to the public Haven & Hearth sites, and it never injects input into a client.
The Chronicle
The home view is a live geopolitical map with a time slider. The built-in panels cover:
- world timelapse frames;
- activity heatmaps;
- battle and graveyard heatmaps;
- resource and quality cheat maps, locked behind an explicit spoiler toggle;
- Civ-style rise-and-fall graphs;
- the Simulated World Forum and Gazette tab.
The spoiler toggle is fail-closed. Without it, the cheat-map endpoint returns a locked payload instead of hidden resource or quality data.
The local wiki
The local Ring of Brodgar snapshot is indexed into FTS5 and served from this machine. Custom HHLocal pages carry a [HHLocal Custom] badge. Vanilla pages that differ under HHLocal carry an [HHLocal Note] callout with a link to the relevant HHLocal page. The search box and JSON search endpoint read the same index.
Legends Mode and Past Worlds
A finished world can be sealed into an immutable Past Worlds archive. The seal uses the simulated world clock's end instant and the world seed to derive the archive id, so the same end-of-world attempt always addresses the same directory:
- [archive root]/[archive id]/world.sqlite is a VACUUM INTO copy of the live world;
- manifest.json records the seed, schema version, seal instant, chronicle snapshot, byte counts and SHA-256 digests;
- history-book.json and history-book.md are the two History Book exports.
After publication the database, manifest and both exports are read-only. Every catalogue, load and query call re-proves the recorded SHA-256 and runs PRAGMA quick_check through the read-only snapshot helper before returning data. A duplicate seal, a missing archive, a digest mismatch or a corrupt archive is refused with a stable refusal code.
History Book
Both exports always contain the same eight sections in this order:
- Settlements
- Dynasties
- Wars
- Ruins
- Legends
- Notable People
- Notable Events
- Chronicle Snapshots
The content comes from the public WorldStore loaders. Dynasties are derived from persona ancestor links. The current schema has no war table, so wars is an explicit empty list rather than an invented record. Every list is sorted by a stable key, so an unchanged world produces byte-identical exports.
Hearth Gazette
The Hearth Gazette is the weekly digest of real chronicle activity. Each issue is persisted as a forum post in the gazette category, stickied and authored by The Hearth Gazette. Generation is idempotent: re-running it does not duplicate an issue. Market quotes and activity summaries in the Gazette are derived from the same read-only data as the rest of the Chronicle.
The local World Forum
The live World Forum is a per-world board set served at /forum. Villagers may post there only when their knowledge mode allows it, and human players read the same boards. The forum is part of the world's public record, not a private chat channel.
Old World Haven & Hearth Forum Archives
The historical H&H forum dump is mounted as a separate read-only archive at /forum/archive. Its contract is deliberately narrow:
- the SQLite database is opened with mode=ro, so nothing in the viewer can write to the snapshot;
- post HTML passes through a strict allow-list sanitizer; scripts, event handlers and external links do not survive;
- archived image URLs are rewritten to local, hashed paths of the form /forum/media/[sha256].[ext];
- only raster images are served. The server checks both the file extension and the magic bytes for PNG, JPEG, GIF, WebP, BMP and ICO;
- media responses carry X-Content-Type-Options: nosniff, and path traversal or malformed hashes are rejected;
- a missing or un-crawled archive yields graceful empty boards instead of an exception.
Where the rules live
- Chronicle UI and routing: web/chronicle/index.html, web/chronicle/app.py and web/chronicle/static/
- Wiki snapshot, overlay and renderer: web/chronicle/wiki/
- Live forum and Gazette: web/chronicle/forum/
- Legends Mode: hhlocal.parity.LegendsMode and docs/legends-mode.md
- Past Worlds catalogue and History Book: the legends module in the parity tables