@denizokcu/haze 0.9.0 → 0.10.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +57 -17
- package/README.md +119 -64
- package/dist/cli/chat/chatMetrics.d.ts +17 -1
- package/dist/cli/chat/chatMetrics.js +22 -5
- package/dist/cli/chat/contextReport.d.ts +11 -0
- package/dist/cli/chat/contextReport.js +44 -0
- package/dist/cli/chat/fileMentionSuggestions.d.ts +29 -0
- package/dist/cli/chat/fileMentionSuggestions.js +91 -0
- package/dist/cli/chat/inputSuggestions.d.ts +5 -0
- package/dist/cli/chat/inputSuggestions.js +17 -3
- package/dist/cli/chat/sessionLifecycle.d.ts +58 -0
- package/dist/cli/chat/sessionLifecycle.js +155 -0
- package/dist/cli/chat/sessionRecorder.js +7 -9
- package/dist/cli/chat/startupInfo.d.ts +1 -0
- package/dist/cli/chat/startupInfo.js +11 -0
- package/dist/cli/chat/tips.d.ts +21 -0
- package/dist/cli/chat/tips.js +43 -0
- package/dist/cli/chat/wizardDispatch.d.ts +64 -0
- package/dist/cli/chat/wizardDispatch.js +645 -0
- package/dist/cli/commands/chat.d.ts +1 -0
- package/dist/cli/commands/chat.js +181 -700
- package/dist/cli/commands/chatModes.d.ts +1 -1
- package/dist/cli/commands/chatModes.js +7 -2
- package/dist/cli/commands/commandHelp.js +5 -3
- package/dist/cli/commands/commands.d.ts +3 -2
- package/dist/cli/commands/commands.js +12 -13
- package/dist/cli/commands/fleetCommand.d.ts +14 -0
- package/dist/cli/commands/fleetCommand.js +46 -0
- package/dist/cli/commands/formatters.d.ts +5 -0
- package/dist/cli/commands/formatters.js +33 -6
- package/dist/cli/commands/logsCommand.js +1 -7
- package/dist/cli/commands/modelCommand.js +1 -1
- package/dist/cli/commands/providerWizard.d.ts +1 -0
- package/dist/cli/commands/providerWizard.js +13 -0
- package/dist/cli/commands/runCommand.d.ts +1 -0
- package/dist/cli/commands/runCommand.js +25 -5
- package/dist/cli/commands/sessionPicker.d.ts +9 -0
- package/dist/cli/commands/sessionPicker.js +29 -0
- package/dist/cli/commands/settingsSummary.js +6 -4
- package/dist/cli/commands/skillConfirmRemove.js +4 -3
- package/dist/cli/commands/skillWizard.d.ts +2 -0
- package/dist/cli/commands/skillWizard.js +16 -6
- package/dist/cli/commands/streaming/idleTimer.d.ts +26 -0
- package/dist/cli/commands/streaming/idleTimer.js +24 -0
- package/dist/cli/commands/streaming/toolGroupRenderer.d.ts +2 -0
- package/dist/cli/commands/streaming/toolGroupRenderer.js +4 -2
- package/dist/cli/commands/streaming/turnRuntime.js +6 -4
- package/dist/cli/commands/streaming.d.ts +13 -1
- package/dist/cli/commands/streaming.js +42 -19
- package/dist/cli/commands/wizardActions.d.ts +6 -0
- package/dist/cli/commands/wizardActions.js +6 -0
- package/dist/cli/commands/wizardSuggestions.d.ts +8 -0
- package/dist/cli/commands/wizardSuggestions.js +60 -12
- package/dist/cli/commands/wizardTransition.d.ts +4 -0
- package/dist/cli/commands/wizardTransition.js +1 -2
- package/dist/cli/index.js +17 -3
- package/dist/cli/terminalTitle.d.ts +6 -0
- package/dist/cli/terminalTitle.js +36 -0
- package/dist/config/inputHistory.d.ts +3 -3
- package/dist/config/inputHistory.js +12 -18
- package/dist/config/modelDiscovery.d.ts +20 -0
- package/dist/config/modelDiscovery.js +51 -0
- package/dist/config/providerPresets.d.ts +16 -4
- package/dist/config/providerPresets.js +263 -34
- package/dist/config/providers.d.ts +2 -0
- package/dist/config/providers.js +7 -0
- package/dist/config/settings.d.ts +22 -0
- package/dist/config/settings.js +29 -1
- package/dist/config/skillSettings.d.ts +6 -13
- package/dist/config/skillSettings.js +20 -19
- package/dist/core/agent/budgets.d.ts +26 -0
- package/dist/core/agent/budgets.js +34 -0
- package/dist/core/agent/compaction.js +17 -3
- package/dist/core/agent/contextBudget.d.ts +8 -0
- package/dist/core/agent/contextBudget.js +29 -0
- package/dist/core/agent/errors.js +6 -2
- package/dist/core/agent/events.d.ts +12 -0
- package/dist/core/agent/toolOutputStore.d.ts +5 -0
- package/dist/core/agent/toolOutputStore.js +18 -1
- package/dist/core/agent/workState.d.ts +1 -1
- package/dist/core/agent/workState.js +0 -4
- package/dist/core/attachments/imageAttachments.d.ts +90 -0
- package/dist/core/attachments/imageAttachments.js +245 -0
- package/dist/core/attachments/readBlessings.d.ts +37 -0
- package/dist/core/attachments/readBlessings.js +79 -0
- package/dist/core/goal/requestClassifier.d.ts +0 -3
- package/dist/core/goal/requestClassifier.js +0 -13
- package/dist/core/io/boundedRead.js +76 -29
- package/dist/core/limits/byteBudgets.d.ts +5 -0
- package/dist/core/limits/byteBudgets.js +5 -0
- package/dist/core/limits/textBudgets.d.ts +23 -0
- package/dist/core/limits/textBudgets.js +23 -0
- package/dist/core/process/backgroundRegistry.d.ts +35 -0
- package/dist/core/process/backgroundRegistry.js +194 -0
- package/dist/core/process/runBoundedProcess.d.ts +3 -0
- package/dist/core/process/runBoundedProcess.js +65 -29
- package/dist/core/safety/urlGuard.d.ts +2 -1
- package/dist/core/safety/urlGuard.js +3 -2
- package/dist/core/session/sessionSlimming.js +47 -4
- package/dist/core/session/sessionStore.d.ts +37 -0
- package/dist/core/session/sessionStore.js +95 -9
- package/dist/core/subagent/contracts.d.ts +116 -0
- package/dist/core/subagent/contracts.js +54 -0
- package/dist/core/subagent/executionProfiles.d.ts +28 -0
- package/dist/core/subagent/executionProfiles.js +45 -0
- package/dist/core/subagent/subagentCoordinator.d.ts +74 -0
- package/dist/core/subagent/subagentCoordinator.js +134 -0
- package/dist/core/subagent/subagentRunner.d.ts +211 -145
- package/dist/core/subagent/subagentRunner.js +228 -98
- package/dist/core/subagent/workspaceMutationPolicy.d.ts +11 -0
- package/dist/core/subagent/workspaceMutationPolicy.js +52 -0
- package/dist/core/tasks/taskStorage.js +12 -1
- package/dist/llm/client.d.ts +20 -29
- package/dist/llm/client.js +29 -28
- package/dist/llm/hazeTools.d.ts +2013 -78
- package/dist/llm/hazeTools.js +16 -7
- package/dist/llm/lsp.d.ts +2 -0
- package/dist/llm/lsp.js +18 -3
- package/dist/llm/requestContext.d.ts +22 -1
- package/dist/llm/requestContext.js +45 -5
- package/dist/llm/systemPrompt.d.ts +4 -1
- package/dist/llm/systemPrompt.js +14 -4
- package/dist/llm/toolResultTypes.d.ts +1 -1
- package/dist/llm/tools/bashTool.d.ts +874 -32
- package/dist/llm/tools/bashTool.js +25 -4
- package/dist/llm/tools/fetchTool.d.ts +26 -26
- package/dist/llm/tools/fetchTool.js +1 -1
- package/dist/llm/tools/fileToolShared.d.ts +2 -1
- package/dist/llm/tools/fileToolShared.js +5 -5
- package/dist/llm/tools/grepRunner.d.ts +5 -0
- package/dist/llm/tools/grepRunner.js +52 -71
- package/dist/llm/tools/outputCap.d.ts +2 -6
- package/dist/llm/tools/outputCap.js +2 -6
- package/dist/llm/tools/processTool.d.ts +1077 -0
- package/dist/llm/tools/processTool.js +41 -0
- package/dist/llm/tools/toolContext.d.ts +8 -0
- package/dist/llm/tools/toolContext.js +22 -11
- package/dist/llm/tools/workspaceFile.d.ts +9 -1
- package/dist/llm/tools/workspaceFile.js +33 -4
- package/dist/llm/webFetch.js +24 -11
- package/dist/llm/workerContext.d.ts +18 -0
- package/dist/llm/workerContext.js +55 -0
- package/dist/skills/SkillLoader.d.ts +2 -2
- package/dist/skills/SkillRegistry.d.ts +3 -2
- package/dist/skills/SkillRegistry.js +43 -13
- package/dist/skills/builder/SkillBuilder.d.ts +3 -0
- package/dist/skills/builder/SkillBuilder.js +23 -5
- package/dist/skills/skillTools.js +11 -4
- package/dist/skills/types.d.ts +6 -1
- package/dist/ui/components/TextInput.d.ts +5 -2
- package/dist/ui/components/TextInput.js +76 -8
- package/dist/utils/format.d.ts +2 -0
- package/dist/utils/format.js +8 -0
- package/dist/utils/fs.d.ts +0 -1
- package/dist/utils/fs.js +0 -4
- package/dist/utils/openPath.d.ts +2 -0
- package/dist/utils/openPath.js +9 -0
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,45 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## Unreleased
|
|
4
|
+
|
|
5
|
+
## 0.10.0 - 2026-08-03
|
|
6
|
+
|
|
7
|
+
### Added
|
|
8
|
+
|
|
9
|
+
- Added image input for png/jpeg/gif/webp files mentioned with `@path` or a slash-containing bare path. Providers must be explicitly marked image-capable; each message is limited to four images and 5 MB per image, and resumed sessions store placeholders instead of bytes.
|
|
10
|
+
- Added turn-scoped read blessings for user-typed file and directory paths, including host paths outside the workspace. `@` autocomplete browses gitignore-aware workspace paths. Mutating tools never honor the read exception.
|
|
11
|
+
- Added context-isolated subagents with explicit modes, profiles, models, deadlines, concurrency, tool budgets, cancellation quarantine, and shared mutation coordination. `/fleet` exposes parallel-only decomposition with temporary `--review`, `--profile`, `--workers`, and `--concurrency` options.
|
|
12
|
+
- Added managed background processes for up to five dev servers or watchers. Rolling output stays byte-bounded and retrievable by handle; the `process` tool lists, reads, and kills registrations, and haze tears down all process trees on session reset or exit.
|
|
13
|
+
- Added a workspace session browser to `/resume`, including resume-in-place and fork-from-snapshot actions. Session headers record fork provenance.
|
|
14
|
+
- Added live model discovery from OpenAI-compatible `/models` endpoints to `/model` and provider setup, with curated models pinned when served and manual entry retained as fallback. Expanded the provider preset catalog.
|
|
15
|
+
- Added project-local Markdown skills under `.haze/skills`. Project skills are labeled as untrusted repository content, override same-named global skills, remain real-path-confined, and can be managed independently by scope.
|
|
16
|
+
- Added rotating busy-state tips, toggled with `/tips`, cursor-aware `@` completion, and a TTY-only `haze - <cwd>` terminal title.
|
|
17
|
+
- Added the spec-kit workspace and project constitution.
|
|
18
|
+
|
|
19
|
+
### Changed
|
|
20
|
+
|
|
21
|
+
- Bash tool results carry byte statistics instead of duplicating retained stream text into model context; raw retrieval by handle is unchanged.
|
|
22
|
+
- `/compact` now builds a bounded recent-first excerpt and reports omitted entries rather than embedding unbounded collapsed text.
|
|
23
|
+
- `readToolOutput` eviction is true LRU: reading an entry refreshes its recency.
|
|
24
|
+
- Session IDs include a random suffix to avoid same-millisecond collisions. Session restore reads conversation and work state in one scan.
|
|
25
|
+
- Headless `--debug` progress uses stderr; the undocumented `HAZE_DEBUG` environment variable was removed.
|
|
26
|
+
- Branch display refreshes every 15 seconds and after each turn. Chat session and wizard orchestration were split into focused helpers without changing public flows.
|
|
27
|
+
|
|
28
|
+
### Security
|
|
29
|
+
|
|
30
|
+
- Project skills and their references remain real-path-confined to the workspace and are framed as untrusted repository content before entering model context.
|
|
31
|
+
- User-typed host paths grant read access only for the current turn. Mutating tools never honor the blessing set.
|
|
32
|
+
- Grep now shares bash's bounded process-group teardown, including `SIGTERM` to `SIGKILL` escalation and a close fallback for retained output pipes.
|
|
33
|
+
- Managed background processes keep byte-bounded rolling output and are terminated as process trees on session reset or haze exit.
|
|
34
|
+
|
|
35
|
+
### Fixed
|
|
36
|
+
|
|
37
|
+
- Subagent synthesis retains the task and gathered tool results, and long active worker waves no longer trip the idle timer. Flat required tool input avoids empty union-schema calls from local providers.
|
|
38
|
+
- Bash results no longer duplicate retained stream text into model context. Raw output remains available by handle.
|
|
39
|
+
- `/clear` prints once. Malformed `.haze/tasks.json` loads as an empty list. Retry classification matches status codes as whole words.
|
|
40
|
+
- `readFile` outline paging no longer skips entries after output truncation. Session files slim large mutation inputs to path and byte counts.
|
|
41
|
+
- Fetch derives its user agent from `package.json`, and session restore reads conversation and work state in one pass.
|
|
42
|
+
|
|
3
43
|
## 0.9.0 - 2026-07-10
|
|
4
44
|
|
|
5
45
|
### Security
|
|
@@ -16,11 +56,11 @@
|
|
|
16
56
|
|
|
17
57
|
### Changed
|
|
18
58
|
|
|
19
|
-
-
|
|
20
|
-
-
|
|
21
|
-
-
|
|
22
|
-
-
|
|
23
|
-
-
|
|
59
|
+
- Migrated the main `ToolLoopAgent` turn and subagent runner to AI SDK v7 while preserving compact terminal output, turn-scoped tool state, loop guardrails, and scoped context injection.
|
|
60
|
+
- Added the active model, a one-second elapsed timer, and current tool activity to the busy line. Activity labels cover reading, editing, searching, commands, skills, LSP, and MCP tools. Long waits during model and tool calls now show visible progress.
|
|
61
|
+
- Applied stricter bounds to large bash output before it enters the transcript or model context, especially for validation, search, and log-heavy commands.
|
|
62
|
+
- Updated tool context wiring, maintenance prompts, and agent guidance for AI SDK v7 and the current runtime.
|
|
63
|
+
- Standardized the lowercase `haze` name across the README, docs, prompts, skills, command help, tests, and agent guidance.
|
|
24
64
|
|
|
25
65
|
### Fixed
|
|
26
66
|
|
|
@@ -32,24 +72,24 @@
|
|
|
32
72
|
|
|
33
73
|
### Added
|
|
34
74
|
|
|
35
|
-
-
|
|
36
|
-
-
|
|
75
|
+
- Added `--output stream-json` to print mode. `haze -p "…" --output stream-json` writes public progress events to stdout as newline-delimited JSON, followed by the same `{type,status,result,usage}` envelope as `--output json`. Each event has an ISO-8601 `at` timestamp. Tool events omit raw inputs and outputs so CI and harness logs do not capture them. Before this option, print mode stayed silent until it returned the final envelope; harnesses could not show live progress or detect stagnant and looping runs from stdout. Every line is valid JSON and can be piped through `jq -c .`. The `text` and `json` formats are unchanged.
|
|
76
|
+
- The startup message now lists the context files sent with the system prompt. This makes it possible to check whether haze loaded global `CLAUDE.md` or `AGENTS.md` files and workspace instructions.
|
|
37
77
|
|
|
38
78
|
### Changed
|
|
39
79
|
|
|
40
|
-
-
|
|
41
|
-
-
|
|
42
|
-
-
|
|
80
|
+
- `haze -p "prompt"` runs one non-interactive turn and prints the result. It supports a per-run `--model provider:name` override without changing settings, plus structured `--output json` output. It reads piped prompts from stdin. Exit codes and JSON status come from the agent's terminal state (`complete`, `aborted`, or `failed`) rather than parsed reply text. Invalid or ambiguous model selectors print a specific error and exit nonzero. `--debug` writes a JSONL log under `~/.haze/logs/`, and the JSON `usage` object has a documented, fixed set of fields.
|
|
81
|
+
- Nested `CLAUDE.md` and `AGENTS.md` files discovered during a turn are added to the next model step and reread when their signature changes. haze serializes concurrent discovery so it reads unchanged files once without missing updated instructions.
|
|
82
|
+
- Session persistence no longer stores streaming `message_update` events. Large outputs and errors in saved `tool_end` events and `conversation_snapshot` tool results are reduced to previews and byte counts. Sessions remain resumable without unchecked JSONL growth from repeated text streams or large file reads.
|
|
43
83
|
|
|
44
84
|
### Security
|
|
45
85
|
|
|
46
|
-
-
|
|
86
|
+
- Closed a DNS-rebinding TOCTOU issue in `fetch`. `urlGuard.validateUrl` checked that a hostname resolved only to public addresses, but the global `fetch` resolved it again when connecting. An attacker-controlled DNS server could therefore return a public IP during validation and an internal or cloud-metadata IP during connection. `fetchUrlContent` now pins each connection and redirect hop to the validated IP with a small standard-library transport. It preserves the original `Host` header, TLS `servername`, and certificate verification without another DNS lookup. The redundant post-fetch validation was removed. Literal IP URLs still use the global `fetch` because they have no DNS-rebinding surface.
|
|
47
87
|
|
|
48
88
|
## 0.6.0 - 2026-06-21
|
|
49
89
|
|
|
50
90
|
### Added
|
|
51
91
|
|
|
52
|
-
-
|
|
92
|
+
- Added [Model Context Protocol](https://modelcontextprotocol.io) server support. `/mcp` opens an interactive picker for presets or custom `http`, `sse`, and `stdio` servers. Context7 is included as a preset for current library documentation. From the picker, users can enable, disable, or remove a server and set a masked API key. Configuration is stored under `mcpServers` in `~/.haze/settings.json`. MCP clients open for each agent turn and close afterward. A failing server is isolated, and MCP tools cannot shadow built-ins.
|
|
53
93
|
- Added optional configurable stdio LSP support through `/lsp`, with TypeScript, Rust, Python, Go, and PHP presets.
|
|
54
94
|
- Added read-only semantic navigation tools (`lspWorkspaceSymbols`, `lspSymbols`, `lspDefinition`, `lspReferences`) that are exposed to the model only when an enabled LSP command is installed on `PATH`.
|
|
55
95
|
- Added `/context`, a token breakdown of the current request (system prompt, project context, tools including MCP, and chat messages).
|
|
@@ -58,7 +98,7 @@
|
|
|
58
98
|
|
|
59
99
|
### Changed
|
|
60
100
|
|
|
61
|
-
- Switched the main agent turn to the AI SDK v6 `ToolLoopAgent` abstraction while preserving compact terminal tool
|
|
101
|
+
- Switched the main agent turn to the AI SDK v6 `ToolLoopAgent` abstraction while preserving compact terminal tool and text rendering and the existing loop guardrails.
|
|
62
102
|
- Improved transcript segmentation so assistant text and tool blocks alternate cleanly during multi-step turns.
|
|
63
103
|
- Added LSP-aware prompt guidance only when LSP tools are actually available; otherwise haze naturally falls back to `grep`, `listFiles`, and `readFile`.
|
|
64
104
|
- Made `/lsp` and `/mcp` interactive pickers matching the `/provider` flow (autocomplete lists, preset pickers, masked API-key entry), replacing the previous `/lsp`/`/mcp` subcommand syntax.
|
|
@@ -70,7 +110,7 @@
|
|
|
70
110
|
### Changed
|
|
71
111
|
|
|
72
112
|
- Removed all user-facing environment variables. `OPENAI_API_KEY`, `OPENAI_BASE_URL`, `HAZE_MODEL`, and `HAZE_CONTEXT_BUDGET_SHARE` are no longer read; configure providers, models, API keys, and base URLs through `~/.haze/settings.json` and the `/provider`, `/model`, `/settings` slash commands instead. This also removes the `OPENAI_*` env overrides from the startup provider info and the header.
|
|
73
|
-
- File LLM logging is now
|
|
113
|
+
- File-based LLM logging is now off by default. Previously, every session wrote a detailed JSONL log containing full prompts, model messages, tool inputs and outputs, and token usage to `~/.haze/logs/<timestamp>.jsonl`. Run `haze --debug` to enable logging and the on-screen debug panel. `/logs` still opens historical log files.
|
|
74
114
|
- Bash results now pass through command-aware reducers before they enter the transcript/model context. Validation failures render focused diagnostics, successful validation stays short, git/diff/search/JSON/log-like output is compacted, noisy command families get line filters, and reduced raw output remains retrievable by `readToolOutput` when stored.
|
|
75
115
|
- `grep` now returns compact structured search output for long match sets/lines, with reduction metadata, omitted-result counts, and a raw-output handle when the rendered result was truncated.
|
|
76
116
|
- Tool activity rendering is quieter: live tool groups show elapsed timers, subagent child calls, capped group detail, and compact success/failure summaries instead of dumping large result objects.
|
|
@@ -95,13 +135,13 @@
|
|
|
95
135
|
|
|
96
136
|
### Skills
|
|
97
137
|
|
|
98
|
-
- Replaced single-shot `/create-skill <description>` with a
|
|
138
|
+
- Replaced single-shot `/create-skill <description>` with a three-step interactive wizard: name → optional role → description. The wizard uses the supplied name and role verbatim; the model no longer renames them.
|
|
99
139
|
- Added language-agnostic intent extraction. Skill descriptions are interpreted by the model in any language, replacing the previous English-only regex strip. `"crée une compétence qui vérifie le style du code"` now produces a skill that vérifies code style, not a skill about creating something.
|
|
100
140
|
- Added `toSkillDirName` for kebab-casing user-typed skill names without stop-word stripping (so `"create a skill"` stays `create-a-skill`, not `skill`).
|
|
101
141
|
|
|
102
142
|
### Commands
|
|
103
143
|
|
|
104
|
-
- Removed the `/tasks` slash command.
|
|
144
|
+
- Removed the `/tasks` slash command. The model now manages tasks through `writeTasks`. `/clear` still removes them when it clears the conversation.
|
|
105
145
|
- Removed the `/list-skills` alias; `/skills` now shows the overview and the installed list.
|
|
106
146
|
- Removed the `/skill <subcommand>` and `/skills <subcommand>` legacy routing forms. Each skill operation now has exactly one user-facing form: `/skills`, `/create-skill`, `/skill-info`, `/validate-skill`, `/remove-skill`.
|
|
107
147
|
- Removed the `/tasks rm` alias for `/tasks remove`.
|
|
@@ -110,7 +150,7 @@
|
|
|
110
150
|
### Docs site
|
|
111
151
|
|
|
112
152
|
- Added §02 "Native skill creation" segment that frames the 3-step wizard as the haze superpower, with a live transcript of the wizard prompts, superpower bullets, and copy-pasteable recipe cards for `/code-review`, `/deploy-check`, `/release-prep`, `/security-review`.
|
|
113
|
-
- Added §07 "Commands index"
|
|
153
|
+
- Added §07 "Commands index," a categorized reference for all 16 slash commands and dynamic `/<skill-name>` invocations.
|
|
114
154
|
- Removed §04 "Serviceable procedures" (folded into §02).
|
|
115
155
|
- Renumbered sections sequentially (§01 Operation → §02 Native skill creation → §03 Field behavior → §04 Components → §05 Compatibility → §06 Install → §07 Commands index).
|
|
116
156
|
- Fixed §01 layout: switched from `.container-prose` (narrow, visually centered) to `.container` so it aligns with every other section.
|
package/README.md
CHANGED
|
@@ -2,29 +2,32 @@
|
|
|
2
2
|
|
|
3
3
|
A minimal LLM harness for your terminal.
|
|
4
4
|
|
|
5
|
-
## What's new in 0.
|
|
5
|
+
## What's new in 0.10.0
|
|
6
6
|
|
|
7
|
-
haze 0.
|
|
7
|
+
haze 0.10.0 adds richer input, isolated parallel work, and better control over long-running sessions.
|
|
8
8
|
|
|
9
|
-
-
|
|
10
|
-
-
|
|
11
|
-
-
|
|
12
|
-
-
|
|
13
|
-
-
|
|
9
|
+
- Attach png, jpeg, gif, or webp files by typing `@path` or a path containing `/`. Explicitly mentioned non-image files and directories can be read for that turn, including outside the workspace; mutating tools remain workspace-confined. `@` autocomplete browses workspace files.
|
|
10
|
+
- `/fleet` decomposes genuinely independent work across disposable, context-isolated subagents. Explicit profiles, model selection, concurrency and mutation coordination keep parallel execution bounded and predictable.
|
|
11
|
+
- `/resume` now opens a workspace session browser and can resume or fork a saved snapshot. Session IDs are collision-resistant, persisted entries stay compact, and ordered writes flush at turn and shutdown boundaries.
|
|
12
|
+
- The agent can register up to five dev servers or watchers as managed background processes. Their bounded rolling output is readable by handle, and haze terminates every registered process tree when the session ends.
|
|
13
|
+
- `/model` and provider setup can discover models from OpenAI-compatible `/models` endpoints. Curated models are pinned when available, and the provider wizard includes a larger preset catalog without silently selecting a default.
|
|
14
|
+
- Rotating busy-state tips are controlled by `/tips`; terminal tabs identify the active workspace.
|
|
15
|
+
- Follow-up hardening removes duplicated bash stream text from model context, gives grep the same process-tree teardown as bash, slims mutation inputs in saved sessions, fixes outline paging after truncation, and makes retry classification stricter.
|
|
14
16
|
|
|
15
17
|
Previous releases:
|
|
16
18
|
|
|
17
|
-
-
|
|
18
|
-
-
|
|
19
|
-
-
|
|
20
|
-
-
|
|
21
|
-
-
|
|
22
|
-
-
|
|
23
|
-
-
|
|
24
|
-
-
|
|
25
|
-
-
|
|
26
|
-
-
|
|
27
|
-
-
|
|
19
|
+
- `0.9.0`: private home-state storage, authoritative turn status, collection-time byte bounds, hardened process teardown, stronger real-path and network boundaries, and ordered persistence.
|
|
20
|
+
- `0.8.0`: AI SDK v7 runtime, live status with model, elapsed time, and tool labels; bounded bash output processing; lowercase `haze` naming.
|
|
21
|
+
- `0.7.0`: headless `-p`, `--output json`, and `--output stream-json`; pinned-connection `fetch` safety; scoped instruction refresh; smaller sessions; startup context visibility.
|
|
22
|
+
- `0.6.0`: AI SDK-native ToolLoopAgent core, optional LSP navigation, MCP support, unified configuration pickers, cleaner transcripts, `/context`, and startup update checks.
|
|
23
|
+
- `0.5.0`: SSRF-protected public URL fetching, no provider environment variables, debug-only LLM logs, command-aware output reduction, CLI Markdown rendering, scoped nested context files, and automatic cleanup of completed tasks.
|
|
24
|
+
- `0.4.0`: three-step skill wizard, language-agnostic skill intent extraction, model-managed tasks, a smaller command surface, and docs site additions.
|
|
25
|
+
- `0.3.0`: redesigned docs site, a relocated task bar, and automatic task cleanup between sessions.
|
|
26
|
+
- `0.2.0`: more reliable recovery from failed edits and validation, structured bash classification, parsed validation summaries, and multiline input with vertical cursor movement.
|
|
27
|
+
- `0.1.0`: bundled ripgrep, subagent delegation, and inline diffs.
|
|
28
|
+
- `0.0.3`: durable sessions, context compaction, and provider management.
|
|
29
|
+
- `0.0.2`: Markdown skills, autocomplete, and `listFiles` pagination.
|
|
30
|
+
- `0.0.1`: initial release.
|
|
28
31
|
|
|
29
32
|
haze works with OpenAI-compatible providers, including OpenRouter and local endpoints. Use `/provider` to choose or add one, then `/model` to select a model.
|
|
30
33
|
|
|
@@ -37,7 +40,7 @@ haze works with OpenAI-compatible providers, including OpenRouter and local endp
|
|
|
37
40
|
|_| |_|\__,_/___\___|
|
|
38
41
|
```
|
|
39
42
|
|
|
40
|
-
haze keeps guardrails light. The LLM can work from the terminal with
|
|
43
|
+
haze keeps guardrails light. The LLM can work from the terminal with access close to yours while staying scoped to the current project where possible. It is for developers who would rather supervise tool calls than work through a stack of permission dialogs. Keep an eye on what it does.
|
|
41
44
|
|
|
42
45
|
## Getting started
|
|
43
46
|
|
|
@@ -60,9 +63,9 @@ On first run, create or choose a provider, then choose your first model:
|
|
|
60
63
|
/model
|
|
61
64
|
```
|
|
62
65
|
|
|
63
|
-
`/provider`
|
|
66
|
+
`/provider` sets up any OpenAI-compatible endpoint, such as OpenRouter, OpenAI, LM Studio, Ollama, or a proxy. haze asks for a provider name, base URL, optional API key, and model names.
|
|
64
67
|
|
|
65
|
-
`/model` selects the model haze should use. You can also set one directly:
|
|
68
|
+
`/model` selects the model haze should use. The picker also offers `add models`, which fetches a provider's model list from its OpenAI-compatible `/models` endpoint so you can pick instead of typing; if the endpoint is unavailable you can still type model names. You can also set one directly:
|
|
66
69
|
|
|
67
70
|
```txt
|
|
68
71
|
/model anthropic/claude-sonnet-4.6
|
|
@@ -71,7 +74,7 @@ On first run, create or choose a provider, then choose your first model:
|
|
|
71
74
|
|
|
72
75
|
### MCP servers
|
|
73
76
|
|
|
74
|
-
Use `/mcp` to connect [Model Context Protocol](https://modelcontextprotocol.io) servers and give the agent
|
|
77
|
+
Use `/mcp` to connect [Model Context Protocol](https://modelcontextprotocol.io) servers and give the agent more tools. The interactive picker works like `/provider`: enable, disable, or remove a server; set its API key; or add one from a preset or custom configuration. The built-in Context7 preset provides current library documentation.
|
|
75
78
|
|
|
76
79
|
```txt
|
|
77
80
|
/mcp # opens the server picker
|
|
@@ -82,11 +85,11 @@ Use `/mcp` to connect [Model Context Protocol](https://modelcontextprotocol.io)
|
|
|
82
85
|
|
|
83
86
|
API keys for HTTP/SSE servers are entered in a masked prompt and sent as `Authorization: Bearer <value>`. Stdio authentication belongs in the command or wrapper; haze does not attach HTTP headers to stdio. Servers persist in `~/.haze/settings.json` under `mcpServers`. Discovery and cleanup have bounded deadlines, failures are isolated, and MCP tools never shadow built-ins.
|
|
84
87
|
|
|
85
|
-
Saved settings live in `~/.haze/settings.json`. Provider keys and MCP headers require HTTPS unless the endpoint
|
|
88
|
+
Saved settings live in `~/.haze/settings.json`. Provider keys and MCP headers require HTTPS unless the endpoint uses loopback HTTP (`localhost`, `*.localhost`, `127/8`, or `::1`). Keyless HTTP remains available, and local OpenAI-compatible providers do not need a key. If the settings file is malformed, haze shows an actionable startup error instead of treating it as empty. Configure everything inside haze with `/provider`, `/model`, and `/settings`; there are no environment variables to set.
|
|
86
89
|
|
|
87
|
-
haze
|
|
90
|
+
haze focuses on chat, local tools, context files, sessions, and Markdown skills. Use `/skills` for workflows outside that core. Its interactive picker can generate a skill from a description, then enable, disable, validate, or remove it. For reviews, release prep, deploy checks, debugging routines, or a team-specific checklist, ask haze to create a skill and edit the resulting Markdown as needed.
|
|
88
91
|
|
|
89
|
-
##
|
|
92
|
+
## Start using haze
|
|
90
93
|
|
|
91
94
|
Open a project and ask for work:
|
|
92
95
|
|
|
@@ -94,9 +97,11 @@ Open a project and ask for work:
|
|
|
94
97
|
create a calculator in calc-app in ruby with add subtract multiply divide
|
|
95
98
|
```
|
|
96
99
|
|
|
97
|
-
haze
|
|
100
|
+
haze can inspect and edit files, fetch public URLs, and run commands. Tool activity stays compact in the transcript. Small edits show a colorized diff with one line of context on either side; large diffs get a short summary instead. Bash output is capped while the command runs, then filtered according to the command type. Validation failures keep the useful diagnostics. Raw output handles have per-entry and total memory limits, and tell you how many bytes were dropped. Sessions are saved by default, so you can pick up the latest workspace conversation with `haze --continue` or `/resume`.
|
|
98
101
|
|
|
99
|
-
|
|
102
|
+
The agent can start up to five dev servers or watchers as registered background processes. Their rolling output is capped at 256 KB and remains available through `readToolOutput`; the `process` tool lists, reads, and kills them. The status bar shows the live count. Starting a new session or exiting haze terminates every registered process tree, while aborting an individual turn leaves background work running. Background processes are unavailable inside fleet workers and never survive haze itself.
|
|
103
|
+
|
|
104
|
+
Use `/` to discover commands and skills. Type `@` to browse workspace files; `Tab` completes the top suggestion.
|
|
100
105
|
|
|
101
106
|
Useful starters:
|
|
102
107
|
|
|
@@ -110,9 +115,19 @@ Useful starters:
|
|
|
110
115
|
|
|
111
116
|
`/init` creates or updates `AGENTS.md` so future sessions understand the project.
|
|
112
117
|
|
|
113
|
-
##
|
|
118
|
+
## Attach images
|
|
119
|
+
|
|
120
|
+
Reference an image in your prompt to attach it, and haze sends it to the model alongside your text:
|
|
121
|
+
|
|
122
|
+
```txt
|
|
123
|
+
@docs/screenshot.png the button in this shot is misaligned — fix it
|
|
124
|
+
```
|
|
125
|
+
|
|
126
|
+
Image input is opt-in per provider. Mark a provider image-capable in `/provider` before attaching, and haze shows which providers accept images in `/settings`. Attachments are limited to png, jpeg, gif, and webp files, up to 5 MB and 4 per message. Explicit user-typed paths may point outside the workspace; this exception is read-only and never expands mutation access. A non-capable provider, an invalid image path, or an oversized file fails with a clear message before any model call. Resumed sessions keep a short placeholder instead of the image bytes.
|
|
114
127
|
|
|
115
|
-
Skills
|
|
128
|
+
## Skills that grow with your workflow
|
|
129
|
+
|
|
130
|
+
Skills are Markdown workflows that haze creates with `/skills`. Choose **this project** to store a team workflow in `.haze/skills`, or **global** to store a personal workflow in `~/.haze/skills`. Project skills override same-named global skills in that workspace; `/skills` always shows each skill's provenance.
|
|
116
131
|
|
|
117
132
|
If you do something for the second time, build a skill for it:
|
|
118
133
|
|
|
@@ -123,10 +138,11 @@ If you do something for the second time, build a skill for it:
|
|
|
123
138
|
# Description: review the diff between my current branch and main, focusing on bugs, tests, DRY and KISS
|
|
124
139
|
```
|
|
125
140
|
|
|
126
|
-
haze uses the model to create the skill file for you:
|
|
141
|
+
haze uses the model to create the skill file for you at the explicitly selected scope:
|
|
127
142
|
|
|
128
143
|
```txt
|
|
129
|
-
|
|
144
|
+
.haze/skills/<skill-name>/SKILL.md # project
|
|
145
|
+
~/.haze/skills/<skill-name>/SKILL.md # global
|
|
130
146
|
```
|
|
131
147
|
|
|
132
148
|
A skill is just Markdown with frontmatter, a role, a focused prompt, and a small output template:
|
|
@@ -169,7 +185,7 @@ Installed skills appear as slash commands like:
|
|
|
169
185
|
|
|
170
186
|
They are also available through one `skill` catalog tool. haze loads one workflow body first and fetches large references only when needed. Skills provide instructions; they do not execute code.
|
|
171
187
|
|
|
172
|
-
|
|
188
|
+
When you catch yourself repeating the same instructions, put them in a skill. The workflow stays in a Markdown file that you can read and edit.
|
|
173
189
|
|
|
174
190
|
## Commands
|
|
175
191
|
|
|
@@ -187,13 +203,15 @@ This is the trick: do normal work, notice friction, create a skill, keep going.
|
|
|
187
203
|
/init
|
|
188
204
|
/context
|
|
189
205
|
/session
|
|
190
|
-
/resume
|
|
206
|
+
/resume [id]
|
|
191
207
|
/new
|
|
192
208
|
/compact [instructions]
|
|
193
209
|
/clear
|
|
194
210
|
/exit
|
|
195
211
|
|
|
196
212
|
/skills
|
|
213
|
+
/tips
|
|
214
|
+
/fleet [--review] [--profile <name>] [--workers <provider:model>] [--concurrency <n>] <prompt>
|
|
197
215
|
```
|
|
198
216
|
|
|
199
217
|
Skill management is a single interactive picker, mirroring `/provider`, `/lsp`, and `/mcp`: generate a custom skill from a description, then show info, enable/disable, validate, or remove. Disabled skills drop out of the model catalog and the `/<name>` command list until re-enabled.
|
|
@@ -201,9 +219,10 @@ Skill management is a single interactive picker, mirroring `/provider`, `/lsp`,
|
|
|
201
219
|
CLI flags:
|
|
202
220
|
|
|
203
221
|
```bash
|
|
204
|
-
haze --debug
|
|
205
|
-
haze --continue
|
|
206
|
-
haze --
|
|
222
|
+
haze --debug # show model/tool debug logs and write detailed JSONL logs to ~/.haze/logs
|
|
223
|
+
haze --continue # resume the latest saved session for this workspace
|
|
224
|
+
haze --resume <id> # resume an exact session id for this workspace
|
|
225
|
+
haze --no-session # run without durable session storage
|
|
207
226
|
```
|
|
208
227
|
|
|
209
228
|
Non-interactive / print mode:
|
|
@@ -211,12 +230,17 @@ Non-interactive / print mode:
|
|
|
211
230
|
```bash
|
|
212
231
|
haze -p "refactor utils.ts to remove the unused export"
|
|
213
232
|
haze -p "summarize this repo" --model openai:gpt-4o-mini
|
|
233
|
+
haze --resume <id> -p "continue the investigation"
|
|
214
234
|
haze -p "list the top 3 bugs in src/api.ts" --output json
|
|
215
235
|
haze -p "audit src/auth.ts" --output stream-json # live NDJSON events, then the result envelope
|
|
216
236
|
echo "what does this project do?" | haze
|
|
217
237
|
```
|
|
218
238
|
|
|
219
|
-
`-p`
|
|
239
|
+
`-p` and `--prompt` run one agentic turn with the full tool set and print the final assistant text. `--model` accepts a bare model name or `provider:name` and overrides the active model for that run without changing `~/.haze/settings.json`. The model must already be registered under a provider's `models`; add it once with `/provider`. Unknown or ambiguous selectors print a specific error to stderr and exit nonzero.
|
|
240
|
+
|
|
241
|
+
If you pipe stdin without `-p`, haze reads the prompt from stdin. One-shot runs do not create or update durable sessions, and they ignore `--continue`; `--resume <id>` can load an exact saved context for the turn without changing the original session. They also do not compact automatically after a context overflow, so keep large CI prompts within the model's context window. Add `--debug` to write a detailed JSONL log under `~/.haze/logs/`.
|
|
242
|
+
|
|
243
|
+
`--output` controls the result format: `text` is the default, `json` prints one final envelope, and `stream-json` writes live NDJSON events followed by the same envelope.
|
|
220
244
|
|
|
221
245
|
`--output json` prints a single-line envelope instead of plain text:
|
|
222
246
|
|
|
@@ -237,7 +261,7 @@ echo "what does this project do?" | haze
|
|
|
237
261
|
|
|
238
262
|
The `status` field is authoritative (driven by the agent's terminal state, not by parsing `result`), and the exit code mirrors it: `0` only for `complete`. A turn that ends without a substantive final answer, after an unresolved final tool failure, or at a hard step/tool budget is `failed` even if the provider returned normally.
|
|
239
263
|
|
|
240
|
-
`--output stream-json`
|
|
264
|
+
`--output stream-json` writes progress as the run happens. Each public event is one newline-delimited JSON object on stdout. The last line uses the same `{ type: "result", status, result, usage }` envelope as `--output json`, so consumers can display progress and parse the final result in the same way:
|
|
241
265
|
|
|
242
266
|
```jsonc
|
|
243
267
|
{"type":"turn_start","request":"audit src/auth.ts","at":"2026-06-27T22:00:00.000Z"}
|
|
@@ -250,32 +274,34 @@ The `status` field is authoritative (driven by the agent's terminal state, not b
|
|
|
250
274
|
{"type":"result","status":"complete","result":"Here are the findings…","usage":{"inputTokens":0,"outputTokens":0,"cacheReadTokens":0,"cacheWriteTokens":0,"reasoningTokens":0}}
|
|
251
275
|
```
|
|
252
276
|
|
|
253
|
-
|
|
277
|
+
Each line is valid JSON and can be piped through `jq -c .`. Event types include `turn_start`, `message_start` / `message_update` / `message_end`, `tool_start` / `tool_end`, `retry`, `context_overflow`, and `turn_end`. Every event has an ISO-8601 `at` timestamp. Tool events omit raw inputs and outputs because CI and harness logs often capture stdout; use `--debug` for detailed local JSONL logs.
|
|
254
278
|
|
|
255
|
-
|
|
279
|
+
This mode is intended for harnesses that run haze without a person at the terminal. A supervisor can watch stdout for progress, stalls, or loops. The final `result` envelope contains the authoritative status, text, and usage. The `text` and `json` formats are unchanged.
|
|
280
|
+
|
|
281
|
+
By default, haze does not write detailed LLM logs under `~/.haze/logs/`; those files contain full prompts, messages, and tool I/O. Run `haze --debug` to enable file logging and the on-screen debug panel. Use `/logs` to review saved logs.
|
|
256
282
|
|
|
257
283
|
## Agent tools
|
|
258
284
|
|
|
259
|
-
haze
|
|
285
|
+
haze has a small built-in toolset:
|
|
260
286
|
|
|
261
|
-
- `listFiles`
|
|
262
|
-
- `readFile`
|
|
263
|
-
- `grep`
|
|
264
|
-
- `editFile`
|
|
265
|
-
- `replaceLines`
|
|
266
|
-
- `writeFile`
|
|
267
|
-
- `bash`
|
|
268
|
-
- `readToolOutput`
|
|
269
|
-
- `fetch`
|
|
270
|
-
- `writeTasks`
|
|
271
|
-
- `skill`
|
|
272
|
-
- `lspWorkspaceSymbols`, `lspSymbols`, `lspDefinition`, `lspReferences`
|
|
287
|
+
- `listFiles` handles structured discovery and recursive listings, with cursor pagination when needed.
|
|
288
|
+
- `readFile` returns numbered UTF-8 lines in bounded pages, with `nextOffset` when more remain. It keeps a small, signature-checked index of line offsets so later pages do not start from the top of the file. File contents are not cached.
|
|
289
|
+
- `grep` runs structured ripgrep searches with a global result cap and compacts long lines and result sets. It rejects directly named ignored roots unless `includeIgnored` is set.
|
|
290
|
+
- `editFile` makes unique text replacements and tolerates accidental line-number prefixes.
|
|
291
|
+
- `replaceLines` edits line ranges when exact replacements are awkward and clamps ranges that extend slightly past EOF.
|
|
292
|
+
- `writeFile` creates files and parent directories.
|
|
293
|
+
- `bash` runs tests, builds, git and gh commands, scripts, installs, and other shell work. It trims output according to the command type while keeping useful failure details. A timeout or abort kills the process tree, escalates if necessary, and returns even when an escaped child keeps stdout or stderr open.
|
|
294
|
+
- `readToolOutput` pages through retained raw output omitted from oversized or reduced results, subject to in-memory budgets.
|
|
295
|
+
- `fetch` reads public `http(s)` URLs as Markdown, formatted JSON, or text. It rejects non-HTTP schemes, private and loopback addresses, metadata hosts, and malformed IPv6-like hosts. Bounded output remains available through `readToolOutput`.
|
|
296
|
+
- `writeTasks` replaces the task list at meaningful phase changes. Completed lists clear on the next user turn.
|
|
297
|
+
- `skill` loads an installed Markdown workflow or one of its references.
|
|
298
|
+
- `lspWorkspaceSymbols`, `lspSymbols`, `lspDefinition`, and `lspReferences` provide optional read-only navigation through configured language servers. They appear only when an enabled server command is installed.
|
|
273
299
|
|
|
274
|
-
Tool calls are grouped in the transcript so you can see what happened without reading a novella.
|
|
300
|
+
Tool calls are grouped in the transcript so you can see what happened without reading a novella. A small file edit shows colored additions and removals with one line of context. A large one gets a summary and a pointer to `git diff`. File-tool failures include a reason code and a recovery hint. Large bash, search, and fetch results stay behind an in-memory handle. Later model calls see a compact summary tailored to validation, git, search, diffs, JSON, logs, or the head and tail of the output.
|
|
275
301
|
|
|
276
302
|
### Optional LSP navigation
|
|
277
303
|
|
|
278
|
-
haze can use
|
|
304
|
+
haze can use stdio Language Server Protocol servers for semantic code navigation. Open `/lsp` to add a preset or custom command, then enable, disable, or remove it. The presets cover TypeScript, Rust, Python, Go, and PHP. You install the server yourself. haze only exposes LSP tools when an enabled server command is on `PATH`; otherwise it uses `grep`, `listFiles`, and `readFile`. When haze closes a server or rejects malformed protocol output, it terminates the server's process tree and forces it to exit if necessary.
|
|
279
305
|
|
|
280
306
|
Example TypeScript setup:
|
|
281
307
|
|
|
@@ -290,13 +316,41 @@ npm install -g typescript typescript-language-server
|
|
|
290
316
|
|
|
291
317
|
## Subagents
|
|
292
318
|
|
|
293
|
-
|
|
319
|
+
A subagent is a disposable worker with its own context. It is useful for a repository survey, log diagnosis, documentation search, or noisy validation run that would swamp the main conversation. The point is to isolate context, not merely to run things in parallel.
|
|
320
|
+
|
|
321
|
+
The worker receives a bounded description of its objective, deliverable, mode, and scope. It does not see the main conversation or sibling conversations, and it loads the relevant `AGENTS.md` or `CLAUDE.md` files itself. Only its compact result returns to the parent model. Tool logs, timings, usage, and estimated context savings stay out of that context.
|
|
322
|
+
|
|
323
|
+
The available modes are `inspect` (read-only), `research` (read-only with public fetch), `implement` (file changes and coordinated bash), and `validate` (reads and coordinated bash). Read-only modes cannot change files. Workers that can make changes are serialized with each other and with changes from the main turn. This coordination is not a shell sandbox.
|
|
324
|
+
|
|
325
|
+
Tool-call budgets apply to each execution, including calls submitted together. At the deadline, haze returns a terminal result and aborts the worker. If the underlying code ignores the abort, haze quarantines it and keeps its actual concurrency and mutation slot occupied until it settles. Retries stay within the same turn scope. Result handles exist only in the current process and are not durable, so each compact deliverable must stand on its own.
|
|
326
|
+
|
|
327
|
+
`/fleet` remains parallel-only model decomposition over the same worker primitive. Its control guidance is ephemeral and sessions retain only the original invocation, task/result capsules, and final answer. Supported one-run flags are:
|
|
328
|
+
|
|
329
|
+
```text
|
|
330
|
+
/fleet --review <prompt>
|
|
331
|
+
/fleet --profile local-safe <prompt>
|
|
332
|
+
/fleet --workers provider:model <prompt>
|
|
333
|
+
/fleet --concurrency 2 <prompt>
|
|
334
|
+
/fleet -- --prompt-that-starts-with-a-flag
|
|
335
|
+
```
|
|
336
|
+
|
|
337
|
+
Built-in profiles are `local-safe`, `local-throughput`, `cloud-balanced`, and `cloud-fast`. haze never infers a profile from a provider name or endpoint URL. If no profile is selected, it uses a provider-neutral compatibility baseline. If no worker model is set, it reuses the explicitly selected active model. An invalid worker model or profile blocks execution instead of falling back. Settings can select or customize profiles:
|
|
338
|
+
|
|
339
|
+
```json
|
|
340
|
+
{
|
|
341
|
+
"subagents": {
|
|
342
|
+
"workerModel": "local:qwen3-coder",
|
|
343
|
+
"defaultProfile": "local-safe",
|
|
344
|
+
"profiles": {"local-safe": {"maxConcurrency": 1, "deadlineMs": 300000}}
|
|
345
|
+
}
|
|
346
|
+
}
|
|
347
|
+
```
|
|
294
348
|
|
|
295
|
-
|
|
349
|
+
Keep trivial, conversation-coupled, sequential, user-interactive, or uncertain shared-mutation work in the main thread.
|
|
296
350
|
|
|
297
351
|
## Context files
|
|
298
352
|
|
|
299
|
-
haze saves durable workspace sessions in `~/.haze/sessions`. Settings, history, sessions, and debug logs use private POSIX directory/file permissions (`0700`/`0600`) and ordered, flushable writes. Use `/session` to see the current file, `/new` to start fresh, `/resume` to
|
|
353
|
+
haze saves durable workspace sessions in `~/.haze/sessions`. Settings, history, sessions, and debug logs use private POSIX directory/file permissions (`0700`/`0600`) and ordered, flushable writes. Use `/session` to see the current file, `/new` to start fresh, and `/resume` to browse workspace sessions, resume one, or fork its latest snapshot into a new session. `/resume <id>` and `haze --resume <id>` select an exact session. Use `/compact` to condense older model context into a bounded excerpt. Sessions also persist compact structured work state: the active goal, touched files, validation evidence, blockers, and next action.
|
|
300
354
|
|
|
301
355
|
Session files are optimized for resume and audit, not token-by-token playback: completed user/assistant messages, tool lifecycle events, conversation snapshots, and work-state snapshots are persisted, but streaming `message_update` events are skipped. Large persisted tool outputs are replaced with previews and byte counts so a resumed model can reread current files instead of carrying stale megabytes forward.
|
|
302
356
|
|
|
@@ -310,17 +364,18 @@ haze loads project instructions from:
|
|
|
310
364
|
|
|
311
365
|
At the same scope, `AGENTS.md` overrides `CLAUDE.md`; global haze guidance in `~/.haze/AGENTS.md` overrides global Claude guidance in `~/.claude/CLAUDE.md`. Nested `CLAUDE.md` / `AGENTS.md` files below the workspace are scoped: haze surfaces them only when file tools operate inside that directory or its subdirectories, injects newly discovered scoped guidance into the next model step, and mutating tools stop once so the model can review it before editing. Scoped context files are tracked by signature, so changed nested guidance can be read again later in the same session.
|
|
312
366
|
|
|
313
|
-
Use `AGENTS.md` for project conventions, commands, architecture notes, and
|
|
367
|
+
Use `AGENTS.md` for project conventions, commands, architecture notes, and anything you do not want to explain again. Because context files are added to every request, `/init` keeps its discovery pass small, preserves useful existing guidance, and asks for a compact file.
|
|
314
368
|
|
|
315
369
|
## Safety model
|
|
316
370
|
|
|
317
|
-
-
|
|
318
|
-
-
|
|
319
|
-
- Ignored files require an explicit override.
|
|
371
|
+
- Model-selected file tools are restricted to the current workspace and follow `.gitignore` by default.
|
|
372
|
+
- A path explicitly typed by the user with `@path` or as a slash-containing bare path may grant read-only access for that turn, including outside the workspace. It never grants mutation access.
|
|
373
|
+
- Ignored workspace files require an explicit override unless covered by that user-granted read exception.
|
|
320
374
|
- Bash commands are classified and shown with working-directory metadata, but haze does not use command confirmation gates.
|
|
321
|
-
- The `fetch` tool reads public `http(s)` URLs
|
|
375
|
+
- The `fetch` tool only reads public `http(s)` URLs. It rejects other schemes along with private, loopback, link-local, cloud-metadata, and malformed IPv6-like hosts. On every redirect, haze connects to the public IP it already validated, which closes the DNS-rebinding gap.
|
|
322
376
|
- Mutating and destructive commands can run when they are relevant to the user's request; this is intentional for expert users.
|
|
323
|
-
- haze
|
|
377
|
+
- Project skills under `.haze/skills` are repository-provided, untrusted instructions. haze announces them, labels their provenance, confines their real paths to the workspace, and frames their content so it cannot override higher-priority safeguards. Review project skills before using an unfamiliar repository.
|
|
378
|
+
- haze can make substantial changes, and it still needs supervision.
|
|
324
379
|
|
|
325
380
|
## Local development
|
|
326
381
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { ModelMessage } from 'ai';
|
|
2
|
-
import type { Message } from '../commands/streaming.js';
|
|
2
|
+
import type { Message, TokenUsage } from '../commands/streaming.js';
|
|
3
3
|
export declare function toolCallCount(messages: Message[]): number;
|
|
4
4
|
export declare function estimateTokens(text: string): number;
|
|
5
5
|
export declare function compactHomePath(filePath: string, home?: string): string;
|
|
@@ -9,3 +9,19 @@ export declare function estimateConversationTokens(messages: Message[]): {
|
|
|
9
9
|
input: number;
|
|
10
10
|
output: number;
|
|
11
11
|
};
|
|
12
|
+
/** Status-bar numbers for the transcript, extracted so render stays declarative (CR-006). */
|
|
13
|
+
export declare function statusBarMetrics(input: {
|
|
14
|
+
messages: Message[];
|
|
15
|
+
tokenUsage: TokenUsage;
|
|
16
|
+
enabledSkillCount: number;
|
|
17
|
+
backgroundProcessCount?: number;
|
|
18
|
+
}): {
|
|
19
|
+
hazeMessages: number;
|
|
20
|
+
toolsUsed: number;
|
|
21
|
+
effectiveInput: number;
|
|
22
|
+
effectiveOutput: number;
|
|
23
|
+
inputEstimated: boolean;
|
|
24
|
+
outputEstimated: boolean;
|
|
25
|
+
statusDetailLabel: string;
|
|
26
|
+
hasTokenBreakdown: boolean;
|
|
27
|
+
};
|