# LifeOS Doctor Tool Capabilities: Checking and Fixing Dependencies Complete Guide

> Explore the LifeOS Doctor tool's capabilities for checking and fixing dependencies. This guide details how it diagnoses issues and provides instant, copy-paste solutions for failures.

- Repository: [Daniel Miessler 🛡️/LifeOS](https://github.com/danielmiessler/LifeOS)
- Tags: how-to-guide
- Published: 2026-08-12

---

**LifeOS Doctor is a self-contained diagnostic utility that probes external tools and services, writes a TTL-based capability manifest, and provides copy-paste fix commands for every detected failure.**

The LifeOS Doctor tool, implemented in [[`Doctor.ts`](https://github.com/danielmiessler/LifeOS/blob/main/Doctor.ts)](https://github.com/danielmiessler/LifeOS/blob/main/LifeOS/install/LIFEOS/TOOLS/Doctor.ts), serves as the central health monitor for the LifeOS ecosystem. It performs offline and network-based checks across 13+ capabilities, records results in [`capabilities.json`](https://github.com/danielmiessler/LifeOS/blob/main/capabilities.json), and emits actionable remediation commands that users can run immediately. A companion Pulse module at [[`doctor.ts`](https://github.com/danielmiessler/LifeOS/blob/main/doctor.ts)](https://github.com/danielmiessler/LifeOS/blob/main/LifeOS/install/LIFEOS/PULSE/modules/doctor.ts) exposes this data via API for UI consumption.

## Core Diagnostic Actions

LifeOS Doctor executes three primary functions: **Probe**, **Reconcile**, and **Statusline**.

### Probe: Capability Detection and Manifest Generation

The `Probe` action iterates over the `CAPS` registry and evaluates each capability through a defined lifecycle:

1. **Skip** if the capability was previously **declined**
2. **Check configuration** via the `configured()` function
3. **Execute `probeOffline`** for local validation
4. **Optionally execute `probeNetwork`** when `--network` flag is provided
5. **Record results** with timestamp, TTL, status, and `fixCmd`

```bash
bun LIFEOS/TOOLS/Doctor.ts

```

By default, this produces a formatted table showing `live`, `broken`, `declined`, or `stale` states.

### Reconcile: Hook Registration Validation

The `Reconcile` action compares hooks present on disk against those registered in [`settings.json`](https://github.com/danielmiessler/LifeOS/blob/main/settings.json). It detects:

- Unwired hooks (registered but missing files)
- Missing hooks (files present but unregistered)
- Interpreter misconfigurations

### Statusline: Prompt-Aware Health Signaling

The Pulse module consumes [`capabilities.json`](https://github.com/danielmiessler/LifeOS/blob/main/capabilities.json) and [`doctor-heartbeat.json`](https://github.com/danielmiessler/LifeOS/blob/main/doctor-heartbeat.json) to emit a concise glyph for command-line prompts, signaling only **newly-broken** capabilities (respecting the `ackedBroken` list).

## The Capability Registry

Each capability is defined in [`Doctor.ts`](https://github.com/danielmiessler/LifeOS/blob/main/Doctor.ts) with these properties:

- `id` — internal manifest key
- `title` — human-readable description
- `powers` — functionality summary
- `ttlHours` — freshness duration for cached results
- `configured()` — determines if setup is present
- `probeOffline` — local validation function
- `probeNetwork` — optional live service check
- `fixCmd` — copy-paste remediation command

## Complete Capability List and Fix Commands

| Capability | What It Checks | Failure Mode | Fix Command |
|------------|--------------|--------------|-------------|
| **shadow-home** | Orphaned memory trees from pre-#1451 installs | Legacy `$HOME/.claude/LIFEOS/MEMORY` trees exist | `bun <configRoot>/LIFEOS/TOOLS/Doctor.ts --reclaim` |
| **codex** | `codex` CLI on `$PATH` and `~/.codex/auth.json` | Binary missing or auth file absent | `bun install -g @openai/codex && codex login` |
| **interceptor** | Interceptor skills, Chrome/Brave/Chromium, CLI/daemon, `INTERCEPTOR_TEST_CONTEXT_ID` | Missing skills, browser, or test context | Run Interceptor skill setup, set `INTERCEPTOR_TEST_CONTEXT_ID`, then re-run Doctor |
| **cloudflare** | `CLOUDFLARE_API_TOKEN` and `wrangler` binary; optionally validates via `wrangler whoami` | Missing token or binary | Add `CLOUDFLARE_API_TOKEN` to `<configRoot>/.env`, then: `bun LIFEOS/TOOLS/Doctor.ts --network` |
| **voice** | `ELEVENLABS_API_KEY` and optionally `ELEVENLABS_VOICE_ID`; optionally performs TTS request | Missing credentials or API error (e.g., "famous_voice_not_permitted") | Set `ELEVENLABS_VOICE_ID` to API-permitted voice in `<configRoot>/.env` |
| **ripgrep** | `rg` binary on `$PATH` | Binary missing | `brew install ripgrep` (Linux: `sudo apt-get install ripgrep`) |
| **imagemagick** | `magick` binary on `$PATH` | Binary missing | `brew install imagemagick` (Linux: `sudo apt-get install imagemagick`) |
| **gh** | GitHub CLI `gh` on `$PATH` | Binary missing | `brew install gh && gh auth login` (Linux: see cli.github.com) |
| **ffmpeg** | `ffmpeg` binary on `$PATH` | Binary missing | `brew install ffmpeg` (Linux: `sudo apt-get install ffmpeg`) |
| **ytdlp** | `yt-dlp` binary on `$PATH` | Binary missing | `brew install yt-dlp` (Linux: `sudo apt-get install yt-dlp`) |
| **fabric** | `fabric` binary on `$PATH` | Binary missing | See fabric project for install instructions |
| **jq** | `jq` binary on `$PATH` | Binary missing | `brew install jq` (Linux: `sudo apt-get install jq`) |
| **hook-interpreters** | Executable permissions, valid shebangs, and interpreter availability for registered hooks | Non-executable script, bad shebang, or missing interpreter | `bun <configRoot>/LIFEOS/TOOLS/Doctor.ts --hooks` |

## Running Diagnostic Commands

### Basic Offline Scan

```bash
bun LIFEOS/TOOLS/Doctor.ts

```

Produces a table with status glyphs: `✅ live`, `❌ broken`, `⏸ declined`, `◌ stale`.

### Include Network Validation

```bash
bun LIFEOS/TOOLS/Doctor.ts --network

```

Enables live API calls for `cloudflare` (`wrangler whoami`) and `voice` (ElevenLabs TTS probe).

### JSON Export for Automation

```bash
bun LIFEOS/TOOLS/Doctor.ts --json > doctor-report.json

```

Outputs the full `Manifest` structure including version, `updatedAt`, capabilities array, and integrity hash.

### Opt-Out of Specific Capabilities

```bash
bun LIFEOS/TOOLS/Doctor.ts decline voice

```

Permanently silences `voice` warnings. The entry is marked `declined` in [`capabilities.json`](https://github.com/danielmiessler/LifeOS/blob/main/capabilities.json).

### Re-Enable Declared Capabilities

```bash
bun LIFEOS/TOOLS/Doctor.ts enable voice

```

Removes the `declined` flag; subsequent runs will probe the capability again.

### Acknowledge Current Failures

```bash
bun LIFEOS/TOOLS/Doctor.ts ack

```

Adds all currently broken capabilities to `ackedBroken`, suppressing the statusline glyph until a **new** regression appears.

### Diagnose Hook Interpreters

```bash
bun LIFEOS/TOOLS/Doctor.ts --hooks

```

Reports per-hook issues such as:

- `myhook.hook.ts: not executable (chmod +x)`
- `somehook.hook.sh: shebang interpreter sh not on PATH`

### Reclaim Legacy Memory Trees

```bash
bun LIFEOS/TOOLS/Doctor.ts --reclaim

```

Detects pre-#1451 shadow `$HOME/.claude/LIFEOS/MEMORY` trees, merges JSONL logs, copies missing artifacts, and moves old data to timestamped backups.

## Key Files and Their Roles

| File | Purpose | Location |
|------|---------|----------|
| [`Doctor.ts`](https://github.com/danielmiessler/LifeOS/blob/main/Doctor.ts) | Core implementation, capability definitions, CLI, manifest I/O | [`LIFEOS/install/LIFEOS/TOOLS/Doctor.ts`](https://github.com/danielmiessler/LifeOS/blob/main/LIFEOS/install/LIFEOS/TOOLS/Doctor.ts) |
| [`doctor.ts`](https://github.com/danielmiessler/LifeOS/blob/main/doctor.ts) (Pulse) | Read-only API serving manifest, heartbeat, and hook reconciliation | [`LIFEOS/install/LIFEOS/PULSE/modules/doctor.ts`](https://github.com/danielmiessler/LifeOS/blob/main/LIFEOS/install/LIFEOS/PULSE/modules/doctor.ts) |
| [`settings.json`](https://github.com/danielmiessler/LifeOS/blob/main/settings.json) | User hook registrations; inspected by `hook-interpreters` check | `~/.claude/settings.json` (user-specific) |
| [`capabilities.json`](https://github.com/danielmiessler/LifeOS/blob/main/capabilities.json) | TTL-based advisory cache with SHA-256 integrity hash | `~/.claude/LIFEOS/MEMORY/STATE/` (runtime) |
| [`doctor-heartbeat.json`](https://github.com/danielmiessler/LifeOS/blob/main/doctor-heartbeat.json) | Run timestamp and network flag record | `~/.claude/LIFEOS/MEMORY/STATE/` (runtime) |
| `.capabilities-salt` | 32-byte random salt for manifest hashing | `~/.claude/LIFEOS/MEMORY/STATE/` (runtime) |

The manifest is **write-locked** to the Doctor tool itself; the UI and Pulse module consume it read-only, ensuring single-source-of-truth integrity.

## Summary

- **LifeOS Doctor** probes 13+ capabilities ranging from CLI binaries (`rg`, `jq`, `ffmpeg`) to authenticated services (`codex`, `cloudflare`, `voice`)
- **Three action modes**: Probe (manifest generation), Reconcile (hook validation), and Statusline (prompt health glyph)
- **TTL-based caching** prevents redundant checks while keeping results fresh per-capability
- **Copy-paste fix commands** eliminate guesswork for every detected failure
- **Network probing** (`--network`) validates live service authentication without making it mandatory
- **Declarative lifecycle management** via `decline`, `enable`, and `ack` subcommands lets users curate their dependency surface

## Frequently Asked Questions

### How does LifeOS Doctor determine if a capability is broken?

LifeOS Doctor calls the `configured()` function for each capability to check whether required setup exists (binaries on `$PATH`, environment variables, auth files). If `configured()` returns false, the capability is marked **broken** immediately with its `fixCmd`. Otherwise, `probeOffline` runs to validate functionality. Network probes only execute with the `--network` flag.

### What is the difference between `declined` and `ackedBroken` states?

**Declined** (`bun Doctor.ts decline <cap>`) permanently removes a capability from consideration—the user explicitly opts out. **AckedBroken** (`bun Doctor.ts ack`) suppresses the statusline glyph for currently broken capabilities while keeping them in the manifest; new failures will still trigger alerts.

### Can I use LifeOS Doctor output in CI/CD pipelines?

Yes. Run `bun LIFEOS/TOOLS/Doctor.ts --json` to emit machine-readable output. The JSON contains the full `Manifest` type with version, timestamp, per-capability status, and fix commands. Parse the `capabilities` array to gate workflows on specific dependency availability.