Skip to content

feat([codex5-onboarding-capability-map]): capability map of connected systems#477

Merged
atomantic merged 8 commits into
mainfrom
claim/codex5-onboarding-capability-map
May 25, 2026
Merged

feat([codex5-onboarding-capability-map]): capability map of connected systems#477
atomantic merged 8 commits into
mainfrom
claim/codex5-onboarding-capability-map

Conversation

@atomantic
Copy link
Copy Markdown
Owner

Summary

Adds a Capabilities page (/capabilities, under the System nav section) that shows the status of every connected integration on one screen — doubling as a first-run setup checklist and a runtime health overview.

Implements PLAN item [codex5-onboarding-capability-map] ([P2][ONBOARDING]).

What it shows

One row per integration, each with a status tier (Ready / Degraded / Error / Not set up) and a deep link to its settings page:

Capability Signal Links to
AI Providers configured / available / unavailable counts /ai
Calendar accounts connected + enabled /calendar/config
Brain & Memory memory count + embedding provider configured /brain/config
Voice enabled + TTS/STT engines /settings/voice
Tailscale & HTTPS HTTPS on + tailnet host detected /instances
Genome & Health genome uploaded + marker/flag counts /meatspace/genome
Telegram token+chatId configured + connected /settings/telegram
Messages accounts connected + enabled /messages/config
Apps & Processes PM2 app summary (online/stopped) /apps

A header badge rolls the rows up to an overall posture (worst-wins).

Implementation

  • server/lib/capabilityMap.js — pure, side-effect-free row builders + summarizeCapabilities rollup. Fully unit-tested (capabilityMap.test.js, 29 cases). Registered in the lib barrel + README.
  • server/routes/capabilities.jsGET /api/capabilities gathers each integration's status in parallel; every source is .catch()-guarded so one broken integration degrades to "not set up" rather than 500-ing the page. Deliberately avoids live network probes (voice/embedding health have side effects) — reports config-level + already-in-memory runtime signals only. No secrets/internal paths in the response (only derived counts/booleans).
  • client/src/pages/CapabilityMap.jsx — auto-refetches every 20s; plain-div page using the default scrolling main (not full-width); mobile responsive.
  • Page registered in the nav manifest (⌘K + voice), sidebar (System section, alphabetical), and router.

Tests

  • server/lib/capabilityMap.test.js — 29 cases covering every builder's status tiers + the rollup + fail-soft degradation.
  • Existing navManifest.test.js, palette.test.js, and the lib barrel test pass (page registration covered automatically).
  • Client builds clean.

Deferred (logged in PLAN.md)

  • [extract-account-list-capability-row] — extract a shared accountListRow once a 3rd account-style integration appears (calendar + messages are identical-structure today; rule of three).

atomantic added 4 commits May 24, 2026 10:03
… systems

One page (/capabilities) showing each integration's status — Providers,
Calendar, Brain & Memory, Voice, Tailscale & HTTPS, Genome & Health,
Telegram, Messages, Apps & Processes. Each row links to its settings page.
Doubles as a setup checklist (unconfigured rows) and a runtime health
overview (ok/warn/error tiers).

- server/lib/capabilityMap.js: pure status-tier row builders + rollup (unit-tested)
- server/routes/capabilities.js: GET /api/capabilities aggregator (parallel, fail-soft)
- client/src/pages/CapabilityMap.jsx: the page, auto-refetch every 20s
- nav manifest + sidebar + route wiring
…ount-list dedup

/simplify pass: defer extracting a shared accountListRow (calendarRow +
messagesRow identical-structure, 2 callers) until a 3rd account-style row.
Also defers the providerStatus sync-throw guard into the Promise.all chain.
…failure + not-started accuracy

- Calendar/Messages rows degrade to WARN when an enabled account's
  lastSyncStatus is 'error'/'partial' (page no longer claims Ready while a
  sync is failing). Extracted the shared accountListRow helper to keep the
  fix DRY across both rows (retires the deferred rule-of-three PLAN item).
- Apps row counts notStarted PM2 apps as degraded + surfaces them in the
  summary (a registered-but-never-launched app no longer shows Ready).
