Skip to content

docs(adr): build new first-party apps on hearth, with lodge as their hub - #265

Merged
bketelsen merged 2 commits into
mainfrom
lucilla/adr-0085-hearth-lodge-hub
Nov 16, 2026
Merged

bketelsen merged 2 commits into
mainfrom
lucilla/adr-0085-hearth-lodge-hub

Conversation

@frostyard-machines

@frostyard-machines frostyard-machines commented Nov 16, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Adds ADR-0085: new first-party apps are built on hearth (frostyard/hearth), a toolkit of Protobuf options, protoc plugins and a Go runtime over Connect, and lodge is their hub (OAuth with consent, 1 MCP gateway per principal, an embedded NATS JetStream broker on lodge's HTTPS listener and a Unix socket, no second port). The ADR records the scope (frostnotes, frostmail and Porter keep lodge's current contract), the options and their extension numbers, the manifest and its compatibility rule, the MCP mapping, the permission and trust rules, the event contract, the names (frostyard.<app>.v1, org.frostyard.<app>.<object>.<verb>, ADR-0016), that an app on hearth needs no lodge, and the rejected alternatives (YAML schema and tools/rpcgen; code-first Go).

  • ADR-0057 gets a link-only back-reference (ADR-0033) that names what ADR-0085 amends: the per-app MCP endpoint and lodge/kit as the app library. ADR-0085 lists each ADR-0057 statement it makes false, for apps on hearth only.
  • Plan 0002 gets an "Incubating repositories" section: frostyard/hearth and frostyard/frostmarks, exit criteria = the pilot's done lines, decision date 2027-03-31. Plan 0002 is superseded as a whole; its status line now says that its lifecycle states stay in use for this list.
  • docs/README.md indexes the ADR.

The 2 repositories do not exist yet; the links in Plan 0002 resolve once they are created from bketelsen/agentic-template.

Risk tier

Risk tier: 1 — docs only (an ADR, a link-only line in ADR-0057, a plan section and an index line). No path in .github/risk-paths.json matches.

Docs housekeeping

  • New docs started from their category's TEMPLATE.md
  • Every new doc indexed in docs/README.md
  • Cross-links added in both directions (ADR ↔ plan; ADR-0085 ↔ ADR-0057)
  • New significant decision recorded as an ADR first, in this PR
  • New/edited ADRs are fact-only (ADR-0051)
  • Conformance aliases (ADR-0029) untouched

Verification

  • make ci green locally before the first push (953 tests pass, check:docs included)
  • npm run verify green
  • Not covered: the external links (lodge ADRs on GitHub, MCP and CloudEvents specs) are not checked by the docs gate; they were checked by hand against lodge origin/main at 78f5e20.

Review

  • Cross-review: reviewer openai/gpt-6.1-sol, coder anthropic/claude-opus-5-5, base cbb54f2c9186877b78e378dc83bf900dcd65b6bf.
    • Initial review at 1607f5fb73e37eefd4576f27599b48bfe4b0e4a0: Not ready, 2 blocking findings. (1) The prefix rule "G covers P when P is G or starts with G + /" gave the root / no children. (2) The context's tool, method and line counts named no source.
    • Fixed in 21f7973612899e595c0aa9635b9bff20ef2cc46f: the root has its own clause (an item on / covers every path), with a /Chan against /Chani example; the counts are removed. Guard: an AGENTS.md rule beside the count rule (prefix rules state root and boundary cases) and the record .memory/corrections/2026-11-15-pr-265-adr-root-path-and-counts.json.
    • Re-review 1 at 21f7973612899e595c0aa9635b9bff20ef2cc46f: Ready, Blocking: none.
  • Owner review (lodge, hearth, frostmarks) at 1607f5f: OK, in the PR comment above. The change after it only fixes the root case of the path rule, as the plan's design states it ("/ is the root"), and removes the counts.
  • Revert test: exempt (docs only, no new behavior).
  • make ci passed locally at 21f7973; CI is green at 21f7973.

ADR-0085 records the toolkit, permission, event and hub contracts for new
first-party apps, and amends ADR-0057 in part (per-app MCP endpoint;
lodge/kit as the app library). Plan 0002 lists frostyard/hearth and
frostyard/frostmarks as incubating, with exit criteria and a decision date
of 2027-03-31.
@github-actions github-actions Bot added the level:L3 Skim label Nov 16, 2026
@frostyard-machines

Copy link
Copy Markdown
Contributor Author

Owner review: OK (lodge, hearth, frostmarks), at head 1607f5f.

  1. Context facts are correct. lodge ADR-0006 gives each app its own MCP endpoint, and ADR-0012 records that the two tools/rpcgen copies do not converge. frostnotes' schema/rpc/events.yaml has callers: [local, session, device] on origin/main. The tool and method counts and the token path (lodgectl token issue, token file, client entry, app-read scope) match the code.
  2. The Decision does not block lodge's t2 or t6 work. The consent rule (only a login on lodge's admin list approves), effective access as grant within client scope, opaque tokens with server-side grants, the gateway at /gateway/mcp, the broker on /run/lodge/nats.sock and /nats, and "no second port" all match what t2 and t6 build. t2 can still ship the broker off by default behind a configuration switch: the ADR does not forbid that.
  3. The list of ADR-0057 statements is complete for apps on hearth. Not a blocker: @frostyard/lodge-client has 2 parts (client/package.json): the frame protocol between the shell and an app, and ./rpc, the JSON-RPC client of /app/<id>/api. An app on hearth still uses the frame protocol. Its API client is connect-es on /app/<id>/connect/, which this ADR already states. So the ADR-0057 sentence stays true for the frame protocol, and leaving it unchanged is correct. A later lodge ADR can record the ./rpc part when frostmarks' web UI is built.

The prefix rule 'G covers P when P is G or starts with G + /' gave the
root / no children. The root now has its own clause, with a /Chan against
/Chani example. The tool, method and line counts named no source and are
removed. AGENTS.md gains the root and boundary rule beside the count rule,
with its correction record.
@frostyard-machines frostyard-machines added the ready-for-human Reviewed, CI green: ready for Brian to review and merge label Nov 16, 2026
@bketelsen
bketelsen added this pull request to the merge queue Nov 16, 2026
Merged via the queue into main with commit 9ff8c71 Nov 16, 2026
6 checks passed
@bketelsen
bketelsen deleted the lucilla/adr-0085-hearth-lodge-hub branch November 16, 2026 03:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

level:L3 Skim ready-for-human Reviewed, CI green: ready for Brian to review and merge

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants