Files
homelab/hosts/mars/honcho-console.nix
T
darmanandClaude Opus 5.5 0e00512773 feat(mars): honcho-console phase 4 — hermes recall preview
Tells the console Hermes' user and AI peers, as hermes-agent.nix writes
them into honcho.json, for the "what luna sees" preview.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-03 00:38:59 +02:00

44 lines
1.8 KiB
Nix

{ config, inputs, ... }:
# Web console for luna's Honcho (honcho.nix). Bound on all interfaces but
# its port stays closed in the firewall, so like Hermes' dashboard it is
# reachable over tailscale0 only: http://mars.orbit.sol:8095. It can rewrite
# luna's memory, so it stays off the LAN and off neptun.
let
# Honcho's own model settings, so cost per stage tracks honcho.nix.
env = config.virtualisation.oci-containers.containers.honcho-api.environment;
level = l: env."DIALECTIC_LEVELS__${l}__MODEL_CONFIG__MODEL";
in
{
imports = [ inputs.honcho-console.nixosModules.default ];
services.honcho-console = {
enable = true;
listen = "0.0.0.0:8095";
# Unlocks the UI toggle only; every start is still read-only.
allowWrites = true;
cardSnapshotInterval = "15m";
representationSnapshotInterval = "24h";
stageModels = {
"deriver.ingestion" = env.DERIVER_MODEL_CONFIG__MODEL;
"deriver.summary" = env.SUMMARY_MODEL_CONFIG__MODEL;
"dreamer.deduction" = env.DREAM_DEDUCTION_MODEL_CONFIG__MODEL;
# card_refresh reuses the deduction model.
"dreamer.card_refresh" = env.DREAM_DEDUCTION_MODEL_CONFIG__MODEL;
"dreamer.induction" = env.DREAM_INDUCTION_MODEL_CONFIG__MODEL;
} // builtins.listToAttrs (map (l: { name = "dialectic.${l}"; value = level l; })
[ "minimal" "low" "medium" "high" "max" ]);
# Honcho's key, used by nothing else: its usage is Honcho's actual spend.
openrouterKeyFile = config.sops.secrets.openrouter_api_key.path;
# As hermes-agent.nix writes them into honcho.json; the rest are Hermes' defaults.
hermes = {
userPeer = "darman";
aiPeer = "luna";
};
};
# Honcho's tables must exist before the grant covers them.
systemd.services.honcho-console-grants.after = [ "podman-honcho-api.service" ];
}