- Deferred codex finding #2 (Apple Health signal) onto the existing
  [apple-health-integration-live-sync] item — that import isn't built yet.
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a new Capabilities screen (/capabilities) that aggregates config/runtime signals across integrations into a single “setup + health” overview, backed by a new server API and a pure/units-tested capability-row builder library.

Changes:

  • Added GET /api/capabilities to collect integration signals in parallel and return rows + an overall rollup.
  • Introduced server/lib/capabilityMap.js (pure row builders + rollup) with comprehensive unit tests.
  • Wired the new page into the client router, sidebar, and nav command manifest; documented in lib README + changelog.

Reviewed changes

Copilot reviewed 13 out of 13 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
server/routes/capabilities.js New API endpoint aggregating integration signals and returning capability rows + summary.
server/lib/capabilityMap.js Pure capability row builders and rollup logic used by the API.
server/lib/capabilityMap.test.js Unit tests covering status tier derivation and rollup behavior.
server/lib/index.js Exports capabilityMap from the server lib barrel.
server/lib/README.md Documents the new lib module in the public barrel list.
server/lib/navManifest.js Adds /capabilities to the System navigation commands (⌘K/voice).
server/index.js Registers the /api/capabilities route.
client/src/pages/CapabilityMap.jsx New Capabilities page UI with 20s auto-refresh and per-row deep links.
client/src/services/apiSystem.js Adds getCapabilities() client API wrapper.
client/src/App.jsx Adds route for /capabilities.
client/src/components/Layout.jsx Adds Capabilities to the System sidebar section.
PLAN.md Removes completed PLAN item and updates Apple Health note to include a future Capabilities signal.
.changelog/NEXT.md Adds release note entry for the new Capabilities page.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread server/routes/capabilities.js
Comment thread server/lib/capabilityMap.js Outdated
…ry count + empty-rollup

- CRITICAL: getMemories() returns { total, memories }, not an array, so the
  Array.isArray check made the Brain row always report 0 memories. Read
  .total instead; fallback returns { total: 0 }.
- summarizeCapabilities now reports 'unconfigured' (not 'ok') for empty/garbage
  input so an empty roll-up can't masquerade as a healthy system.
- (gemini's silent:true finding rejected — it's the documented background
  auto-refetch pattern; the page has its own 'unavailable' fallback.)
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 13 out of 13 changed files in this pull request and generated 3 comments.

Comment thread server/lib/capabilityMap.js
Comment thread server/lib/capabilityMap.js Outdated
Comment thread server/routes/capabilities.js
atomantic added 2 commits May 24, 2026 18:19
…anaged apps, all-unknown rollup, route test

- Apps row no longer reports 'No apps registered' when only native/Xcode
  (unmanaged) apps exist — getAppStatusSummary().total excludes them; show
  'N native apps · no runtime status' instead.
- summarizeCapabilities derives overall purely from counts so a non-empty list
  of unknown-status rows can't masquerade as 'ok' (was: list.length>0 ? OK).
- Add routes/capabilities.test.js covering the aggregator: row shape, the
  memoryCount-from-.total regression guard, and fail-soft (a throwing source
  degrades that row but still returns 200).
- (copilot threads on memoryCount + summarize total were already fixed in the
  prior gemini-review commit; resolved as addressed.)
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 14 out of 14 changed files in this pull request and generated 2 comments.

Comment thread server/routes/capabilities.js Outdated
Comment thread server/routes/capabilities.js
…mirror initConfig (drop enabled check)

- resolveEmbeddingProviderConfigured now keys off endpoint alone, exactly like
  memoryEmbeddings.initConfig (which ignores 'enabled'), so a disabled-but-
  endpoint'd embedding provider isn't misreported as 'no embedding provider'.
- Deferred the getMemories-count efficiency nit to [capabilities-cheap-memory-count]
  in PLAN.md (micro-opt on a cached-index 20s poll; proper fix is a memory.js count API).
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 14 out of 14 changed files in this pull request and generated no new comments.

@atomantic atomantic merged commit 86f1912 into main May 25, 2026
6 checks passed
@atomantic atomantic deleted the claim/codex5-onboarding-capability-map branch May 25, 2026 02:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants