euron-code 0.2.0__tar.gz → 0.4.1__tar.gz

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.
Files changed (91) hide show
  1. euron_code-0.4.1/CHANGELOG.md +247 -0
  2. euron_code-0.4.1/PKG-INFO +572 -0
  3. euron_code-0.4.1/README.md +506 -0
  4. {euron_code-0.2.0 → euron_code-0.4.1}/pyproject.toml +8 -2
  5. {euron_code-0.2.0 → euron_code-0.4.1}/src/euron_code/__init__.py +1 -1
  6. euron_code-0.4.1/src/euron_code/activity.py +194 -0
  7. {euron_code-0.2.0 → euron_code-0.4.1}/src/euron_code/agent.py +560 -50
  8. {euron_code-0.2.0 → euron_code-0.4.1}/src/euron_code/api.py +79 -11
  9. euron_code-0.4.1/src/euron_code/attachments.py +245 -0
  10. euron_code-0.4.1/src/euron_code/auth.py +190 -0
  11. euron_code-0.4.1/src/euron_code/cache.py +128 -0
  12. {euron_code-0.2.0 → euron_code-0.4.1}/src/euron_code/checkpoints.py +73 -1
  13. {euron_code-0.2.0 → euron_code-0.4.1}/src/euron_code/cli.py +164 -12
  14. {euron_code-0.2.0 → euron_code-0.4.1}/src/euron_code/config.py +116 -10
  15. euron_code-0.4.1/src/euron_code/context.py +405 -0
  16. euron_code-0.4.1/src/euron_code/contextforge/LICENSE +21 -0
  17. euron_code-0.4.1/src/euron_code/contextforge/__init__.py +3 -0
  18. euron_code-0.4.1/src/euron_code/contextforge/text.py +337 -0
  19. euron_code-0.4.1/src/euron_code/contextforge/toolout.py +185 -0
  20. {euron_code-0.2.0 → euron_code-0.4.1}/src/euron_code/doctor.py +88 -88
  21. euron_code-0.4.1/src/euron_code/documents.py +368 -0
  22. {euron_code-0.2.0 → euron_code-0.4.1}/src/euron_code/hooks.py +2 -1
  23. {euron_code-0.2.0 → euron_code-0.4.1}/src/euron_code/memory.py +21 -5
  24. {euron_code-0.2.0 → euron_code-0.4.1}/src/euron_code/permissions.py +107 -4
  25. euron_code-0.4.1/src/euron_code/project_setup.py +267 -0
  26. {euron_code-0.2.0 → euron_code-0.4.1}/src/euron_code/prompts.py +42 -14
  27. euron_code-0.4.1/src/euron_code/repl.py +1642 -0
  28. {euron_code-0.2.0 → euron_code-0.4.1}/src/euron_code/rules.py +6 -2
  29. {euron_code-0.2.0 → euron_code-0.4.1}/src/euron_code/sessions.py +27 -6
  30. {euron_code-0.2.0 → euron_code-0.4.1}/src/euron_code/skills.py +11 -4
  31. euron_code-0.4.1/src/euron_code/textsafe.py +41 -0
  32. {euron_code-0.2.0 → euron_code-0.4.1}/src/euron_code/tools/__init__.py +9 -2
  33. euron_code-0.4.1/src/euron_code/tools/background.py +378 -0
  34. {euron_code-0.2.0 → euron_code-0.4.1}/src/euron_code/tools/base.py +1 -0
  35. euron_code-0.4.1/src/euron_code/tools/document.py +54 -0
  36. {euron_code-0.2.0 → euron_code-0.4.1}/src/euron_code/tools/fs.py +160 -11
  37. euron_code-0.4.1/src/euron_code/tools/reuse.py +103 -0
  38. {euron_code-0.2.0 → euron_code-0.4.1}/src/euron_code/tools/search.py +20 -5
  39. {euron_code-0.2.0 → euron_code-0.4.1}/src/euron_code/tools/shell.py +41 -12
  40. euron_code-0.4.1/src/euron_code/tools/symbols.py +105 -0
  41. euron_code-0.4.1/src/euron_code/trust.py +190 -0
  42. euron_code-0.4.1/src/euron_code/ui.py +373 -0
  43. {euron_code-0.2.0 → euron_code-0.4.1}/src/euron_code/usage_view.py +145 -44
  44. {euron_code-0.2.0 → euron_code-0.4.1}/tests/conftest.py +2 -0
  45. {euron_code-0.2.0 → euron_code-0.4.1}/tests/helpers.py +2 -0
  46. {euron_code-0.2.0 → euron_code-0.4.1}/tests/mock_gateway.py +227 -12
  47. euron_code-0.4.1/tests/serve_helper.py +19 -0
  48. {euron_code-0.2.0 → euron_code-0.4.1}/tests/test_agent_mock.py +229 -228
  49. {euron_code-0.2.0 → euron_code-0.4.1}/tests/test_api_shell.py +160 -160
  50. {euron_code-0.2.0 → euron_code-0.4.1}/tests/test_cli_e2e.py +19 -1
  51. {euron_code-0.2.0 → euron_code-0.4.1}/tests/test_context_memory_sessions.py +1 -0
  52. {euron_code-0.2.0 → euron_code-0.4.1}/tests/test_permissions.py +91 -91
  53. euron_code-0.4.1/tests/test_textsafe.py +45 -0
  54. {euron_code-0.2.0 → euron_code-0.4.1}/tests/test_tools_fs.py +143 -143
  55. {euron_code-0.2.0 → euron_code-0.4.1}/tests/test_v2_rules_skills_hooks.py +7 -0
  56. {euron_code-0.2.0 → euron_code-0.4.1}/tests/test_v2_tokens_shortcuts.py +2 -1
  57. euron_code-0.4.1/tests/test_v31_security.py +349 -0
  58. euron_code-0.4.1/tests/test_v3_accounts_value_setup.py +333 -0
  59. euron_code-0.4.1/tests/test_v3_activity.py +224 -0
  60. euron_code-0.4.1/tests/test_v3_attachments.py +305 -0
  61. euron_code-0.4.1/tests/test_v3_context.py +220 -0
  62. euron_code-0.4.1/tests/test_v3_live_repl.py +315 -0
  63. euron_code-0.4.1/tests/test_v3_single_login.py +150 -0
  64. euron_code-0.4.1/tests/test_v4.py +341 -0
  65. euron_code-0.2.0/PKG-INFO +0 -452
  66. euron_code-0.2.0/README.md +0 -391
  67. euron_code-0.2.0/src/euron_code/auth.py +0 -115
  68. euron_code-0.2.0/src/euron_code/context.py +0 -190
  69. euron_code-0.2.0/src/euron_code/repl.py +0 -821
  70. euron_code-0.2.0/src/euron_code/ui.py +0 -269
  71. {euron_code-0.2.0 → euron_code-0.4.1}/.gitignore +0 -0
  72. {euron_code-0.2.0 → euron_code-0.4.1}/LICENSE +0 -0
  73. {euron_code-0.2.0 → euron_code-0.4.1}/src/euron_code/__main__.py +0 -0
  74. {euron_code-0.2.0 → euron_code-0.4.1}/src/euron_code/builtin_skills/explain-codebase/SKILL.md +0 -0
  75. {euron_code-0.2.0 → euron_code-0.4.1}/src/euron_code/builtin_skills/review/SKILL.md +0 -0
  76. {euron_code-0.2.0 → euron_code-0.4.1}/src/euron_code/builtin_skills/test-writer/SKILL.md +0 -0
  77. {euron_code-0.2.0 → euron_code-0.4.1}/src/euron_code/credentials.py +0 -0
  78. {euron_code-0.2.0 → euron_code-0.4.1}/src/euron_code/frontmatter.py +0 -0
  79. {euron_code-0.2.0 → euron_code-0.4.1}/src/euron_code/keys.py +0 -0
  80. {euron_code-0.2.0 → euron_code-0.4.1}/src/euron_code/repomap.py +0 -0
  81. {euron_code-0.2.0 → euron_code-0.4.1}/src/euron_code/tools/db.py +0 -0
  82. {euron_code-0.2.0 → euron_code-0.4.1}/src/euron_code/tools/ignore.py +0 -0
  83. {euron_code-0.2.0 → euron_code-0.4.1}/src/euron_code/tools/skill.py +0 -0
  84. {euron_code-0.2.0 → euron_code-0.4.1}/src/euron_code/tools/task.py +0 -0
  85. {euron_code-0.2.0 → euron_code-0.4.1}/src/euron_code/tools/todo.py +0 -0
  86. {euron_code-0.2.0 → euron_code-0.4.1}/src/euron_code/tools/web.py +0 -0
  87. {euron_code-0.2.0 → euron_code-0.4.1}/tests/test_db.py +0 -0
  88. {euron_code-0.2.0 → euron_code-0.4.1}/tests/test_powershell_exit_codes.py +0 -0
  89. {euron_code-0.2.0 → euron_code-0.4.1}/tests/test_repl.py +0 -0
  90. {euron_code-0.2.0 → euron_code-0.4.1}/tests/test_search.py +0 -0
  91. {euron_code-0.2.0 → euron_code-0.4.1}/tests/test_v2_usage_headers.py +0 -0
