Slash Commands
Reference for every slash command available in the fwm CLI agent REPL — project lifecycle, session management, authentication, and core TUI.
Slash commands are deterministic shortcuts inside the REPL. Press / to
open the picker. You can also just ask the agent in natural language —
the same tools are invoked under the hood.
Core TUI
| Command | Description |
|---|---|
/help | List the slash commands. |
/clear | Clear the conversation pane. |
/context | Show estimated and API-reported context-window usage. |
/quit | Exit the REPL (alias: /exit). |
Session management
| Command | Description |
|---|---|
/resume | List saved sessions. |
/resume N | Reload session N. |
/history clear | Delete all saved sessions. |
Sessions are stored at ~/.fwm/sessions/session_<unix-timestamp>.json;
the three most recent are kept. See
Session persistence.
Authentication
| Command | Description |
|---|---|
/login | Open browser, authenticate, save token to ~/.fwm/config.toml. |
/logout | Remove the stored token. |
/whoami | Show the currently authenticated user. |
Mode switching
See Agent Modes for the full reference.
| Command | Description |
|---|---|
/edit | Edit mode — full read + write access (19 tools). |
/plan | Plan mode — 11 read-only tools, produces a plan. |
/debug | Debug mode — 13 read-only datasheet-aware analysis tools. |
Project lifecycle
| Command | Description |
|---|---|
/init | Scaffold a new Zephyr / nRF Connect SDK project for any of 21 Nordic targets. |
/build | Build with auto-detected toolchain (west, cargo, cmake, idf.py, pio). |
/flash | Flash via west flash, nrfutil, nrfjprog, probe-rs, openocd, or custom command. |
/analyze | Local parsing of codebase, datasheet PDFs, and KiCad schematics. |
/validate | Run TOML-defined hardware validation sequences (CI / HIL / production). |
/targets | List every supported MCU with core, clock, flash, RAM, and default board. |
/init — scaffold a project
Project type is auto-selected from the chip's capabilities, and each target ships with a canonical Zephyr Hardware Model v2 board out of the box.
/init --target nrf52840 # BLE, C, on the nRF52840 DK
/init --target nrf9160 --name tracker # Named LTE project
/init --target nrf7002 # Wi-Fi (companion IC)
/init --target nrf52840 --language rust # Rust / Embassy
/init --target nrf52833 --language cpp # C++17
/init --target nrf52840 --rtos freertos # FreeRTOS skeleton
/init --from-docs ./docs/ # AI-driven: inspect docs, pick target + type
/init --from-docs . # Shortcut: AI-driven from current directory| Project type | Auto-selected for | Scaffolded |
|---|---|---|
| BLE | nRF52, nRF53, nRF54 | bt_enable(), bt_le_adv_start() |
| LTE | nRF91 | nrf_modem_lib_init(), lte_lc_connect() |
| Wi-Fi | nRF70 | net_mgmt callbacks |
| Thread | nRF52840, nRF5340 | OpenThread 802.15.4 |
| Matter | nRF52840, nRF5340 | Matter over Thread |
| Zigbee | nRF52840, nRF5340 | Zigbee 3.0 |
| General | Any | GPIO LED blink with GPIO_DT_SPEC_GET() |
Generated trees include the right CMakeLists.txt, prj.conf, and a
boards/<board>.overlay devicetree file — all wired up so /build
works out of the box. Rust projects produce an Embassy skeleton; C++
projects produce a C++17 skeleton; FreeRTOS produces FreeRTOSConfig.h
plus a task-creating main.c.
/build
A custom [build] command in .fwm/project.toml always wins. Otherwise
fwm auto-detects the toolchain — Zephyr (west build with the nRF
Connect SDK env auto-set), Rust (cargo build), CMake, Make, ESP-IDF,
or PlatformIO.
/build
/build --release
/build --clean
/build -- --pristine/flash
For Zephyr projects: west flash with the nCS env auto-set, after
verifying a build artifact exists. For other targets fwm prefers modern
nrfutil device program and falls back to nrfjprog, probe-rs,
openocd, pyocd, picotool, or dfu-util.
/flash
/flash --target nrf52840dk
/flash --erase
/flash --binary build/zephyr/zephyr.hex
/flash -- --runner nrfutil/analyze
Local parsing — no AI call, no authentication required. Output is saved
as JSON to .fwm/context.json (override with --output).
/analyze # defaults to --codebase .
/analyze --codebase ./some-project
/analyze --datasheet path/to/nrf52840_ps.pdf
/analyze --schematic path/to/board.kicad_sch/validate
Automated TOML-defined step sequences for CI, hardware-in-the-loop
checks, and production validation. Bundled examples include
smoke-test, binary-size, and boot-test. Reports in JUnit XML,
Markdown, or JSON.
/validate # list available sequences
/validate --init-example smoke-test # copy a bundled example
/validate -s .fwm/validations/smoke-test.toml # run a sequence
/validate -s seq.toml --report-format junit -o out/targets
Lists every supported MCU with core, clock, flash, RAM, and default board. See the overview for the family summary.
Slash commands are shortcuts when you know exactly what you want. You can also just ask the agent in natural language and it will use the same underlying tools.