Commit 24ab785
committed
v0.7.0
# v0.7.0 — Craft CLI, Headless Server & Architecture Overhaul
---
## Craft CLI
A new terminal client for running agent sessions from the command line — no GUI required.
- **`craft-cli run`** — launch agent sessions directly from your terminal with prompt input and streaming output
- **Multi-provider support** — select between multiple LLM connections and models from the CLI
- **CI workspace support** — create and manage workspaces programmatically for automated workflows
- **`--validate-server`** — verify server configuration with prettified diagnostic output
- **Redesigned spinner** — stays visible during agent thinking for better terminal UX
### Why it's cool
This is the first step toward full programmatic control of Craft Agents. Script your agent workflows, integrate into CI/CD pipelines, or run sessions headlessly on remote machines. Partially addresses [#343](#343).
## Headless Server
Run Craft Agents as a standalone server without the Electron desktop app — deploy on any machine, connect from any client.
- **Standalone Bun server** — headless entry point that runs without Electron, with sharp eliminated from the bundle
- **TLS support** — secure remote connections with automatic certificate handling
- **Multi-platform build script** — distribution packaging for Linux, macOS, and Windows
- **Remote mode via env vars** — configure headless operation through environment variables
- **Thin-client connection state** — WebSocket connection status and failure banners in the client
### Why it's cool
Deploy Craft Agents on a remote server and connect from anywhere. Run it on your home lab, a cloud VM, or a CI runner. The thin-client mode means the browser UI stays lightweight while all the heavy lifting happens server-side. Partially addresses [#291](#291).
## Transport & Architecture
The entire inter-process communication layer has been rebuilt from the ground up.
- **WebSocket-only RPC** — replaced Electron IPC with WebSocket RPC for all communication, enabling remote operation
- **Bidirectional RPC** — typed push events, server-owned OAuth token management
- **Server-core extraction** — 14 core handlers, session management, services, and domain utilities extracted into `@craft-agent/server-core` for reuse across Electron and headless
- **Protocol formalization** — channels, DTOs, and event maps extracted to `@craft-agent/shared/protocol` with wire-format stability tests
- **Split-brain cleanup** — removed dead handler/session copies, added `IWindowManager` and channel advertisement
### Why it's cool
This is the foundation that makes CLI, headless server, and future remote/mobile clients possible. The architecture is now cleanly split between reusable server-core logic and platform-specific shells (Electron, Bun server, CLI).
## Editor & UI
- **Rich block interactions** — tiptap image support, slash menu for inserting content blocks, and theme fallback
- **Model fallback chain** — automatic fallback between models when one is unavailable, with improved playground theming
- **Browser tooling** — better lifecycle management, metadata badge components, and safe-mode boundaries
## Security
- **Block unencrypted WebSocket** — remote connections now require `wss://` (TLS); plaintext `ws://` is rejected
- **Certificate generation** — fixed curve name in cert generation script
## Bug Fixes
- **Pi 3-tier model persistence** — fixed model save/hydration for Best/Balanced/Fast tiers. Fixes [#336](#336)
- **Multi-panel input focus** — fixed focus scoping and race handling that caused keystrokes to jump between panels. Fixes [#339](#339)
- **Pi Azure base URL** — propagate Azure base URL to Pi subprocess
- **Deep-link routing** — corrected deep-link client targeting with regression tests
- **Split-turn expansion** — fixed TurnCard expansion key collisions
- **Explore mode false positive** — no longer flags node arrow syntax (`=>`) as a write operation
- **Onboarding loop** — fixed onboarding always showing + silent connection save failures
- **Copilot model listing** — use GitHub OAuth token for CopilotClient model listing
- **Label badge overlap** — prevent premature label badge overlap in UI
- **Transport hardening** — hardened WebSocket startup routing, codec, and session watcher isolation
- **OAuth fixes** — open OAuth browser locally via `shell.openExternal`, accept `/oauth/callback` path
- **Event payloads** — consistent `sources:changed` and `skills:changed` payload shapes
- **Global config guard** — ensure `config.json` exists before handler registration1 parent 9e0b8fb commit 24ab785
File tree
392 files changed
+34414
-8384
lines changed- .github/workflows
- apps
- cli
- src
- electron
- eslint-rules
- resources
- release-notes
- scripts/tests
- src
- __tests__
- main
- __tests__
- handlers
- __tests__
- preload
- renderer
- actions
- atoms
- __tests__
- components
- apisetup
- __tests__
- app-shell
- __tests__
- input
- __tests__
- chat
- onboarding
- ui
- __tests__
- config
- __tests__
- contexts
- __tests__
- context
- event-processor/handlers
- hooks
- __tests__
- keyboard
- pages
- settings
- playground
- registry
- runtime
- server
- transport
- __tests__
- viewer
- docs
- packages
- core
- src/types
- pi-agent-server
- src
- tools
- search
- providers
- server-core
- src
- bootstrap
- domain
- handlers
- rpc
- model-fetchers
- runtime
- services
- sessions
- transport
- server
- src
- session-mcp-server
- session-tools-core
- src
- handlers
- runtime
- ui
- eslint-rules
- src
- components
- chat
- __tests__
- markdown
- __tests__
- extensions
- overlay
- __tests__
- ui
- styles
- scripts
- build
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
392 files changed
+34414
-8384
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
62 | 62 | | |
63 | 63 | | |
64 | 64 | | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
147 | 147 | | |
148 | 148 | | |
149 | 149 | | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
| 186 | + | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
| 193 | + | |
| 194 | + | |
| 195 | + | |
| 196 | + | |
| 197 | + | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
| 207 | + | |
| 208 | + | |
| 209 | + | |
| 210 | + | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
| 246 | + | |
| 247 | + | |
| 248 | + | |
| 249 | + | |
| 250 | + | |
| 251 | + | |
| 252 | + | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
| 262 | + | |
| 263 | + | |
| 264 | + | |
| 265 | + | |
| 266 | + | |
| 267 | + | |
| 268 | + | |
| 269 | + | |
| 270 | + | |
| 271 | + | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
| 275 | + | |
| 276 | + | |
| 277 | + | |
| 278 | + | |
| 279 | + | |
| 280 | + | |
| 281 | + | |
| 282 | + | |
| 283 | + | |
| 284 | + | |
| 285 | + | |
| 286 | + | |
| 287 | + | |
| 288 | + | |
| 289 | + | |
| 290 | + | |
| 291 | + | |
| 292 | + | |
| 293 | + | |
| 294 | + | |
| 295 | + | |
| 296 | + | |
| 297 | + | |
| 298 | + | |
| 299 | + | |
| 300 | + | |
| 301 | + | |
| 302 | + | |
| 303 | + | |
| 304 | + | |
| 305 | + | |
| 306 | + | |
| 307 | + | |
| 308 | + | |
| 309 | + | |
| 310 | + | |
| 311 | + | |
| 312 | + | |
| 313 | + | |
| 314 | + | |
| 315 | + | |
| 316 | + | |
| 317 | + | |
| 318 | + | |
| 319 | + | |
| 320 | + | |
| 321 | + | |
| 322 | + | |
| 323 | + | |
| 324 | + | |
| 325 | + | |
| 326 | + | |
| 327 | + | |
| 328 | + | |
| 329 | + | |
| 330 | + | |
| 331 | + | |
| 332 | + | |
| 333 | + | |
| 334 | + | |
| 335 | + | |
| 336 | + | |
| 337 | + | |
| 338 | + | |
| 339 | + | |
| 340 | + | |
| 341 | + | |
| 342 | + | |
150 | 343 | | |
151 | 344 | | |
152 | 345 | | |
153 | 346 | | |
154 | 347 | | |
| 348 | + | |
155 | 349 | | |
156 | 350 | | |
157 | 351 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
0 commit comments