1635 Commits

Author SHA1 Message Date
Zhou
5a28a6165c
fix(shell): preserve UTF-8 native input on PowerShell 5 (#5160)
Windows PowerShell 5.1 defaults $OutputEncoding to US-ASCII, corrupting non-ASCII strings piped to native commands. Set it from the console encoding only on legacy versions so PowerShell 7 keeps its defaults.
2026-07-29 21:47:01 +08:00
chengyongru
757ad9c764
refactor: enforce BasedPyright strict type checking (#5158) 2026-07-29 21:37:11 +08:00
chengyongru
e703481755
fix(memory): expose media references to session consolidation (#5157)
Co-authored-by: shakewingo <yaoyingshakewin@gmail.com>
Co-authored-by: bingqilinweimaotai <111987281+bingqilinweimaotai@users.noreply.github.com>
2026-07-29 15:18:44 +08:00
chengyongru
393d429e0a
fix(ci): stabilize and speed up CI (#5145) 2026-07-28 22:55:59 +08:00
chengyongru
0c6c0438d4
feat(config): add actionable startup diagnostics and WebUI recovery (#5110) 2026-07-28 18:52:05 +08:00
chengyongru
ae089aa3ae fix(webui): reconcile threads after browser resume 2026-07-28 16:25:08 +08:00
chengyongru
78cf68c291 fix(agent): snapshot active tasks before cancellation 2026-07-28 15:42:52 +08:00
chengyongru
ae7b4c8792 fix(sdk): narrow persisted turn callback API 2026-07-28 15:30:28 +08:00
chengyongru
fd17c1352a fix(sdk): harden host integration contracts 2026-07-28 15:30:28 +08:00
chengyongru
c050955ae3 feat(sdk): add host integration extension points 2026-07-28 15:30:28 +08:00
chengyongru
12f828ea3d
fix(agent): read document attachments on demand (#5122) 2026-07-28 13:33:06 +08:00
chengyongru
ef9e687f19
refactor(core): remove redundant runtime scaffolding (#5127) 2026-07-28 11:07:58 +08:00
chengyongru
f78ad59ed0
fix(memory): preserve Dream input integrity (#5114) 2026-07-27 21:37:13 +08:00
yu-xin-c
7fd28c9f06 fix(memory): preserve unprocessed dream history 2026-07-27 15:47:21 +08:00
chengyongru
c13df29457
feat(memory): restore Dream model preset override (#5107) 2026-07-27 14:43:25 +08:00
chengyongru
281b4b7f0b
chore: remove expired v0.3.1 compatibility shims (#5106) 2026-07-27 13:53:04 +08:00
chengyongru
39348dfafe refactor(agent): remove dead lifecycle scaffolding 2026-07-27 12:00:06 +08:00
chengyongru
b3d3a3e6c3 fix(image): delegate DNS to explicit proxy 2026-07-27 10:06:19 +08:00
chengyongru
d73794bc68 fix(image): honor provider proxy for URL downloads 2026-07-27 10:06:19 +08:00
Xubin Ren
cc3dbbe804 fix(security): block IPv6 unspecified SSRF targets 2026-07-27 10:06:19 +08:00
Xubin Ren
4408cde019 fix(security): harden generated image downloads 2026-07-27 10:06:19 +08:00
Xubin Ren
cf1e801a29 fix(image): align Gemini hints with model capabilities 2026-07-27 03:07:41 +08:00
Xubin Ren
a8604a3172 fix(image): scope Gemini image sizes by model 2026-07-27 03:07:41 +08:00
stupidloud
ef445cc246 fix(image): narrow Gemini Flash aspect-ratio and image-size scoping
Address review feedback that the capability checks were broader than the
documented per-model matrix:

- Drop the extreme aspect ratios (1:4, 4:1, 1:8, 8:1) from the Flash
  allow-list. They are only documented for 3.1 Flash / Flash Lite, so the
  global set could send an unsupported ratio to 2.5 Flash Image or 3.1 Pro
  Image. Keep the ratios common to every Flash image model.
- Identify imageSize support positively via "gemini-3" instead of excluding
  "2.5". The old predicate also matched gemini-2.0-flash-preview-image-
  generation, which (with the default 1K size) altered that model's request
  shape even though only Gemini 3+ image models accept a configurable size.

Add tests for the gemini-2.0 image-size drop and the extreme-ratio drop.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-27 03:07:41 +08:00
stupidloud
4986590bd7 fix(image): pass aspect ratio and size to Gemini Flash image models
The Gemini Flash image path (`generateContent`) dropped both `aspect_ratio`
and `image_size`: `generate()` never forwarded them and
`_generate_gemini_flash` did not accept them, so every request fell back to
1:1 / input-matched output. The Imagen path was unaffected.

Forward the hints and emit them under
`generationConfig.responseFormat.image` per the current Gemini API. Aspect
ratio is validated against the accepted set; `imageSize` is validated against
{512,1K,2K,4K} and only sent to Gemini 3+ image models, since
`gemini-2.5-flash-image` supports only `aspectRatio`.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-27 03:07:41 +08:00
Xubin Ren
b695a7e875 fix(cli): harden quick start OAuth handling 2026-07-27 02:51:04 +08:00
Xubin Ren
a4ec83fb0d fix(cli): scope Codex proxy env resolution 2026-07-27 02:51:04 +08:00
chengyongru
2a1f840ce2 fix(cli): support Codex OAuth in quick start 2026-07-27 02:51:04 +08:00
Xubin Ren
68717937e8 fix(agent): throttle idle scans by default 2026-07-27 02:15:48 +08:00
Andrew Khmylov
7aab7e8830 feat(agent): make idle compaction scan interval configurable
Before this change, idle compaction is triggered every 1 second
if the incoming message stream is idle.
When triggered, it enumerates all session files, loads and parses them,
and then checks their expiration.

This becomes too CPU-intensive, especially on low-power devices like Raspberry Pi.
It's unlikely that you actually need to compact every second over the long time.

This change adds a configurable throttling for idle-compaction.

Default behavior is unchanged.
2026-07-27 02:15:48 +08:00
Xubin Ren
4e2640f2d2 fix(memory): keep failed Dream batches retryable 2026-07-27 02:00:41 +08:00
shixi-li
15e42059bd fix(memory): progress past completed no-op batches 2026-07-27 02:00:41 +08:00
Xubin Ren
b55b76d755 fix(streaming): preserve recovered segments across channels 2026-07-27 01:39:46 +08:00
chengyongru
e6baecafcd fix(agent): close length recovery lifecycle gaps 2026-07-27 01:39:46 +08:00
chengyongru
27a00c7a4f fix(webui): merge length recovery stream segments 2026-07-27 01:39:46 +08:00
chengyongru
1d2ed6e4d2 fix(agent): reset recovery chains across injections
Reset both the recovered segments and retry budget whenever injected input starts a new logical answer. Cover fatal tool-error boundaries and rename the prompt test module so pytest can collect the full suite.
2026-07-27 01:39:46 +08:00
chengyongru
154cbc1974 refactor(agent): trim recovery tail anchor 2026-07-27 01:39:46 +08:00
chengyongru
df2e5b7225 fix(agent): anchor truncated response continuations 2026-07-27 01:39:46 +08:00
chengyongru
b19039f9d0 fix(agent): preserve length-recovered output 2026-07-27 01:39:46 +08:00
Xubin Ren
c1899e2cb4 fix(mcp): decode URI-encoded schema refs 2026-07-27 01:14:41 +08:00
amplifierplus
9aae7485d6 fix(mcp): normalize local schema refs 2026-07-27 01:14:41 +08:00
Xubin Ren
d236883e2d fix(pairing): reject malformed store entries 2026-07-27 00:46:40 +08:00
santhreal
f7bf4c972e fix(pairing): treat null approved/pending maps as empty 2026-07-27 00:46:40 +08:00
Xubin Ren
cf6ca13b6d fix(exec): preserve bwrap workspace masking 2026-07-27 00:31:00 +08:00
yu-xin-c
22e61003f9 test(exec): make bwrap bind tests portable 2026-07-27 00:31:00 +08:00
yu-xin-c
01a11b3980 feat(exec): allow extra bwrap bind roots 2026-07-27 00:31:00 +08:00
Xubin Ren
5d8046deef test(heartbeat): cover ignored unified routes 2026-07-27 00:12:44 +08:00
yu-xin-c
a7a6c26eab fix(heartbeat): route unified sessions to last channel 2026-07-27 00:12:44 +08:00
Xubin Ren
ff379b91cf fix(agent): preserve merged runtime context markers 2026-07-26 23:46:54 +08:00
yu-xin-c
eb93060f95 fix(agent): preserve pending runtime context 2026-07-26 23:46:54 +08:00