| 1 | # Codewhale User Guide |
| 2 | |
| 3 | This guide is for your first hour with Codewhale. It explains the main |
| 4 | workflow, the important safety controls, and where to go next when you need a |
| 5 | complete reference. |
| 6 | |
| 7 | Codewhale has deeper reference documents for installation, configuration, |
| 8 | providers, modes, keybindings, tools, and operations. Use this page as a guided |
| 9 | walkthrough, then follow the "Next" links when you need every option. |
| 10 | |
| 11 | ## 1. Welcome to Codewhale |
| 12 | |
| 13 | Codewhale is a terminal coding agent. You run it from a workspace, give it a |
| 14 | task, and it can use structured tools to inspect files, run commands, edit |
| 15 | code, and report back with evidence. |
| 16 | |
| 17 | The important difference from a normal chat model is that Codewhale is built |
| 18 | around a harness: |
| 19 | |
| 20 | - It keeps the active workspace and session visible. |
| 21 | - It routes each turn through explicit modes and approval rules. |
| 22 | - It shows tool calls in the transcript instead of hiding the work. |
| 23 | - It can preserve sessions, fork conversations, and continue later. |
| 24 | - It can run sub-agents for focused background work. |
| 25 | |
| 26 | You can use Codewhale for small questions: |
| 27 | |
| 28 | ```text |
| 29 | Explain the authentication flow in this repository. |
| 30 | ``` |
| 31 | |
| 32 | You can also use it for multi-step work: |
| 33 | |
| 34 | ```text |
| 35 | Find the failing validation path, propose a fix, and wait for my approval |
| 36 | before editing files. |
| 37 | ``` |
| 38 | |
| 39 | For a new repository, start conservatively. Ask Codewhale to explore and plan |
| 40 | before asking it to change files. That gives you a reviewable path and makes it |
| 41 | easier to catch wrong assumptions early. |
| 42 | |
| 43 | Next: [ARCHITECTURE.md](ARCHITECTURE.md) explains the internal harness and |
| 44 | runtime model. |
| 45 | |
| 46 | ## 2. First Launch |
| 47 | |
| 48 | Install Codewhale with the path that fits your machine. Each supported install |
| 49 | path provides both the `codewhale` dispatcher and the `codewhale-tui` runtime. |
| 50 | |
| 51 | ```bash |
| 52 | # npm |
| 53 | npm install -g codewhale |
| 54 | |
| 55 | # Cargo |
| 56 | cargo install codewhale-cli --locked |
| 57 | cargo install codewhale-tui --locked |
| 58 | |
| 59 | # Homebrew, legacy installs only |
| 60 | # The tap/formula still uses the old deepseek-tui name. Prefer npm, Cargo, |
| 61 | # Docker, or direct downloads for new installs until the formula is renamed. |
| 62 | brew tap Hmbown/deepseek-tui |
| 63 | brew install deepseek-tui |
| 64 | ``` |
| 65 | |
| 66 | Docker is also available when you want an isolated runtime: |
| 67 | |
| 68 | ```bash |
| 69 | docker volume create codewhale-home |
| 70 | docker run --rm -it \ |
| 71 | -e DEEPSEEK_API_KEY="$DEEPSEEK_API_KEY" \ |
| 72 | -v codewhale-home:/home/codewhale/.codewhale \ |
| 73 | -v "$PWD:/workspace" \ |
| 74 | -w /workspace \ |
| 75 | ghcr.io/hmbown/codewhale:latest |
| 76 | ``` |
| 77 | |
| 78 | Launch Codewhale from the repository or directory you want it to work in: |
| 79 | |
| 80 | ```bash |
| 81 | codewhale |
| 82 | ``` |
| 83 | |
| 84 | On first launch, Codewhale starts with a short constitution-first setup path: |
| 85 | choose language, review provider/model readiness, review runtime posture, then |
| 86 | create or confirm your Codewhale constitution. The bundled/default |
| 87 | constitution is valid, and you can revisit the setup hub later with `/setup`. |
| 88 | |
| 89 | DeepSeek is the default provider. If you want to configure its key before or |
| 90 | after the first launch, the most direct setup path is: |
| 91 | |
| 92 | ```bash |
| 93 | codewhale auth set --provider deepseek |
| 94 | ``` |
| 95 | |
| 96 | You can also provide a key through the environment: |
| 97 | |
| 98 | ```bash |
| 99 | export DEEPSEEK_API_KEY="your-key" |
| 100 | codewhale |
| 101 | ``` |
| 102 | |
| 103 | New Codewhale config is stored under `~/.codewhale/config.toml`. Legacy |
| 104 | `~/.deepseek/config.toml` files are still supported for users migrating from |
| 105 | the old name. |
| 106 | |
| 107 | Use `/constitution` to review or change standing guidance. After setup, run a |
| 108 | doctor check: |
| 109 | |
| 110 | ```bash |
| 111 | codewhale doctor |
| 112 | ``` |
| 113 | |
| 114 | Use the JSON form when you need a machine-readable report for an issue: |
| 115 | |
| 116 | ```bash |
| 117 | codewhale doctor --json |
| 118 | ``` |
| 119 | |
| 120 | Both forms are offline by default. They report structural configuration and |
| 121 | literal unknown/not-probed credential states without loading workspace `.env` |
| 122 | credentials, opening secret/OAuth files, probing a keyring, contacting a |
| 123 | provider, or starting MCP servers. Use `--check-updates`, `--probe-api`, |
| 124 | `--probe-local`, or `--probe-mcp` only when you intentionally want that live |
| 125 | boundary. JSON remains offline and does not accept live flags. |
| 126 | |
| 127 | JSON reports credential `source` separately from literal `availability`. |
| 128 | Configured environment, external-auth, OAuth, consent, and secret-store sources |
| 129 | remain `not_probed`; their declaration alone does not make Setup or Fleet ready. |
| 130 | Only a structurally present literal config value, or a route where credentials |
| 131 | are not required, certifies offline readiness. A legacy secret-store sentinel on |
| 132 | a route that cannot use the shared store is reported separately as |
| 133 | `secret_store_unavailable`/`unavailable`, not as eligible or merely unknown. |
| 134 | |
| 135 | Both `doctor` and `doctor --json` also include a session-recovery diagnostic |
| 136 | that compares legacy session filenames against the current store and reports |
| 137 | one of `isolated`, `no_legacy_sessions`, `migration_pending`, |
| 138 | `migration_incomplete`, `migration_complete`, or `scan_failed`; it never reads |
| 139 | session contents. Use `migration_pending` or `migration_incomplete` as your |
| 140 | cue to finish moving sessions from `~/.deepseek` to `~/.codewhale`, the same |
| 141 | legacy-path migration described above. Setting an explicit `CODEWHALE_HOME` |
| 142 | suppresses this ambient inspection. |
| 143 | |
| 144 | Next: [INSTALL.md](INSTALL.md) covers platform-specific install paths, |
| 145 | [CONFIGURATION.md](CONFIGURATION.md) covers config resolution, and |
| 146 | [PROVIDERS.md](PROVIDERS.md) covers provider IDs and credentials. |
| 147 | |
| 148 | ## 3. Your First Task |
| 149 | |
| 150 | Start with a read-only task in a real workspace: |
| 151 | |
| 152 | ```text |
| 153 | Map the repository structure and tell me where the CLI entrypoint lives. |
| 154 | ``` |
| 155 | |
| 156 | Then ask for a focused plan: |
| 157 | |
| 158 | ```text |
| 159 | I want to add a small validation for empty config values. Inspect the relevant |
| 160 | code and propose the smallest safe change before editing anything. |
| 161 | ``` |
| 162 | |
| 163 | When you are ready for edits, be specific about the acceptance criteria: |
| 164 | |
| 165 | ```text |
| 166 | Implement the validation you proposed. Keep the change scoped to config |
| 167 | parsing, add or update the narrowest test, and run the relevant check. |
| 168 | ``` |
| 169 | |
| 170 | Good first prompts include four details: |
| 171 | |
| 172 | - The outcome you want. |
| 173 | - The files, feature, or behavior you care about. |
| 174 | - What is out of scope. |
| 175 | - What verification should count as done. |
| 176 | |
| 177 | For example: |
| 178 | |
| 179 | ```text |
| 180 | Fix the broken provider error message in the config loader. Do not change the |
| 181 | provider registry. Add a regression test and run only the config crate tests. |
| 182 | ``` |
| 183 | |
| 184 | If you are not sure where the bug is, say that: |
| 185 | |
| 186 | ```text |
| 187 | Investigate why `codewhale doctor` reports the wrong provider. Do not edit |
| 188 | files yet. Return the likely cause, evidence, and a proposed patch plan. |
| 189 | ``` |
| 190 | |
| 191 | Codewhale works best when you let investigation and implementation happen in |
| 192 | separate steps for unfamiliar code. For small, well-understood changes, a |
| 193 | single implementation request is fine. |
| 194 | |
| 195 | Next: [MODES.md](MODES.md) explains when to use Plan, Act, and Operate. |
| 196 | |
| 197 | ## 4. Understanding the Interface |
| 198 | |
| 199 | The interactive TUI has a few stable regions: |
| 200 | |
| 201 | - Header: current session, active model, mode, and high-level status. |
| 202 | - Transcript: the conversation, tool calls, command output summaries, and |
| 203 | model responses. |
| 204 | - Composer: where you type prompts, slash commands, and file mentions. |
| 205 | - Work bar: the strip above the transcript (or an optional side rail) that |
| 206 | holds the active goal, the to-do list, and sub-agents. Rows stay for the |
| 207 | whole session — finished work reads as done rather than disappearing — and |
| 208 | clicking a row (or pressing `Enter` on it) opens its detail. |
| 209 | - Status and footer areas: live activity, queued follow-ups, and short command |
| 210 | hints. |
| 211 | |
| 212 | The footer status line is configurable. Run `/statusline` to choose which |
| 213 | footer chips are visible, or set `[tui].status_items` in `config.toml` to |
| 214 | control both selection and order. Supported keys currently include `mode`, |
| 215 | `model`, `cost`, `balance` (DeepSeek / DeepSeekCN only), `status`, `agents`, |
| 216 | `reasoning_replay`, `prefix_stability`, `cache`, `context_percent`, |
| 217 | `git_branch`, `last_tool_elapsed` (reserved), `rate_limit` (reserved), |
| 218 | and `tokens`. Omit `status_items` to keep the built-in default order; set it to |
| 219 | `[]` to hide configurable chips. |
| 220 | |
| 221 | The transcript is the audit trail. When Codewhale reads files, runs commands, |
| 222 | or edits code, the action appears there. If a command fails, use the visible |
| 223 | failure output as part of your next instruction instead of starting over. |
| 224 | |
| 225 | The composer accepts normal prompts and slash commands. Type `/` to discover |
| 226 | available commands. Use file mentions when you want the model to focus on a |
| 227 | specific file or directory instead of searching broadly. |
| 228 | |
| 229 | The work bar is useful when a turn spans multiple steps. It keeps the goal, |
| 230 | the to-do list, and agent state visible while the transcript continues to |
| 231 | grow — including after the work settles, so you can still open what happened. |
| 232 | |
| 233 | Keyboard shortcuts vary by context, terminal, and platform. This guide avoids |
| 234 | duplicating the full shortcut catalog so it does not drift from the TUI. |
| 235 | |
| 236 | Next: [KEYBINDINGS.md](KEYBINDINGS.md) is the complete shortcut reference. |
| 237 | |
| 238 | ## 5. Modes |
| 239 | |
| 240 | Codewhale has three visible TUI modes: |
| 241 | |
| 242 | | Mode | Use it for | Default posture | |
| 243 | | --- | --- | --- | |
| 244 | | Plan | Exploration, design, and review before changes | Read-only investigation | |
| 245 | | Act | Normal multi-step coding work | Tool use with approval gates | |
| 246 | | Operate | Direct work plus parallel or background coordination | Tools follow the active posture; delegate when useful | |
| 247 | |
| 248 | Switch modes from the TUI with the mode picker: |
| 249 | |
| 250 | ```text |
| 251 | /mode |
| 252 | ``` |
| 253 | |
| 254 | Or switch directly: |
| 255 | |
| 256 | ```text |
| 257 | /mode plan |
| 258 | /mode act |
| 259 | /mode operate |
| 260 | ``` |
| 261 | |
| 262 | Plan mode is the safest place to start in an unfamiliar repository. It is for |
| 263 | inspection and decision-making, not file edits. |
| 264 | For non-trivial work, Plan mode's confirmation prompt can show a grounded |
| 265 | PlanArtifact: objective, context, sources used, critical files, constraints, |
| 266 | approach, verification plan, risks, and handoff notes. Empty sections are |
| 267 | visible when the agent uses the rich artifact shape, so you can ask for a |
| 268 | revision instead of accepting an under-specified plan. |
| 269 | |
| 270 | Act mode is the default for most contribution work. It lets Codewhale read, |
| 271 | run checks, and edit files while keeping risky actions behind approval gates. |
| 272 | |
| 273 | Operate keeps that direct tool surface and its approval, sandbox, shell, |
| 274 | ask-rule, and repository protections. Its difference is orchestration emphasis: |
| 275 | Codewhale prefers Fleet workers for independent, parallel, background, or |
| 276 | long-running work, while small or tightly coupled work can remain in the parent. |
| 277 | |
| 278 | For trusted workspaces where you intentionally want actions to proceed without |
| 279 | approval prompts, select the Full Access permission posture with `Shift+Tab`. |
| 280 | Do not use Full Access in a repository you do not trust. |
| 281 | |
| 282 | Modes are separate from model routing. `Tab` cycles visible modes when the |
| 283 | composer is idle, while `/model auto` controls model and thinking selection for |
| 284 | turns. |
| 285 | |
| 286 | You can also change approval behavior from `/config` by editing the approval |
| 287 | mode. Use this only when you understand how it changes tool execution. |
| 288 | |
| 289 | Next: [MODES.md](MODES.md) has the full mode, approval, and trust-mode |
| 290 | reference. |
| 291 | |
| 292 | ## 6. Slash Commands |
| 293 | |
| 294 | Slash commands are typed into the composer. They are useful when you want to |
| 295 | change Codewhale state directly instead of asking the model in natural |
| 296 | language. |
| 297 | |
| 298 | Common commands for first-time users: |
| 299 | |
| 300 | | Command | Use | |
| 301 | | --- | --- | |
| 302 | | `/mode` | Open the mode picker or switch with `/mode agent` | |
| 303 | | `/model` | Select a model or use `/model auto` | |
| 304 | | `/provider` | Pick the active API provider | |
| 305 | | `/fleet` | Configure Fleet roles or open worker status | |
| 306 | | `/workflow` | Orchestrate the current work as a Workflow | |
| 307 | | `/config` | Edit runtime and provider settings | |
| 308 | | `/statusline` | Choose which footer status chips are visible | |
| 309 | | `/compact` | Summarize long context to recover token budget | |
| 310 | | `/review` | Ask for a structured review workflow | |
| 311 | | `/memory` | Inspect or manage memory when enabled | |
| 312 | | `/mcp` | Configure or inspect MCP server integration | |
| 313 | | `/plugin` | Review and manage disabled-by-default local plugin bundles | |
| 314 | | `/rc` | Hand this exact session to the signed-in Codewhale web app | |
| 315 | |
| 316 | Toolbox commands stay searchable when you type them directly: `/models` |
| 317 | fetches live endpoint IDs, `/modeldb` opens the bundled model reference, and |
| 318 | `/rlm` loads a file or block of text into a working context that stays |
| 319 | available for the rest of the session. |
| 320 | |
| 321 | Use `/provider` when you want to switch away from the default DeepSeek route. |
| 322 | Provider IDs, environment variables, model defaults, and capability notes are |
| 323 | kept in the provider registry document. |
| 324 | |
| 325 | Soft-auto multi-agent work: [AUTOMATIC_WORKFLOWS.md](AUTOMATIC_WORKFLOWS.md). |
| 326 | |
| 327 | Next for durable multi-worker work: [FLEET_WORKFLOW_TUTORIAL.md](FLEET_WORKFLOW_TUTORIAL.md) |
| 328 | walks through Fleet task specs, monitoring, and Workflow authoring. |
| 329 | |
| 330 | Use `/model auto` when you want Codewhale to choose the model and thinking |
| 331 | level per turn. When the DeepSeek routing model is available, Auto may select |
| 332 | any runnable provider/model pair in the redacted inventory. That classification |
| 333 | sends the latest request (capped at 4,000 characters) plus a bounded summary of |
| 334 | up to six recent context rows (900 characters each) to |
| 335 | `DeepSeek / deepseek-v4-flash`. Credentials, endpoints, and provider error text |
| 336 | are not included in the inventory. Without that router, Auto uses a local, |
| 337 | provider-aware heuristic and sends no routing request. If a classifier attempt |
| 338 | fails validation or errors, Auto falls back to that heuristic while retaining |
| 339 | the attempted classifier data path in the turn receipt. |
| 340 | |
| 341 | The `/model` picker states which data path is available and shows the last |
| 342 | resolved route. `Ctrl+O` opens the reasoning detail for the selected or current |
| 343 | turn; `Ctrl+Alt+O` (or `/turn inspect`) opens the whole-turn Turn Inspector, |
| 344 | whose model-route section records the concrete provider/model, strong/fast pair, |
| 345 | selected tier, selection scope, route reason, and whether the classifier received |
| 346 | routing context. Use a |
| 347 | fixed model when you need repeatable comparisons, a strict provider boundary, |
| 348 | or no classification request. |
| 349 | |
| 350 | Use `/compact` when a session gets long and the model starts carrying too much |
| 351 | history. Compaction trades raw transcript detail for a concise working summary. |
| 352 | |
| 353 | This guide intentionally does not list every command. The command surface |
| 354 | changes more often than the onboarding flow, and the TUI command palette is the |
| 355 | source of truth while you are inside a session. |
| 356 | |
| 357 | Next: [CONFIGURATION.md](CONFIGURATION.md) covers runtime settings and |
| 358 | [MCP.md](MCP.md) covers Model Context Protocol integration. |
| 359 | [PLUGIN_BUNDLES.md](PLUGIN_BUNDLES.md) covers the disabled-by-default bundle |
| 360 | inventory, capability review, and namespaced Skill/MCP activation boundary. |
| 361 | |
| 362 | ## 7. Working with Tools |
| 363 | |
| 364 | Codewhale tools are structured actions. Instead of only producing prose, the |
| 365 | model can call tools to inspect and change the workspace. |
| 366 | |
| 367 | Examples of tool-backed work include: |
| 368 | |
| 369 | - Reading a file before explaining it. |
| 370 | - Searching for call sites before proposing a refactor. |
| 371 | - Running a focused test command. |
| 372 | - Applying a small patch. |
| 373 | - Opening a sub-agent for parallel investigation. |
| 374 | |
| 375 | Tool use is governed by mode, approvals, and sandbox policy. The exact behavior |
| 376 | depends on the current mode and config, but the basic rule is simple: start in |
| 377 | Plan for read-only exploration, use Act for normal changes, and reserve Full |
| 378 | Access for trusted automation. |
| 379 | |
| 380 | The workspace boundary matters. Codewhale is expected to work in the directory |
| 381 | you launched it from or the workspace you configured. Be explicit when a task |
| 382 | should stay inside a repo: |
| 383 | |
| 384 | ```text |
| 385 | Only inspect and edit files under this repository. Do not touch parent |
| 386 | directories or global config. |
| 387 | ``` |
| 388 | |
| 389 | When a command needs network, writes outside the workspace, or a risky shell |
| 390 | operation, expect an approval prompt unless you have configured more permissive |
| 391 | behavior. |
| 392 | |
| 393 | Good tool instructions are concrete: |
| 394 | |
| 395 | ```text |
| 396 | Run the narrowest test that covers this parser change. If it fails, report the |
| 397 | failure and stop before broadening the test scope. |
| 398 | ``` |
| 399 | |
| 400 | Avoid asking for broad cleanup during a focused fix. Smaller tool scopes make |
| 401 | the transcript easier to review and the final diff easier to merge. |
| 402 | |
| 403 | Next: [TOOL_SURFACE.md](TOOL_SURFACE.md) lists the tool surface and |
| 404 | [SANDBOX.md](SANDBOX.md) explains sandbox behavior. |
| 405 | |
| 406 | ## 8. Sub-agents and Parallel Work |
| 407 | |
| 408 | Sub-agents are background child agents. The parent session gives a child a |
| 409 | focused task, receives an agent id, and can continue working while the child |
| 410 | runs. |
| 411 | |
| 412 | The main orchestration tool is: |
| 413 | |
| 414 | - `agent`: start a focused child with a task and role. The child runs in the |
| 415 | background and returns a compact receipt plus transcript handle. |
| 416 | |
| 417 | You normally do not need to call these tools directly. Ask for parallel work in |
| 418 | plain language: |
| 419 | |
| 420 | ```text |
| 421 | Open one read-only explorer for the config crate and another for the TUI |
| 422 | provider picker. Have both return file references and risks before we plan the |
| 423 | fix. |
| 424 | ``` |
| 425 | |
| 426 | Useful roles include: |
| 427 | |
| 428 | | Role | Good for | |
| 429 | | --- | --- | |
| 430 | | `general` | Multi-step tasks; the default when no role is specified | |
| 431 | | `explore` | Read-only code mapping | |
| 432 | | `plan` | Design and migration planning | |
| 433 | | `review` | Bug-focused review of an existing change | |
| 434 | | `implementer` | A tightly specified edit | |
| 435 | | `verifier` | Running checks and reporting pass/fail evidence | |
| 436 | |
| 437 | Sub-agents are most useful when work can be separated cleanly. Do not use them |
| 438 | for tiny edits, and do not ask multiple agents to write the same files at the |
| 439 | same time. |
| 440 | |
| 441 | ### How long work stays coherent |
| 442 | |
| 443 | Work that spans many turns does not rely on an ever-growing chat transcript. |
| 444 | This is ordinary Agent behavior — there is nothing to turn on and no separate |
| 445 | workflow to learn: |
| 446 | |
| 447 | - A working context stays loaded for the session. Large source material and the |
| 448 | durable transcript are held as data the agent can search and slice, and useful |
| 449 | variables and imports survive across turns. |
| 450 | - Workflow composes independent `task(...)` calls and parallel fan-out. |
| 451 | - `agent` messages and follow-ups coordinate active children directly. |
| 452 | - Goals retain the durable objective across the work. |
| 453 | |
| 454 | `/rlm <file-or-text>` points that working context at a specific file or block |
| 455 | of text. The historic action-shaped `rlm` tool remains registered only so older |
| 456 | sessions replay, and is deliberately not taught to new model turns. |
| 457 | |
| 458 | Codewhale can also keep a small project-local ledger at |
| 459 | `.codewhale/harness/state.json`: evidence-backed prompt notes, reusable child |
| 460 | briefs, and skill-routing hints. Later turns receive it as untrusted |
| 461 | supplemental guidance, never as authority or executable instructions. Reading it |
| 462 | is automatic; adding or removing an entry goes through the normal approval |
| 463 | receipt. It is separate from personal memory, and it must never hold secrets, |
| 464 | scratch transcripts, or unverified claims. |
| 465 | |
| 466 | Next: [SUBAGENTS.md](SUBAGENTS.md) covers roles, lifecycle, concurrency, and |
| 467 | output contracts. |
| 468 | |
| 469 | ## 9. Skills |
| 470 | |
| 471 | Skills are reusable instruction packs. A skill is usually a `SKILL.md` file |
| 472 | that teaches Codewhale how to perform a recurring workflow, use a tool family, |
| 473 | or follow a project convention. |
| 474 | |
| 475 | Use skills when a task has a repeatable process: |
| 476 | |
| 477 | - Reviewing a specific kind of PR. |
| 478 | - Working with a document or spreadsheet format. |
| 479 | - Following a team release checklist. |
| 480 | - Using a project-specific memory or wiki workflow. |
| 481 | |
| 482 | Inside the TUI, `/skill <name>` activates a skill when one is available, and |
| 483 | bare `/skills` opens the Skills Manager (owned-only inventory, no network). Use |
| 484 | `/skills <prefix>`, `/skills inspect`, `/skills --remote`, `/skills suggest <task>`, |
| 485 | or `/skills sync` for the text/registry paths. Suggestions rank the remote |
| 486 | catalog but never install or activate anything. The command palette can also |
| 487 | surface skill entries alongside normal slash commands. |
| 488 | |
| 489 | Good skills are narrow. They should tell the model what workflow to follow, |
| 490 | what evidence to collect, and what to avoid. They should not hide credentials |
| 491 | or replace normal repository documentation. |
| 492 | |
| 493 | If a repository has its own instructions, treat them as part of the active |
| 494 | work. Read the local guidance before editing, and keep any contribution within |
| 495 | the repository's conventions. |
| 496 | |
| 497 | Next: see [SKILLS.md](SKILLS.md) for the manager, ownership, and provenance |
| 498 | rules; [CLAUDE_PLUGIN_COMPAT.md](CLAUDE_PLUGIN_COMPAT.md) for Claude Code |
| 499 | skill/plugin compatibility; and [CONFIGURATION.md](CONFIGURATION.md) for config |
| 500 | paths and project authority. |
| 501 | |
| 502 | ## 10. Getting Help |
| 503 | |
| 504 | Start with doctor output: |
| 505 | |
| 506 | ```bash |
| 507 | codewhale doctor |
| 508 | ``` |
| 509 | |
| 510 | Use JSON when filing a detailed issue: |
| 511 | |
| 512 | ```bash |
| 513 | codewhale doctor --json |
| 514 | ``` |
| 515 | |
| 516 | For authentication problems, use the structural source state to identify what |
| 517 | is declared. Doctor deliberately does not inspect environment, secret-store, |
| 518 | keyring, or OAuth token values. When a live check is appropriate, opt in with |
| 519 | `codewhale doctor --probe-api` (or `--probe-local` for a local endpoint). |
| 520 | |
| 521 | For provider problems, confirm the active provider and model: |
| 522 | |
| 523 | ```text |
| 524 | /provider |
| 525 | /model |
| 526 | ``` |
| 527 | |
| 528 | For long or confusing sessions, use `/compact` to reduce context pressure, or |
| 529 | start a fresh session in the same workspace and summarize what you need. |
| 530 | |
| 531 | When reporting an issue, include: |
| 532 | |
| 533 | - Codewhale version. |
| 534 | - Install method. |
| 535 | - Operating system and terminal. |
| 536 | - Provider and model. |
| 537 | - The exact command or prompt. |
| 538 | - Relevant doctor output. |
| 539 | - Whether the problem happens in a fresh workspace. |
| 540 | |
| 541 | Do not paste API keys, private source code, or secrets into a public issue. |
| 542 | |
| 543 | Next: [OPERATIONS_RUNBOOK.md](OPERATIONS_RUNBOOK.md) has operational triage and |
| 544 | recovery steps. |
| 545 | |
| 546 | ## FAQ |
| 547 | |
| 548 | ### Is Codewhale only for DeepSeek? |
| 549 | |
| 550 | DeepSeek is the default and first-class route, but Codewhale also supports |
| 551 | other hosted and local OpenAI-compatible providers. Use `/provider` or |
| 552 | `codewhale --provider <id>` to choose a provider. Keep the provider registry |
| 553 | open when configuring a non-default route. |
| 554 | |
| 555 | ### Which mode should I use first? |
| 556 | |
| 557 | Use Plan for unfamiliar code, Act for normal implementation, and Full Access |
| 558 | only for trusted repositories where automatic execution is acceptable. |
| 559 | |
| 560 | ### Why does Codewhale ask before running commands? |
| 561 | |
| 562 | Approvals are part of the safety model. Shell commands, paid tools, writes, and |
| 563 | actions outside the expected workspace can have side effects. Approval prompts |
| 564 | let you keep control while still letting the model do useful work. |
| 565 | |
| 566 | ### How do I run a Python file on macOS? |
| 567 | |
| 568 | Open Terminal in the folder that contains the file and run: |
| 569 | |
| 570 | ```bash |
| 571 | python3 your_file.py |
| 572 | ``` |
| 573 | |
| 574 | If macOS says `python3` is missing, install Python from |
| 575 | [python.org](https://www.python.org/downloads/macos/) or with Homebrew: |
| 576 | |
| 577 | ```bash |
| 578 | brew install python |
| 579 | ``` |
| 580 | |
| 581 | Inside Codewhale, ask the agent to inspect the file and run it with |
| 582 | `python3 your_file.py`. If the script needs packages, install them in a virtual |
| 583 | environment first: |
| 584 | |
| 585 | ```bash |
| 586 | python3 -m venv .venv |
| 587 | source .venv/bin/activate |
| 588 | python3 -m pip install -r requirements.txt |
| 589 | python3 your_file.py |
| 590 | ``` |
| 591 | |
| 592 | ### Where is my config stored? |
| 593 | |
| 594 | New Codewhale config uses `~/.codewhale/config.toml`. Legacy |
| 595 | `~/.deepseek/config.toml` remains supported for compatibility. Project overlays |
| 596 | can also affect behavior when a workspace config exists. |
| 597 | |
| 598 | ### How do I keep costs predictable? |
| 599 | |
| 600 | Use `/model auto` for routing, choose a fixed model when you need a strict |
| 601 | profile, and compact long sessions. For larger tasks, ask Codewhale to plan |
| 602 | before implementing so you do not spend tokens on the wrong path. |
| 603 | |
| 604 | ### How do I continue previous work? |
| 605 | |
| 606 | Codewhale saves sessions. Use the session picker or resume/continue CLI paths |
| 607 | documented in the README and modes guide. For a risky experiment, fork the |
| 608 | session before changing direction. |
| 609 | |
| 610 | The `/sessions` picker starts scoped to the current workspace so resumes stay |
| 611 | attached to the project you opened. Press `a` in the picker to show sessions |
| 612 | from every workspace, or run `codewhale sessions` to list all saved sessions |
| 613 | with last-updated timestamps before resuming a specific id. |
| 614 | |
| 615 | To continue the exact running session from the web app, type `/rc` or launch |
| 616 | with `codewhale rc`. Approve the one-time code in the system browser. While the |
| 617 | lease is active, the browser owns new prompts and approvals and the terminal is |
| 618 | a readable safety surface; `/rc status` shows ownership, `/rc stop` returns it |
| 619 | to the terminal, and interrupt remains available. A dropped connection keeps |
| 620 | local input locked until the last web lease expires so two controllers never |
| 621 | race. |
| 622 | |
| 623 | ### What should I do when the model gets confused? |
| 624 | |
| 625 | Stop and restate the goal, constraints, and current evidence. If the transcript |
| 626 | is long, use `/compact` or start a fresh session with a short handoff. If the |
| 627 | problem is operational, run `codewhale doctor` and inspect the reported config |
| 628 | and provider state. |
| 629 | |
| 630 | ### Should I put project rules in prompts or files? |
| 631 | |
| 632 | Use repository files for durable project rules and prompts for turn-specific |
| 633 | intent. If a workflow repeats across projects, consider turning it into a |
| 634 | skill. |
| 635 | |
| 636 | ### Can Codewhale edit files outside the current repository? |
| 637 | |
| 638 | That depends on workspace boundaries, sandbox settings, trust mode, and |
| 639 | approval policy. For contribution work, keep instructions scoped to the current |
| 640 | repository unless you intentionally need something else. |
| 641 | |
| 642 | ### Where should I go after this guide? |
| 643 | |
| 644 | Read the focused reference for the thing you are changing. For most users, the |
| 645 | next pages are install, configuration, providers, modes, keybindings, tools, |
| 646 | and sub-agents. |
| 647 | |
| 648 | Next: [INSTALL.md](INSTALL.md), [CONFIGURATION.md](CONFIGURATION.md), |
| 649 | [PROVIDERS.md](PROVIDERS.md), [MODES.md](MODES.md), and |
| 650 | [TOOL_SURFACE.md](TOOL_SURFACE.md). |
| 651 |