50 Commits

Author SHA1 Message Date
Leoy
566465dc42 fix(mastery): ignore knowledge-base sources that no longer resolve (#2752)
* fix(mastery): ignore knowledge-base sources that no longer resolve

Refs #2748

* fix(mastery): filter the caller's mounted knowledge bases too

A study session left open across a deletion keeps sending the base it was
mounted with, and that list is merged verbatim with the topic's sources.
Run both through knowledge_base_ref_available so a stale name cannot reach
the tool bundles and raise AccessError.
2026-11-29 14:49:40 +08:00
Qiu
506cea9d4f feat(desktop): finish Windows chat file actions (#3051)
Continues #2978 and closes #2887. Includes the original Windows file actions, integrates the changes with dev, and adds an explicit default-app action.

Co-authored-by: Botong Wu <2048400180@qq.com>
2026-11-28 13:09:15 -03:00
Bingxi Zhao (Frank)
4c1e000d85 release: v1.7.3
Prepare v1.7.3 notes for reading and book editing, expanded provider and
agent connections, learning records, model streams, and desktop upgrades.

Sync README prose and 11 translations, archive older release notes, and
update the package version. Resolve release lint/type blockers with explicit
parser and capability contracts, compatible Book call forwarding, accurate
auth task types, and quoted SQLite schema identifiers. Cover positional Book
calls and quoted legacy columns; align KB seed tests with visible retrieval
failure reporting. Keep HTTP fixtures independent of host proxies and translate
new Portuguese UI copy.

Release notes: assets/releases/ver1-7-3.md
2026-11-16 02:17:36 +08:00
Bingxi Zhao (Frank)
ce4434e75a fix(workspaces): reuse knowledge references in selective conversation moves
Fixes #2289
2026-11-15 01:42:46 +08:00
Bingxi Zhao (Frank)
719e2a8e30 fix(chat): inherit ready workspace knowledge bases for untouched sessions 2026-11-15 01:00:49 +08:00
Bingxi Zhao (Frank)
92a26ae3cc fix(storage): isolate attachment writes and settle document parsing
Local dev repairs for #2244, #2245, #2255, #2426, #2453. Regression checks cover reported symptoms and compatibility boundaries.
2026-11-15 00:44:09 +08:00
Bingxi Zhao (Frank)
d76a4cbe7e Merge PR #2526: fix: resolve workspace KB scope past dead registrations; keep the progress stream off the activity lease
Regenerate the lazy router index against the integrated route sources.
2026-11-14 22:58:00 +08:00
VAN
b5443bf334 fix: force headless matplotlib backend in exec sandbox
The exec sandbox has no GUI session, so Figure.show() can block until the
tool timeout. schemdraw's Drawing defaults to show=True and calls show() on
context exit even after save(), which makes a successfully saved plot look
like a timed-out execution. Pin MPLBACKEND=Agg for model-authored programs.

Co-Authored-By: Claude Code <noreply@anthropic.com>
2026-11-11 21:24:47 +08:00
denghui996
d39b470d91 fix: resolve a KB's storage scope past unreadable workspace registrations
workspace_id_for_kb_base_dir() walks every registered workspace to find the
one that owns a KB directory, and it runs on every upload, folder sync and
reindex. A registration whose folder no longer exists (archived leftovers, a
directory the user moved) raises WorkspaceError on entry, which aborted the
whole lookup and dropped the storage scope from the background task.

Because WorkspaceError is a ValueError, the upload/sync routes then answered
404 'Knowledge base <name> not found' for a KB that exists, the background
task was never registered (the call sits in add_task's argument list), and
the KB kept the progress entry written just before it, so the UI showed an
endless 'scanning' state with no error on disk.

- skip registrations that cannot be entered instead of aborting the scan
- resolve the scope before copying files or marking the KB queued, so a
  failure cannot leave a task-less progress entry behind
- surface WorkspaceError as 409 with its real message instead of a 404

Fixes #2524
2026-11-09 02:07:05 +08:00
evan188199-tech
857bc6f6ad fix(workspace): conservatively clear dead migration markers (#2390) 2026-11-06 02:27:50 +08:00
Bingxi Zhao (Frank)
25eea13b29 Merge #2398 from Antonio-Faure 2026-11-06 01:56:25 +08:00
Bingxi Zhao (Frank)
c5c15c90eb Merge #2299 from Antonio-Faure 2026-11-06 01:56:22 +08:00
Antonio-Faure
c75b0c8c74 fix(workspace): keep the write probe inside the Windows path limit 2026-11-02 23:14:05 +01:00
Antonio-Faure
d6ecffd74e style: format workspace transfer test 2026-11-01 09:49:07 +01:00
Antonio-Faure
bc680bd762 fix(workspace): keep an explicit knowledge-base detach detached 2026-11-01 09:39:18 +01:00
Antonio-Faure
8a89f68f82 fix(workspace): renumber turn-event ids when moving a conversation 2026-11-01 09:39:15 +01:00
Bingxi Zhao
e1ab417bad Merge pull request #2128 from 0x-IHRR/feat/math-animation-file-actions
fix: show file actions for direct exec attachments
2026-10-31 16:50:09 +08:00
Bingxi Zhao
834bcf3f93 Merge pull request #2149 from KKandLL-Forever/fix/utf8-state-reads
fix: read state files with the writers' UTF-8 encoding
2026-10-31 16:46:05 +08:00
Eapp1e
9a02c9820f fix(workspace): skip archived workspaces in navigation indexes
Archived workspaces are hidden in the picker and rejected by the catalog
resolve path, but read_workspace_indexes() still polled them, logging a
traceback and reporting them as unavailable on every navigation request.

Signed-off-by: Eapp1e <163811520+Eapp1e@users.noreply.github.com>
2026-10-30 11:34:47 +00:00
wangkai
d52fb366c3 fix(workspace): read migration state files as UTF-8
The migration journal, PocketBase snapshot, presentation items and
dependency-closure documents are written as UTF-8 by atomic_write_json()
but were read through the locale default. On Chinese Windows (cp936)
non-ASCII names raise UnicodeDecodeError or come back as mojibake, so
workspace migration/preview can fail or copy wrong values.

Read them with file_io.read_text(), which uses the writers' encoding and
the same bounded PermissionError retry as the write side.
2026-10-29 13:33:13 +08:00
0x-IHRR
c097402538 fix: expose actions for exec turn attachments 2026-10-29 02:51:32 +08:00
Bingxi Zhao (Frank)
f50ab3afb0 Merge pull request #2050: inspect and clean generated files 2026-10-29 01:10:37 +08:00
Bingxi Zhao (Frank)
9269029699 Merge pull request #2086: server folder picker with all supported locales 2026-10-29 01:10:00 +08:00
0x-IHRR
507ec78780 fix: manage direct chat output attachments 2026-10-28 03:13:05 +08:00
0x-IHRR
25bbc02a3b fix: match generated chat output paths 2026-10-28 02:50:15 +08:00
0x-IHRR
7748e81a20 feat: manage generated chat output files 2026-10-28 02:44:07 +08:00
Bingxi Zhao (Frank)
fbab59acbf feat: modularize installation and enforce feature dependency boundaries 2026-10-28 01:02:29 +08:00
yh wang
98d2bddb92 feat(workspace): add a server-side folder picker for project workspaces 2026-10-27 12:32:45 +08:00
Bingxi Zhao (Frank)
6bbcc00c55 Merge dev into preview, preserving preview features
Integrate dev fixes with preview's Python/TypeScript schedulers, chat queue, learning navigation, and live turn persistence.
2026-10-27 01:16:58 +08:00
0x-IHRR
38cf3979d3 feat: add Math Animator output paths and render-file cleanup 2026-10-26 00:50:41 +08:00
Bingxi Zhao (Frank)
399297e7f0 feat: preserve TypeScript engine migration and workspace updates 2026-10-18 23:09:10 +08:00
dajiaohuang
149343c414 fix(storage): close SQLite connections after helper operations 2026-10-15 12:08:30 +08:00
Bingxi Zhao (Frank)
3cbecb2479 feat(workspaces): add scoped instructions and refine learning UI 2026-10-12 19:29:47 +08:00
Bingxi Zhao (Frank)
e49f518669 Reconcile user setup and provider changes with all reviewed PRs 2026-10-07 20:54:24 +08:00
Bingxi Zhao (Frank)
844c8f0a22 fix(workspace): retain corrupt migration journals as recovery blockers 2026-10-07 20:39:30 +08:00
Bingxi Zhao (Frank)
f8be756906 Integrate saved user workspace changes with reviewed dev updates 2026-10-07 20:37:55 +08:00
evan188199-tech
f94f9869a8 fix(workspace): surface unreadable migration journals and skipped corrupt sources (#1708)
* fix(migration): scope unreadable-journal rejection to migration paths

operations() skipped corrupted operation.json files, so
assert_no_pending_recovery() could not see their status and new
migrations could start while a recovery was still pending. The first
fix rejected unreadable journals in the shared precheck, which every
non-settings request runs - one corrupt file locked the whole app.

Unreadable journals now only fail migration-class callers
(migrate_data, export_data, move_kb, session adoption, and the router's
exclusive branches) via reject_unreadable=True, naming the full journal
path. Normal requests keep working. operations() lists unreadable
journals as status="unreadable" so Settings -> Data migration shows
them, and recover_operation quarantines an unreadable journal
(operation.json.corrupt) instead of crashing, which clears the blockage
while keeping snapshots for inspection.

* fix(workspace): surface skipped corrupt sources in migration dependency closure

Corrupt book manifests, feature documents, and message metadata were
silently skipped while computing the migration dependency closure, so
moved workspaces could silently miss sessions and references. Each skip
now logs a warning (path or session id only) and is returned to callers
via the optional warnings list, which migration preview exposes as a
warnings field. Skip/closure behavior itself is unchanged.

* fix(migration): point the unreadable-journal error at the Recover action

* test(codebuddy): make credential fixture expiry relative to now

test_load_credentials_parses_session wrote a hard-coded expiresAt of
1791055241000 (2026-10-03 15:40:41 UTC) and asserted is_expired() is
False. Once that instant passed the assertion flipped, so the test now
fails on every Python version for every branch.

Derive expiresAt / refreshExpiresAt from time.time() so the fixture
always describes a live session, and assert against the value written.

---------

Co-authored-by: XZH <cto@xzh.ai>
Co-authored-by: Bingxi Zhao (Frank) <13051345080@163.com>
2026-10-07 20:37:16 +08:00
ZQR1101
5b2b99fab9 fix(memory): aggregate account-level L1 across workspaces (#1799) (#1800)
Co-authored-by: ZQR1101 <278034003+ZQR1101@users.noreply.github.com>
2026-10-07 20:36:53 +08:00
Bingxi Zhao (Frank)
f07029cfcf release: v1.6.13
Ship the reading, listening, question-bank, parsing, and provider updates
summarized in assets/releases/ver1-6-13.md.

Make speech timeouts configurable, report actionable synthesis failures,
and keep chat attachments discoverable in their selected workspace while
preserving earlier uploads and URLs. Keep reply playback cancellation and
single-audio ownership intact.

Sync README prose and all eleven translations, update the stable install
note, and archive release notes older than one week. Repair stale reading
test fixtures and spawned test imports, and clear the Partner type error.

Validation: 9252 Python tests and 8 subtests passed (28 skipped); 518 web
unit tests, 1253 Node tests, and 62 browser audits passed. Pre-commit, ruff,
typecheck, contracts, architecture, i18n, production build, route budgets,
and the docs build passed.
2026-10-04 21:35:00 +08:00
Bingxi Zhao (Frank)
ef2d9e5c3c release: v1.6.12
Document workspace knowledge-base moves, connected Kiwix archives, source
figures, and the Task Board in the release notes and README. Sync all eleven
README translations and the version badge. Fix lint-only type annotations and
a duplicate French locale key found by the release gate.

See assets/releases/ver1-6-12.md for the full release notes.
2026-09-27 13:34:05 +08:00
Bingxi Zhao (Frank)
176257b1f8 style: format knowledge source integrations 2026-09-27 11:15:15 +08:00
Bingxi Zhao (Frank)
a824e4b01f fix(knowledge): preserve moved KB retrieval and scoped jobs 2026-09-27 11:04:33 +08:00
Bingxi Zhao (Frank)
b0385a315d feat(knowledge): choose storage and move individual bases 2026-09-27 11:04:33 +08:00
Bingxi Zhao
b333e0262b Merge pull request #1601 from wumajiehechuan-lab/fix/exec-python-utf8
fix: request UTF-8 mode for model-authored exec code
2026-09-27 03:21:07 +08:00
wumajiehechuan-lab
a4c85477b5 fix: request UTF-8 mode for model-authored exec code
`prepare_workspace_execution_env()` sets LANG / PYTHONUNBUFFERED /
PYTHONDONTWRITEBYTECODE but never PYTHONUTF8, and the restricted subprocess
backend deliberately inherits only a fixed subset of host variables. On a
Windows host whose ANSI code page is not UTF-8 (cp936, cp1252, …) the model's
Python therefore ran with `locale.getpreferredencoding() == 'cp936'`.

Two symptoms follow, and they hit any skill or tool script that touches
non-ASCII text:

* a bare `Path.read_text()` / `open()` on a UTF-8 file raises
  `UnicodeDecodeError: 'gbk' codec can't decode byte 0x8d in position 146`
  (or silently mojibakes the content);
* `print()` of a non-ASCII value reaches the caller as GBK bytes, which the
  turn reads back as garbage.

Reproduced end to end with a workspace skill whose build script reads a UTF-8
HTML template: under the exec environment it failed on every invocation, while
the same script succeeded in an ordinary shell on the same host — the classic
environment-dependent failure that is hardest for a user to diagnose. Measured
in the exec environment (same interpreter): `PYTHONUTF8` unset →
`stdout=gbk files=cp936`; set → `stdout=utf-8 files=utf-8`.

One variable fixes both halves, because UTF-8 mode covers file I/O and stdio
together. It is a no-op where UTF-8 is already the locale default, so Linux and
macOS containers behave exactly as before.
2026-09-26 01:44:26 -07:00
krxi
2eb2f2de96 feat: add a workspace-scoped task board 2026-09-24 16:10:03 +03:00
Bingxi Zhao (Frank)
1fe74df0ed fix(notebook): decouple evidence from chat sessions (#1519) 2026-09-21 14:50:02 +08:00
Bingxi Zhao (Frank)
da856ad670 release: v1.6.9
Ship folder-based workspaces and data migration, daily practice, redesigned
provider and model settings, and streaming conversation improvements.
Synchronize README translations and document the archive/permanent-delete
upgrade behavior in assets/releases/ver1-6-9.md.

Reduce initial JavaScript by deduplicating English resources and loading
animation features after hydration. Keep the existing route size budgets.
Update regression fixtures and browser audits for scoped URLs and the new
settings and learning interfaces.
2026-09-21 02:30:40 +08:00
Bingxi Zhao (Frank)
7a96bba1ae release: v1.6.6
Ship the v1.6.5 feedback sweep: answers that could not submit now
arrive, a copy button reports what actually happened, partners can use
connected knowledge bases, Codex sign-in finishes inside Docker, and the
home route is 100KB lighter.

Release notes: assets/releases/ver1-6-6.md
2026-09-08 15:46:59 +08:00
Bingxi Zhao (Frank)
04040a2c06 release: v1.6.5
Ship a content workspace you choose, one exec tool for every language,
Mastery Path modes that gate its tools, and Settings that grades
readiness instead of listing faults.

Release notes: assets/releases/ver1-6-5.md
2026-09-06 13:46:29 +08:00