Skip to content

Self-hosted, Self-Improving, Federated Everything App — dev management, agent orchestration, persistent mind, digital twin, second brain, and creative pipeline from a single dashboard over Tailscale to port the user into the OS

reorganize docs: move design spike and pre-build audit out of features/, fix stale claims

[._.]/ Adam Eivy7284a807d59a
diff --git a/.changelog/NEXT.md b/.changelog/NEXT.md
index 7f39a644f3..9242378643 100644
--- a/.changelog/NEXT.md
+++ b/.changelog/NEXT.md
@@ -35,6 +35,7 @@
## Internal
- Deflaked the `UpdateTab reconcile flow` tests, which intermittently failed CI with "Unable to find role=button and name 'Restarting...'" (#2065). The component mirrors `updating` into `updatingRef` via a passive effect, and the disconnect handler's guard reads that ref synchronously; since `runUpdate()` calls `setUpdating(true)` outside any `act` (after awaiting the pre-update health check), the "Reconciling..." button could commit — satisfying the test's `waitFor` — a scheduler tick before the ref-sync effect ran, leaving the ref stale-false when `disconnect` fired so the confirmation timer never armed. The test now flushes pending effects (`await act(async () => {})`) before firing `disconnect`, syncing the ref to the state production always reaches over real network time. Test-only change; no product behavior touched.
+- Docs audit and reorganization: reclassified two non-feature docs out of `docs/features/` — the cross-domain insights design spike now lives at `docs/plans/2026-06-03-cross-domain-insights-engine.md` (it specs future work, it isn't feature documentation) and the OpenClaw pre-implementation extension-point audit at `docs/research/2026-03-31-openclaw-operator-chat-audit.md` (it's an explicitly-unmaintained investigation record). `docs/README.md` links updated. Also fixed `docs/PORTS.md` claiming the `PORTS` object is "re-exported at `server/lib/ports.js`" (it's a manually-synced mirror — the ESM server can't `require()` the CommonJS config), replaced a dead `#m7-app-templates` anchor in `docs/features/app-wizard.md` with a real pointer to `GET /api/scaffold/templates`, and refreshed the stale example model IDs in `docs/TROUBLESHOOTING.md`. The audit verified every other doc against the code: all 13 top-level guides are indexed and accurate, every feature doc's modules/routes/nav entries resolve, and plans/decisions/research/superpowers/themes/examples/media have zero orphans or broken links.
- Consolidated five component-local duration/uptime/time-until formatters onto the shared `utils/formatters.js` helpers (`formatDurationMs`, `timeUntil`), per the "do not re-define formatters inside components" convention (#2028). `formatDurationMs` gained a day bucket (`2d 3h`) so long uptimes no longer render as an unbounded hours count; ProcessesTab, CityHud, Shell session ages, the CoS QuickSummary "next job" countdown, and the Loops interval label now all route through the shared helpers, and a `console.log` in `memoryClassifier.js` was collapsed to a single interpolated line.
- Migration 155 heals `data/prompts/stages/cd-treatment.md` installs that #1808's anchor-based migration 148 left stranded (#2042). Installs seeded before the `imageStrength` scene knob (older pre-#1808 template) got the `## Cast & ingredients` list but missed the per-scene `"cast": [{ "ingredientId": … }]` field, so the Creative Director cast-threading regression test stayed red on the runtime template and migration 148 (already applied) never re-ran. The new hash-driven prompt-replace upgrades those copies (and both pristine pre-#1808 shipped versions) to the current shipped reference, leaving hand-customized copies untouched. Also folds `cd-treatment.md` into `buildPromptDriftTables` so setup-data.js's drift warning classifies a stranded copy correctly.
- Replaced the last hardcoded `port-*` hex stragglers with design tokens (#2031). The Security page's audio-level meter used raw `#ef4444`/`#f59e0b`/`#22c55e` in an inline `backgroundColor`; these now resolve through `rgb(var(--port-error))`/`--port-warning`/`--port-success` so they track the theme. The Chief-of-Staff page's "CoS" wordmark gradient was duplicated inline three times and is now a single module-level `COS_TITLE_GRADIENT` constant. Visual output is unchanged.
diff --git a/docs/PORTS.md b/docs/PORTS.md
index 282e98f4f7..a03358996c 100644
--- a/docs/PORTS.md
+++ b/docs/PORTS.md
@@ -7,7 +7,7 @@ PortOS uses a contiguous port allocation scheme to make it easy to understand wh
### Convention
1. **Contiguous Ranges**: Each app should use a contiguous block of ports
-2. **Labeled Ports**: Define all ports in the top-level `PORTS` object in `ecosystem.config.cjs` (re-exported at `server/lib/ports.js`); the per-process label map lives in `server/services/apps.js`
+2. **Labeled Ports**: Define all ports in the top-level `PORTS` object in `ecosystem.config.cjs` (mirrored — manually kept in sync — in `server/lib/ports.js`, since the ESM server can't `require()` the CommonJS config); the per-process label map lives in `server/services/apps.js`
3. **No Gaps**: Avoid leaving gaps between port allocations within an app
### Port Labels
diff --git a/docs/README.md b/docs/README.md
index 2fb48c07aa..5d84d05161 100644
--- a/docs/README.md
+++ b/docs/README.md
@@ -26,13 +26,13 @@ App management: [app-wizard](./features/app-wizard.md) · [autofixer](./features
Chief of Staff: [chief-of-staff](./features/chief-of-staff.md) · [cos-agent-runner](./features/cos-agent-runner.md) · [cos-enhancement](./features/cos-enhancement.md) · [agent-skills](./features/agent-skills.md) · [memory-system](./features/memory-system.md) · [claude-ollama](./features/claude-ollama.md) · [prompt-manager](./features/prompt-manager.md)
-Identity & self: [digital-twin](./features/digital-twin.md) · [identity-system](./features/identity-system.md) · [soul-system](./features/soul-system.md) · [cross-domain-insights-engine](./features/cross-domain-insights-engine.md) · [post](./features/post.md)
+Identity & self: [digital-twin](./features/digital-twin.md) · [identity-system](./features/identity-system.md) · [soul-system](./features/soul-system.md) · [post](./features/post.md) (insights design spike: [plans/2026-06-03](./plans/2026-06-03-cross-domain-insights-engine.md))
Knowledge: [brain-system](./features/brain-system.md) · [messages-security](./features/messages-security.md)
Create: [writers-room](./features/writers-room.md) · [cybercity-v2](./features/cybercity-v2.md)
-Comms & voice: [openclaw-operator-chat](./features/openclaw-operator-chat.md) ([pre-build audit](./features/openclaw-operator-chat-audit.md)) · [voice](./features/voice.md)
+Comms & voice: [openclaw-operator-chat](./features/openclaw-operator-chat.md) ([pre-build audit](./research/2026-03-31-openclaw-operator-chat-audit.md)) · [voice](./features/voice.md)
## Point-in-time records
diff --git a/docs/TROUBLESHOOTING.md b/docs/TROUBLESHOOTING.md
index af70271082..d60ccdc7d0 100644
--- a/docs/TROUBLESHOOTING.md
+++ b/docs/TROUBLESHOOTING.md
@@ -102,8 +102,8 @@ claude --version
- Verify model name matches provider's available models
- Check provider documentation for correct model identifiers
- Common models:
- - Claude: `claude-sonnet-4-20250514`, `claude-opus-4-5-20251101`
- - OpenAI: `gpt-4`, `gpt-4-turbo`
+ - Claude: `claude-sonnet-5`, `claude-opus-4-8`, `claude-haiku-4-5-20251001`
+ - OpenAI: `gpt-5`, `gpt-5-mini`
- Ollama: Model must be pulled first (`ollama pull llama3`)
## Chief of Staff Issues
diff --git a/docs/features/app-wizard.md b/docs/features/app-wizard.md
index f156ee8876..8c0a999d9d 100644
--- a/docs/features/app-wizard.md
+++ b/docs/features/app-wizard.md
@@ -64,4 +64,4 @@ Scaffold a new project from template:
- [PM2 Configuration](../PM2.md)
- [Port Allocation](../PORTS.md)
-- [Templates System](#m7-app-templates)
+- Scaffold templates — `GET /api/scaffold/templates` (`server/routes/scaffold.js`)
diff --git a/docs/features/cross-domain-insights-engine.md b/docs/plans/2026-06-03-cross-domain-insights-engine.md
similarity index 98%
rename from docs/features/cross-domain-insights-engine.md
rename to docs/plans/2026-06-03-cross-domain-insights-engine.md
index dfeb13763b..c1a6b2baa0 100644
--- a/docs/features/cross-domain-insights-engine.md
+++ b/docs/plans/2026-06-03-cross-domain-insights-engine.md
@@ -299,6 +299,6 @@ A future `/claim` can pick these up in order. Each phase is independently shippa
## Related features
-- [Digital Twin](./digital-twin.md) — taste/identity/personality source
-- [Identity System](./identity-system.md) — goals, autobiography, the `/ask` loop
-- [Brain System](./brain-system.md) — daily digest + weekly review push channel
+- [Digital Twin](../features/digital-twin.md) — taste/identity/personality source
+- [Identity System](../features/identity-system.md) — goals, autobiography, the `/ask` loop
+- [Brain System](../features/brain-system.md) — daily digest + weekly review push channel
diff --git a/docs/features/openclaw-operator-chat-audit.md b/docs/research/2026-03-31-openclaw-operator-chat-audit.md
similarity index 100%
rename from docs/features/openclaw-operator-chat-audit.md
rename to docs/research/2026-03-31-openclaw-operator-chat-audit.md