@@ -0,0 +1,247 @@
1
+ # Changelog
2
+
3
+ ## 0.4.1 (2026-11-05)
4
+
5
+ ### Fixed
6
+ - Pasting text with emoji into a Windows terminal crashed the prompt ("surrogates not allowed") and
7
+ then failed every request. Text is now repaired before it is saved or sent.
8
+
9
+ ### Changed
10
+ - Clearer privacy wording; the limits section shows the daily allowance and where to track usage.
11
+
12
+ ## 0.4.0 (2026-11-05)
13
+
14
+ ### Run the app, not just the tests
15
+ - `start_background_process` (waits for a port or a ready line), `read_process_output`, `stop_process`:
16
+ at most 3, 64 KB output each, whole process trees stopped on exit, `/clear` and `/rewind`; `/ps`.
17
+ - `check_app`: local URLs only; status, timing, title, `contains`, `wait_seconds`; `browser: true` uses
18
+ Playwright when installed (new extra `euron-code[browser]`) for console errors, failed requests and a
19
+ screenshot.
20
+ - The system prompt now says to use these for servers instead of `bash`.
21
+
22
+ ### Reuse Euron's open-source code (V4 contract section 3)
23
+ - `euron_reuse_search` and `euron_reuse_read` over the gateway's index of Euron's public MIT repos; the
24
+ system prompt asks to search before writing a substantial common component and to keep the licence
25
+ notice; `/reuse <query>`.
26
+
27
+ ### Context optimisation with Euron Open ContextForge (MIT, vendored in `euron_code/contextforge/`)
28
+ - Before any model-written summary: older duplicate tool results are dropped, bulky logs, test runs and
29
+ JSON are condensed to their verbatim signal lines (errors, failures, stack frames, head and tail), and
30
+ stubs keep the facts they drop. Often that is enough and no model call is spent.
31
+ - Every summary now carries a verbatim fact ledger (ids, paths, versions, env names, URLs, ports, dates,
32
+ error classes) and the user's stated constraints, plus permission grants, git branch and state, and the
33
+ last command with its exit code.
34
+
35
+ ### More tools and gaps closed (audit increment 6)
36
+ - `find_symbol` (definitions and references), `delete_file` and `move_file` (both undone by `/rewind`).
37
+ - `AGENTS.md` and `CLAUDE.md` are read alongside `EURON.md` (trust-gated like it).
38
+ - Inline `<tool_call>` JSON is repaired (trailing commas, single quotes, Python literals); garbage
39
+ becomes an error result for the model, never a crash.
40
+ - `/rewind` works after `euron --resume`: checkpoints are kept in `~/.euron/checkpoints/<session>/`
41
+ (user-only, at most 50 MB per session).
42
+ - The context window and output cap come from `/v1/models` unless you set them.
43
+ - `/export` warns that the file contains tool output.
44
+
45
+ ### Euron-only client and privacy (V4 contract section 1, audit increment 3)
46
+ - A 403 `client_not_supported` shows the gateway's message ("works through the euron app only").
47
+ - README and the first image attach say where data goes: prompts on GPUs rented from Vast.ai (not
48
+ logged), images described by Google Gemini (not stored).
49
+
50
+ ### CI
51
+ - `.github/workflows/ci.yml`: pytest on ubuntu, windows and macos x Python 3.9 and 3.12 (ripgrep on one
52
+ job), then build the wheel and sdist and check the wheel contents.
53
+
54
+ ## 0.3.0 (2026-11-05)
55
+
56
+ ### Never stuck at the output limit
57
+ - An answer cut by the output limit (`finish_reason: length`) is continued automatically (up to 3 times)
58
+ and joined into one answer. A tool call cut mid-arguments (typically a huge `write_file`) is never run;
59
+ the model is asked to make the change in smaller steps. When reasoning alone used the budget, the
60
+ request is retried once with `reasoning_effort: low`. Each case shows one dim note, never an error.
61
+ - `reasoning_effort` is sent on every call: `medium` by default, `low` for simple follow-ups
62
+ ("thanks", "continue") and continuation retries. `/effort low|medium|high`, setting `reasoningEffort`,
63
+ shown in the status bar.
64
+ - `max_tokens` is sized per request: min(server max, context window - prompt estimate - 512), at least
65
+ 1024. A request that would not fit is compacted first. The prompt estimate starts from the last
66
+ server-reported `prompt_tokens` and adds only the new messages.
67
+
68
+ ### Context management for a 32k window
69
+ - An output budget is reserved (min(maxOutputTokens, window/4)); percentages are of the usable rest.
70
+ - From 50%, tool outputs are cleared biggest and oldest first until under 40% (the latest step is never
71
+ touched). Each stub names the call (for reads: path and line range) so the model can read it again.
72
+ The note reports real numbers: "freed 9,400 tokens, now 38%".
73
+ - The conversation is summarised at 70%, or whenever the next request would not fit. The summary keeps
74
+ the task, decisions, files changed, commands and results, the last error and open todos (files
75
+ changed and the last error are also added verbatim).
76
+ - `read_file` reads 200 lines by default and stops at a line boundary before ~6k tokens. Files over
77
+ 2,000 lines return an outline (definitions with line numbers) unless a range is given. The system
78
+ prompt says: search first, read ranges, edit with `edit_file`, never rewrite big files.
79
+
80
+ ### A live session like Claude Code
81
+ - **Activity line** while the agent works: an animated glyph, a rotating verb, elapsed time, tokens
82
+ sent and received (counted live from the stream), what is happening (`thinking`, `writing app.py`,
83
+ `running pytest 12s`, `waiting for a GPU slot (2 ahead)`, `retrying in 3s`) and `esc to interrupt`.
84
+ On a terminal it redraws 10 times a second; without one it prints a progress line every 15 s; in `-p`
85
+ mode it appears on stderr only when stderr is a terminal. The gateway's `: queued, N ahead` comments
86
+ are shown instead of being ignored.
87
+ - **Status bar**: model and effort, mode, session tokens and their value, context %, today's and this
88
+ week's remaining quota, session uptime. Refreshed continuously.
89
+ - **Type while it works.** The turn runs in a worker thread and the prompt stays live. `/usage`, `/cost`,
90
+ `/context`, `/status`, `/model`, `/effort`, `/help`, `/todos`, `/permissions` run at once (a model switch
91
+ applies from the next model call, a mode change from the next tool call); anything else is queued as
92
+ your next message. Permission questions are answered in the same prompt. Esc or Ctrl-C stops the
93
+ turn (a running command is killed) and puts queued messages back into the input line.
94
+ - **`/` menu** pops up as soon as you type `/`, with every command, custom command and skill. `/model`
95
+ opens a picker (arrow keys + Enter) with context size and status. `@word` searches the project's files.
96
+ - `/status`, `/whoami`, `/config`, `/bug`, `/release-notes`, `/users` (alias of `/usage`).
97
+
98
+ ### Accounts and modes
99
+ - Plain `euron` with no saved key logs you in in the browser and goes straight into the session.
100
+ - `euron login` / `/login` when logged in: shows who, offers to log in as a different account
101
+ (`--force` skips the question). The old key is replaced only after the new login is approved. Logout
102
+ stays local (there is no CLI revoke API); revoke keys at euron.one/code-agent.
103
+ - `--permission-mode bypassPermissions` and `--dangerously-skip-permissions` (alias of `--yolo`) with a
104
+ red warning; Shift+Tab reaches bypass only when started with it. `acceptEdits` is shown as "auto-apply
105
+ edits". `--add-dir DIR` adds folders the agent may work in.
106
+
107
+ ### One login at a time
108
+ - A key revoked because the account logged in on another device (401 `signed_in_elsewhere`) shows that
109
+ message, drops the local key and offers "Log in here? (this signs out the other device)"; after the
110
+ login the interrupted message is carried on. `-p` exits 4 with the message.
111
+ - When another session holds the account (409 `session_in_use`), Euron Code asks "Take over here?"; yes
112
+ retries once with `X-Euron-Takeover: 1`. `-p` exits 4 unless `--takeover` is given.
113
+ - After `euron login`: "Signed in as ... (any other device using this account was signed out)".
114
+
115
+ ### Plan quotas and value (V3 contract)
116
+ - `/usage` shows the plan tier, all four periods (day, week, month, year) with bars and refill times,
117
+ `quota.blocked` prominently, and value lines at the reference API price ("≈ $1.07 (₹94) at Claude
118
+ Sonnet 5.5 API list prices · included in your plan"), plus what the allowance is worth. `/cost` and the
119
+ status bar show this session's value. Always labelled as a reference, never a bill.
120
+ - New 429 codes `monthly_token_limit`, `yearly_token_limit` and `cooldown`, each with its refill time in
121
+ local time; exit code 5 in `-p` mode.
122
+
123
+ ### Automatic project setup and local cache
124
+ - First `euron` in a folder without `EURON.md` or `.euron/` (not your home folder or a drive root) offers
125
+ to set it up; `--yes` or `euron init` does it without asking. Locally, with no model call: `EURON.md`
126
+ (stack, commands, layout, entry points), `.euron/rules/` (testing, git, security and per-stack
127
+ rules), `.euron/settings.json` (allow rules for the detected test/lint commands and read-only git),
128
+ `.euron/hooks.example.json` (off; `/hooks enable` turns them on, pre-trusted because Euron Code wrote
129
+ them), `.euron/commands/` (`/fix-tests`, `/commit`, `/pr`), and `.euron/cache/` in `.gitignore`.
130
+ - `.euron/cache/` keeps the repo map and file index, keyed by git HEAD and folder mtimes. Safe to delete,
131
+ no secrets, only written when `.euron/` exists.
132
+
133
+ ### Attach anything
134
+ - `@file`, `/attach`, or drag files into the terminal (Windows `"C:\..."` and PowerShell `& '...'`
135
+ quoting, Unix escaped spaces and `file://` are recognised). Word, Excel, PowerPoint and PDF become
136
+ compact text locally (stdlib zip+XML; `pypdf` for PDF), as do CSV/TSV (sample + column summary),
137
+ JSON, YAML and notebooks, capped at about 6k tokens per file with a note; unknown binaries are only
138
+ described. The new `read_document` tool reads more pages, sheets or rows on demand.
139
+ - `@folder` attaches a digest within a budget: tree, file types and sizes, heads of key files.
140
+ - Images (png/jpg/gif/webp/bmp, up to 5 per message, 5 MB each) are sent as `image_url` parts, resized
141
+ to 1568 px with the optional `euron-code[images]` extra (Pillow), which also enables Ctrl+V and
142
+ `/paste-image`. A 400 `images_unavailable` drops the images with a clear note and retries.
143
+ - Session transcripts never store image bytes.
144
+
145
+ ### Security (independent audit, before release)
146
+ - **Project trust.** A repo's `.euron/settings.json` / `settings.local.json` can no longer loosen anything
147
+ silently: allow rules, `defaultMode` other than default/plan, `shell`, `db.*`, `webFetch: true` and
148
+ raised limits apply only after the user trusts the repo (one prompt listing exactly what it ships,
149
+ with view / trust / ignore; fingerprinted in `~/.euron/trusted-projects.json`, so a change asks again).
150
+ Restrict-only keys (deny rules, plan mode, lowered limits) always apply. `-p` ignores untrusted keys
151
+ with a warning; `euron trust` / `/trust` trust a repo. Rules the user saves with `s` or
152
+ `/permissions allow` now live in `~/.euron/projects/<hash>.json`, outside the repo.
153
+ - **Repo instructions are trust-gated too:** project and parent `EURON.md`, `.euron/rules`, `.euron/skills`
154
+ and `.euron/commands` load only for a trusted repo. The system prompt no longer says project memory
155
+ "overrides" anything: project-provided guidance follows `# Tools and safety`, which always wins.
156
+ - `grep` skips secret-looking files (`.env*`, keys, credentials) in both the ripgrep and the Python path
157
+ and says which were skipped; naming one explicitly asks, like `read_file`.
158
+ - Commands, `!` commands and hooks run without `EURON_API_KEY` / `EURON_CODE_API` in their environment.
159
+ - Bypass mode still asks for commands that touch existing paths outside the project and for a list of
160
+ destructive commands (that list asks even with an allow rule); `web_fetch` to localhost, private
161
+ ranges, link-local and metadata addresses asks in every mode unless that exact host was allowed.
162
+ - Edits to `EURON.md` and `.euron/**` always ask in acceptEdits mode.
163
+ - Session transcripts are created user-only (0600, folder 0700) on POSIX.
164
+
165
+ ### Runaway guard and honest completion
166
+ - 3 identical failing calls add a "change your approach" note; 5 stop the request (`stop_reason: loop`).
167
+ Identical successful calls get a note at 4 and stop at 8.
168
+ - Step budget per request, `maxStepsPerPrompt` (default 60): the REPL asks to continue; `-p` exits 6.
169
+ - A local report after a change: `Changed: ... | Ran: ... (exit N) | Not verified: ...`; `-p --output-format
170
+ json` gains `files_changed` and `commands`. One automatic nudge when files changed and no command
171
+ succeeded afterwards (`verifyNudge`, off in plan mode); the detected test command is in the
172
+ environment block.
173
+ - After `write_file` / `edit_file`: a syntax check for `.py` (compile), `.json` and, when node is installed,
174
+ `.js` files.
175
+
176
+ ### Fixed
177
+ - Windows Terminal, VS Code and other ConPTY hosts: a lone Esc stayed inside prompt_toolkit's VT input
178
+ parser until the next key, so Esc did not interrupt. The timed flush now delivers it (found by
179
+ driving the CLI in a real ConPTY).
180
+ - Safe commands such as `/usage` typed while a permission question is open now run, and the question
181
+ stays open, instead of being rejected as an invalid answer.
182
+
183
+ ### Changed
184
+ - Defaults: `compactThreshold` 0.7, `microCompactThreshold` 0.5, new `microCompactTarget` 0.4,
185
+ `microCompactKeepSteps` 1, `outputReserve`, `reasoningEffort` (all fractions of the usable window).
186
+ - The CHANGELOG ships inside the wheel (for `/release-notes`).
187
+
188
+ ## 0.2.0 (2026-11-05)
189
+
190
+ ### Added
191
+ - **Usage periods.** `/usage` and `euron usage` show Today / This week / This month with a progress bar
192
+ against each limit (the week only when the plan has a weekly limit), reset times in local time,
193
+ requests, sessions, tasks and the share of prompt tokens served from the server's cache, plus the
194
+ 30-day table with cached / sessions / tasks columns. The status bar shows the tighter of the day and
195
+ week allowance.
196
+ - **Weekly limit.** A `weekly_token_limit` 429 stops cleanly with the local reset time; exit code 5 in
197
+ `-p` mode, the same as the daily limit. Both limits read `resets_at` from the error when present.
198
+ - **Session and task headers.** Every model call sends `X-Euron-Session` (the saved session id, kept on
199
+ `--continue` / `--resume` / `/resume`) and `X-Euron-Task` (new for every message you send).
200
+ - **Rules files.** `.euron/rules/*.md` and `~/.euron/rules/*.md`, loaded after `EURON.md`. Rules with
201
+ `paths:` front matter load only once a matching file is read or edited. `/rules`, `/rules new`.
202
+ - **Skills.** `.euron/skills/<name>/SKILL.md` and `~/.euron/skills/<name>/SKILL.md`. Only names and
203
+ descriptions are in the system prompt; the new `skill` tool loads a body on demand; `/<name> [args]`
204
+ runs one. Built in: `review`, `test-writer`, `explain-codebase`. `/skills`, `/skills new`.
205
+ - **Custom commands.** `.euron/commands/<name>.md` and `~/.euron/commands/<name>.md` become `/<name>`
206
+ with `$ARGUMENTS`; shown in `/help` and Tab completion.
207
+ - **Hooks.** `SessionStart`, `UserPromptSubmit`, `PreToolUse`, `PostToolUse`, `Stop` in settings, with a
208
+ tool-name `matcher`, JSON on stdin and exit code 2 to block or give feedback. Project hooks must be
209
+ trusted once per project (re-asked when they change); skipped with a warning in `-p` mode.
210
+ `/hooks`, `/hooks new`.
211
+ - **Plan mode.** Read-only mode in which the model proposes a plan; leaving it is the user's choice.
212
+ Shift+Tab cycles default -> acceptEdits -> plan; also `/plan` and `--permission-mode plan`.
213
+ - **Shortcuts.** `!command` runs a command and adds its output to the next message; `@path` attaches a
214
+ file or folder (Tab completes paths); Esc Esc / `/rewind` undoes the last turn's file edits and drops
215
+ the turn; Ctrl-L clears the screen; `/resume` and `/export` inside a session.
216
+ - **`/context`.** A breakdown with a bar: system prompt, memory, rules, skills index, tool definitions,
217
+ messages, tool results, free space.
218
+ - **`/init` repo map.** A locally built map (stack, manifest commands, layout, entry points) is handed to
219
+ the model, which writes a short `EURON.md` with a repo map section; offers `.euron/rules/` and
220
+ `.euron/settings.json` skeletons.
221
+
222
+ ### Token saving (automatic)
223
+ - The system prompt and tool list stay byte-identical for the whole session; plan mode, hook output and
224
+ `!` output go at the end of the user message.
225
+ - Re-reading an unchanged file (mtime + size, or content hash) returns "unchanged since your last read
226
+ at turn N"; a read that reached the end of the file covers later partial reads.
227
+ - Micro-compaction at 60% of the context: tool outputs older than the last 3 steps become one-line stubs
228
+ (no model call); the summary still happens at 75%.
229
+ - `/cost` and `/context` report prompt tokens sent, tokens served from the server's prefix cache
230
+ (`usage.prompt_tokens_details.cached_tokens`) and tokens saved by each measure. `-p --output-format
231
+ json` adds `cached_tokens` and `saved_tokens`.
232
+
233
+ ### Changed
234
+ - `/help` lists your commands, skills and the shortcuts.
235
+ - `--permission-mode` and `/permissions mode` accept `plan`.
236
+ - New settings: `microCompactThreshold` (0.6), `microCompactKeepSteps` (3), `hooks`.
237
+
238
+ ### Fixed
239
+ - On Windows PowerShell 5.1, a command that wrote to stderr (for example `pytest ... 2>&1` with a
240
+ warning) was reported as exit code 1 with CLIXML noise even when it passed. The real exit code is
241
+ reported now and stderr is plain text.
242
+
243
+ ## 0.1.0
244
+
245
+ First release: agent loop with file, search, shell, database, web, todo and sub-agent tools; device
246
+ login; `EURON.md` memory and `/init`; `/compact` and auto-compaction; saved sessions; permission rules
247
+ and modes; `-p` headless mode.