Session handover — 2026-07-29/30

Big multi-thread session on telep-mainframe + the tailnet. Everything below is LIVE unless marked. Canonical rolling handover is SESSION-HANDOVER; this is the self-contained snapshot for picking up cold. Related: telep-mainframe, kb-agent-api, 2026-07-30-kb-hungarian-translation-complete, 2026-07-30-kb-wiring-gallery-pivot-complete, 2026-07-29-kb-semantic-search-frontend-complete.

Access reminders (read first)

  • Always use /usr/bin/ssh on this Mac — bare ssh is broken. Box user levander@telep-mainframe; router root@100.69.112.32 (tailnet; was 100.115.194.51 before the 2026-08-03 factory reset — see 2026-08-03-telep-router-factory-reset-recovery); KB tailnet node https://knowledgebase.taild4189d.ts.net.
  • House rules: no git commit unless asked; no code comments; subagent-driven; never Sonnet.
  • PSU brown-out risk: heavy sustained CPU (esp. a full Qdrant re-embed over many manuals) resets the box. Cap OMP_NUM_THREADS=4 + nice, one heavy job at a time. For index deletions, purge Qdrant points directly (metadata delete) — do NOT full-reindex.
  • API/session limits hit repeatedly this session — long subagent grinds must be crash-safe: write output per-item immediately + skip-done resume.

Knowledgebase — current live state

Flask+waitress app on 127.0.0.1:8092 (systemd knowledgebase.service, Restart=always), fronts a mkdocs-material static site (site/) + dynamic routes. Qdrant kb-qdrant (127.0.0.1:6333, collection manuals, bge-large-en). App dir /home/levander/knowledgebase/; vectors /home/levander/kb-vectors/.

  • Semantic search (NEW, the front door): GET /api/search?q=&limit=&folder=&manual= → JSON ranked sections. / is now the search UI; /browse is the mkdocs manual tree. bge-large loaded once at app startup (~1.6 GB; warms in main()). ~54 ms warm. Replaced the broken mkdocs lunr search (“Initializing search” hang — community Material has no prebuild_index; unfixable in-config, hence the custom endpoint). Agent-facing doc: kb-agent-api.
  • Hungarian (/hu/…): prioritized manual corpus 100% translated — 820/820 pages (geo-tracker-repair 434, workshop-1988-1998 293, 5door-supplement 61, supplement-61a40 23, sidekick/wiring-1996 9, all kick-fix how-tos, consolidated). Served read-only via mkdocs-static-i18n suffix mode (<page>.hu.md siblings; English fallback). NOT search-indexed (bge is English-only). SKIPPED (low value, addable later): parts-catalogue-89-98, body-measurements, wiring-diagrams booklet, owners-1995, kickfix-docs/*.
  • Wiring: AI netlist extraction RETIRED (deemed inaccurate) — reversibly: hooks._append_wiring uncalled, 65 .wires.txt sidecars + wiring-charts.md moved to /home/levander/wiring-retired/, 2 manuals reindexed so /api/search returns 0 netlist text. REPLACED by /wiring-gallery/ — 480 curated genuine wiring SCANS (grouped vehicle→manual, thumbnails → full source scan), the accurate resource + cluzter’s tracing underlay. glightbox enabled → all images click-to-zoom full-screen (fixed the “diagrams look cut off” = they were shrunk into the narrow column).
  • Deeplinks + nav fixes: kickfix archive .html deeplinks rewritten via a hooks.py build-time pass (392 fixed, 236 dead-delinked). gen_index.py now emits per-folder/per-manual index.md so manual-root URLs (e.g. /suzuki-vitara/wiring-diagrams/) no longer 404.
  • Cleanup: 107 empty/boilerplate pages removed (1251→1144), backed up /home/levander/kb-junk-backup-20260729-182317.tgz; Qdrant points purged. Spec-table + image pages preserved (verified 158-valve-clearances kept).

Key KB paths

  • Wiring: extraction code + out/*.wiring.json (retired-but-kept) in /home/levander/wiring-extract/; retired sidecars/charts in /home/levander/wiring-retired/; gallery selection + thumbs in /home/levander/wiring-collection/.
  • Backups on box (per change): app.py.bak-*, hooks.py.bak-*, mkdocs.yml.bak-*, gen_index.py.bak-*, chunker.py.bak-wiring.

Other systems (from earlier in session)

  • Camera wall (camwall): rebuilt to 4 tiled low-latency mpv panes (was a single movie= composite with ~10–13 s lag → now ~1–2 s). Backup /usr/local/bin/camwall-mpv.sh.bak-latency. TWO OPEN REGRESSIONS: (a) watchdog freeze-detection now only covers the 1 IPC-socket-owning pane (security-relevant); (b) WiFi strip confined to the BL pane (cosmetic).
  • ÉSZAK camera (telep_cam3/cam4, dual-lens TC47 @192.168.30.139): silenced on all mainframe alarm paths — TV siren (intruder-alarm.py EXCLUDE_CAMS={telep_cam3,telep_cam4}, service later disabled entirely) + Telegram (frigate-notify frigate.cameras.exclude). The camera’s OWN onboard siren can only be toggled in the Tapo app / with the TP-Link cloud password (script staged at /home/levander/tapo-ctl/disable_alarm.py).
  • Internet “slow”: root cause was broken IPv6 — router advertised a non-routable v6 prefix → macOS Happy-Eyeballs stalled 2–7 s/site. FIXED on router: dhcp.lan RA/DHCPv6/NDP disabled + wan6 disabled (backups /etc/config/*.bak-ipv6fix). Uplink is a TP-Link NE200 fixed-wireless, double-NAT’d (undo the double-NAT is a documented open item). Net-quality logger: /home/levander/net-monitor/probe.sh (user cron, 5-min).
  • OBD2 bridge: ELM327 “OBDII” (00:1D:A5:68:98:8B, PIN 1234) → Mac RFCOMM→TCP bridge at ~/obd-bridge/obdbridge, launchd com.levander.obdbridge, exposes ELM327-over-TCP on 100.83.222.120:35000 (point an OBD app there as a WiFi adapter). Handshake verified. Recurring “phone can’t connect / RFCOMM open fails” fix (stale macOS SDP cache after the dongle power-cycles): 2026-07-30-obd2-elm327-bridge-rfcomm-fix.

Open items / next steps

  1. In flight now: 2 tiny HU faithfulness reverts on geo-tracker pages 198 (paint-mark color codes → English) + 202 (restore dropped OCR cell).
  2. Translate the SKIPPED low-value manuals if wanted (owners, parts-catalogue, etc.).
  3. Served /api help route — expose kb-agent-api.md at a stable URL so agents fetch usage live (offered, not built).
  4. camwall: fix watchdog to cover all 4 panes (per-pane IPC or framebuffer staleness) + restore full-width WiFi strip.
  5. Phase-2 search: cited-answer RAG (/api/answer); retire the mkdocs lunr search on /browse pages.
  6. Vault git-sync BLOCKED: pre-existing uncommitted changes in projects/facekom/, projects/wiring-diagram/, .gitignore refuse the startup git pull --rebase; today’s many new notes are written but uncommitted → not syncing across the two Macs. Resolve those first, then commit.
  7. Optional: undo the WAN double-NAT (bridge/DMZ the NE200); rotate the telep-cc PSK (leaked earlier).

Gotchas / lessons (reusable)

  • Crash-safe bulk generation: write each unit (page/translation) to disk the instant it’s produced + resume by skipping existing outputs. First HU bulk attempt lost everything to a mid-run API drop; after per-page flush, 3 API drops + a session-limit cost zero completed work.
  • Deletions ≠ re-embed: to drop pages from Qdrant, delete points by metadata filter (cheap) — a full re-embed browned out the PSU.
  • mkdocs-material search is client-built lunr (no community prebuild); large corpora hang on “Initializing search” — the real fix is a server-side search endpoint.
  • Scanned diagrams are the accurate wiring source; AI netlist extraction is not (1632px scans, overlapping wires → hard ceiling). Consolidate/zoom the scans; don’t ship guessed netlists to agents.
  • Concurrent build_site() race: two agents rebuilding can collide on the atomic site/ swap — sequence builds or use build-retry; stop background translation grinds before infra builds.
  • HU pages are read-only mirrors, deliberately not indexed (English embeddings).