Commit Graph

508 Commits

Author SHA1 Message Date
XZH
1fafdf48ac feat(learner): add guardian authorization 2026-08-30 23:56:02 -07:00
XZH
da296fd906 test(video-learning): support lazy included routers 2026-08-30 19:33:48 -07:00
XZH
7f98cac388 chore(ci): format Python baseline for ruff 2026-08-30 18:30:22 -07:00
Bingxi Zhao (Frank)
3dc372f551 release: v1.6.2 — immersive watching and extensible visualizers
Add synchronized YouTube learning, a plugin-driven visualizer catalog, and Hermes, OpenClaw, and DeepSeek agent harnesses. Refresh Reading, Knowledge, Partner status, guided updates, documentation, translations, and release notes for v1.6.2.
2026-08-31 01:13:07 +08:00
Bingxi Zhao (Frank)
7d23ed8a28 merge: integrate video learning and WebVTT fixes
# Conflicts:
#	deeptutor/capabilities/registry.py
#	deeptutor/runtime/bootstrap/builtin_capabilities.py
#	deeptutor/services/session/turn_runtime.py
#	tests/core/test_capabilities_runtime.py
#	web/app/(workspace)/home/[[...sessionId]]/page.tsx
#	web/components/common/AssistantResponse.tsx
#	web/context/UnifiedChatContext.tsx
#	web/lib/settings-nav.ts
#	web/locales/en/app.json
#	web/locales/zh/app.json
2026-08-30 18:07:23 +08:00
Bingxi Zhao (Frank)
5228af9141 merge: integrate recent issue fixes
# Conflicts:
#	web/context/UnifiedChatContext.tsx
#	web/tests/reading-turn-state.test.ts
2026-08-30 17:49:11 +08:00
Bingxi Zhao (Frank)
f694f204a8 feat: add app updater and unify workspace chat flows 2026-08-30 17:40:47 +08:00
Bingxi Zhao (Frank)
64dff25792 style: format recent issue fixes 2026-08-30 16:42:43 +08:00
Bingxi Zhao (Frank)
364b9cf59c fix(video-learning): preserve multiline WebVTT cues (#1091) 2026-08-30 16:41:36 +08:00
Bingxi Zhao (Frank)
da9492fbaf feat(parsing): integrate MinerU multi-format inputs (#1087) 2026-08-30 16:36:43 +08:00
Bingxi Zhao (Frank)
3f3bf0b841 feat(reading): render safe versioned web snapshots 2026-08-30 16:01:40 +08:00
XZH
7615e36bb8 fix(code-execution): preserve deliverable scope and retry discipline 2026-08-30 15:42:32 +08:00
Bingxi Zhao (Frank)
ce7c2dc2dc release: v1.6.1 — one key, one navigator, one sidebar you arrange
Model configuration was one layer replicated seven times: every service
stored its own profile with its own credentials, so a single OpenRouter
key had to be pasted into five separate pages. This release splits that
in two — a **connection** holds one vendor credential and links it down
to every service that vendor can serve, and a **task model** takes the
calls nobody asks for (naming a conversation, writing the composer's
starting points) off the model picked for actual reasoning. Both are
opt-in; existing per-service profiles resolve exactly as before.

Around that: Settings drops the card grid for a persistent searchable
navigator whose landing page answers "what state am I in" instead of
repeating the directory; Mastery Path files study conversations under
their topic and opens them in the tutor rather than dropping them on
/home; the sidebar folds features into More and reorders by drag; the
reading companion is rebuilt from /home's own chat components; and the
LightRAG engine talks to the SDK directly, so its extra no longer drags
MinerU in transitively.

Also back-merges PR #1041 (Anthropic SDK 1.x temperature via extra_body)
and PR #741 (owner-only auth secret/token files), which had been merged
straight into main and never flowed back to dev.

Release notes: assets/releases/ver1-6-1.md
Gates: pre-commit 15/15, ruff clean, pytest 5802 passed, web 450 node
tests, eslint 0 errors, docs build clean.
2026-08-30 13:19:42 +08:00
Bingxi Zhao (Frank)
0b0a5f93dc Merge origin/main into dev
Back-merge PR #1041 (Anthropic SDK 1.x temperature via extra_body) and
PR #741 (owner-only permissions for auth secret/token files), which were
merged directly into main and never flowed back to dev. Required so the
release cut can fast-forward main from dev.
2026-08-30 12:49:49 +08:00
Bingxi Zhao (Frank)
8070773747 fix(course): the recommendation is the answer, not a tool preamble
Course Study turns were ending on "I could not produce a useful response
from the model output", with the real recommendation sitting collapsed in
the trace above it — and, in one observed turn, written out three times.

The loop treats prose emitted alongside a tool call as a preamble: it is
streamed into the trace, and the answer is whatever a later tool-less
round says. That is right for tools that fetch something. It is wrong for
this playbook, which asks for the opposite shape — recommend the next
action, say why it is timely, then call `course_handoff`. The
recommendation and the call are one thought, and models write them in one
round. Dropped from the answer, the model had nothing new to add on the
next round, so it called `course_handoff` again until the budget ran out
and the turn finished empty.

The partner-group capability documents the same failure for
`invoke_other` and already carries the remedy: classify the tool round's
prose, then end the turn on it. Course Study now implements both hooks.

Two details worth keeping:

`_capability_answer_published` is deliberately not set. It means "the
learner has already seen this text, do not emit it again", which holds
for capabilities that buffer output behind a protocol. This mode buffers
nothing, so claiming it left the message body empty with the whole
recommendation hidden a click away — the original symptom, differently
caused.

A bare `course_handoff` with nothing said is left alone rather than
ending the turn: there is no answer to rescue, and the model still gets
its ordinary finish round to write one.

The flag was named `_partner_group_formal_answer_published` while living
in the generic loop, which now has a second caller; renamed to match what
it is.
2026-08-30 00:45:10 +08:00
Bingxi Zhao (Frank)
43c9fe7ea0 feat(course): make a course the container, not a dashboard
A course held the right model — the syllabus that gives progress a
denominator, resources as references, conventions apart from the
assistant's own notes — but almost nothing crossed the edges between it
and the surfaces it was supposed to contain.

Getting in. Course Study was offered in the composer's mode menu while
the only way to bind a course was a link on the course page, so choosing
it there produced a conversation identical to an inert one, and the mode
advised pressing a button that did not exist. The composer now carries
the binding next to the mode: shown whenever there is one, and offered
as an unfinished field in Course Study when there is not. `_course_id`
rides every turn, so detaching detaches and the pill can never drift
from what the turn actually saw.

What a conversation inherits. `default_capability` and `default_persona`
were stored, validated and returned by the API while changing nothing:
`_apply_course_defaults` only fills fields a payload *omits*, and this
composer always sent all of them. They are applied client-side now,
along with the course's knowledge bases, where the learner can watch the
mode and material become the course's before they type. The dialog grows
the editor they never had.

Conventions. "Every conversation in this course starts knowing these" was
true only if the model happened to call `course_overview`. They ride in
the per-turn summary now, and — because the promise is not scoped to one
mode — in the system prompt of any course-bound turn.

Coming back. Mastery Path and Immersive Reading now read `?course=`,
scope themselves to it, and attach whatever is built there; the tiles and
hand-offs pass it; the picker offers to start one. A course could only
ever reference what already existed, so filling a new one meant leaving,
building, and remembering to return.

Hand-offs. A target with no ref stored an opening line for an index that
never consumes it, which then surfaced weeks later in an unrelated path.
An unresolvable ref was passed straight through: observed live, a
syllabus unit id ("u2") sent as a mastery path, producing a card pointing
at a page that does not exist. Refs are checked against the subsystem
that owns them — existence, not membership, since a path built outside
this course routes perfectly well.

Also: the sidebar groups conversations by course, so filing them is
finally readable; a course-scoped notebook console no longer shows
another course's notes beside a list saying there are none (the clear
raced an in-flight detail fetch that landed after it); a hand-off the
model also printed as prose is not rendered twice; a provider error is no
longer stored as a conversation's permanent title; `/space/courses` goes,
having been an unreferenced copy of `/courses`; and the Visualize mode
description gets its missing Chinese.
2026-08-30 00:09:36 +08:00
Bingxi Zhao (Frank)
fc0be68d6f wip: course / partner groups in progress 2026-08-29 22:29:53 +08:00
Bingxi Zhao (Frank)
f349d8fbd4 Merge branch 'dev' into claude/deeptutor-model-config-efe083 2026-08-29 21:52:46 +08:00
Bingxi Zhao (Frank)
5218e1da49 feat(settings): the task model is a service, configured like the LLM
Three things from a look at the new model pages.

The next section's rule was drawn on top of the cards: the grid and the
panels below it were siblings, so the container's spacing never applied
between them.

Cards that open now look like it — a chevron in the lower right that
shifts on hover, a border and tint that lift, a press that registers.
They read as panels that happened to be clickable, which is the same as
not clickable. Search cards draw no chevron, because they have no models
to open into, so the two kinds are told apart before you click.

And the task model was wrong twice over. It asked which model should
name conversations and which should write the starting points, as if
anyone would answer those differently — both are short, frequent, and
want the same small fast model. It is one setting now. It also asked for
that model through a flat dropdown, when it is the same kind of thing as
the LLM and deserves the same shape: the catalog carries a `task`
service, so the whole provider/model editor applies to it unchanged, and
a provider already set up for chat can be brought over instead of typed
again. Empty stays the default and the common case — both calls then
resolve the LLM exactly as before, and the page says so and shows which
model that currently is.

Two tests stopped hardcoding the list of services and derive it, so the
next one to be added needs only its own test written.
2026-08-29 21:46:15 +08:00
Bingxi Zhao (Frank)
ed68087fbf fix(settings): make Save draft real, and stop losing edits on navigation
Save Draft and Apply were the same write. Both persisted to the live files
and both invalidated the runtime caches, so nothing but their labels told
them apart — and Save Draft only ever wrote the model catalog, while half
the settings pages (memory, starting points, network, attachments,
document parsing) keep their state outside it.

The result was silent data loss, reproducible in four steps: open Starting
points, change 20 to 44, press Save Draft, read "Draft saved" — the server
still had 20, and navigating away lost the edit with no warning. The
button was enabled, because `hasUnsavedChanges` counted extension state
that `saveCatalog` never touched.

So a draft is now a place rather than a label. One envelope holding the
catalog and a payload per page, stored beside the live settings and read
by nothing else:

    Save draft  → envelope written, runtime untouched
    Apply       → live files written, envelope cleared
    Discard     → envelope dropped, back to what is live

Two other losses closed along the way. Unsaved page state now lives on the
provider instead of the page, so moving around inside Settings keeps it —
a settings page unmounts on every navigation, which is why the edit
vanished. And an edit that exists nowhere else warns before the tab is
closed or reloaded.

The toolbar had no way to say "there is a draft waiting", so a draft saved
yesterday would have sat there unexplained; it now reports which of the
three states you are in. The storage path moved into that line's tooltip —
self-hosted users occasionally want to know which file backs a page, but
it is a developer fact and was on screen for everyone.
2026-08-29 20:27:33 +08:00
Bingxi Zhao (Frank)
d790419548 Merge remote-tracking branch 'origin/dev' into dev 2026-08-29 19:14:40 +08:00
Bingxi Zhao
83546e679f Merge pull request #1069 from NoxsMedia/codex/nox-3-lightrag-native 2026-08-29 18:46:03 +08:00
Bingxi Zhao
42ba832bc8 Merge pull request #1059 from ZQR1101/fix/openai-binding-deepseek-thinking 2026-08-29 18:44:49 +08:00
Bingxi Zhao
8b585a896f Merge pull request #1077 from ZQR1101/fix/memory-probe-permission-error 2026-08-29 11:55:21 +08:00
Bingxi Zhao
92a2fcf077 Merge pull request #1052 from evan188199-tech/codex/fix/book-language-options 2026-08-29 11:51:18 +08:00
Bingxi Zhao
4c4ae414f7 Merge pull request #1075 from evan188199-tech/codex/fix/deepseek-responses-web-search 2026-08-29 11:50:51 +08:00
Bingxi Zhao (Frank)
a9f67eb3aa feat(settings): connections layer + per-task model pinning
Model configuration was one layer replicated seven times: every service
stored its own profile with its own credentials, so a single OpenRouter
key had to be pasted into five separate pages. Every comparable product
(Dify, Open WebUI, Cherry Studio, RAGFlow) splits this in two — a
credential entered once, then a per-purpose assignment — so this adds
that split without disturbing what already works.

Connections
  A connection holds one vendor credential (api_key / api_version /
  extra_headers, plus an optional endpoint override). Linking creates one
  ordinary profile per service that can use it, and the credential is
  mirrored down on save rather than resolved on read — so every consumer
  of the catalog keeps reading self-contained profiles and a linked
  profile resolves exactly like a hand-typed one. Rotating the key in one
  place reaches every linked profile; deleting a connection unlinks
  rather than wipes. Anyone wanting a different key per service simply
  never makes a connection.

  Which services a vendor can serve is derived from the six provider
  tables that already exist (new `connection_targets` in GET /settings),
  so the web app keeps no second copy and adding a vendor to a service
  table is enough to make it connectable.

Task models
  Naming a conversation and writing the three home-screen starting points
  are LLM calls nobody asked for — short, frequent, and fine on a small
  fast model. Both can now be pinned to their own configured model from
  Settings > Models > Task models. Unpinned is the default and a true
  no-op: the title still follows the turn's own model and the starters
  the active one, exactly as before. A pin at a deleted profile reverts
  to inheriting rather than stranding the call.
2026-08-29 11:50:10 +08:00
Bingxi Zhao
f3d43d969b Merge pull request #1025 from evan188199-tech/codex/fix/code-execution-file-artifacts 2026-08-29 11:50:04 +08:00
Bingxi Zhao
acddbb327e Merge pull request #1057 from dongyu-will/codex/deep-question-validation 2026-08-29 11:49:40 +08:00
Bingxi Zhao (Frank)
ca028e3766 Merge remote-tracking branch 'origin/dev' into pr1077 2026-08-29 11:49:04 +08:00
Bingxi Zhao
07bb3c19e9 Merge pull request #1041 from junjiezhou1122/fix/anthropic-sdk-1x-temperature-extra-body 2026-08-29 11:30:11 +08:00
ZQR1101
50ee9a104c fix(runtime): fall back when psutil cannot read /proc
On HarmonyOS, psutil.children() raises raw PermissionError for /proc/1/stat, which is not a psutil.Error subclass and used to 500 GET /api/v1/system/memory. Catch it and use the defensive /proc walker.

Fixes #1076
2026-08-29 11:28:51 +08:00
Bingxi Zhao
a53b5df302 Merge pull request #1050 from ZQR1101/fix/ask-user-unicode-decode-backend 2026-08-29 11:28:49 +08:00
Bingxi Zhao
f12ba50a53 Merge pull request #1043 from evan188199-tech/codex/fix/clawhub-publisher-refs 2026-08-29 11:28:03 +08:00
Bingxi Zhao
8173b7a8f1 Merge pull request #1066 from evan188199-tech/codex/fix/jina-retrieval-roles 2026-08-29 11:27:58 +08:00
Bingxi Zhao
bb37982279 Merge pull request #1017 from ZQR1101/fix/partner-output-fallback 2026-08-29 11:27:52 +08:00
Bingxi Zhao
3f6e82405e Merge pull request #741 from lukiod/fix/secret-file-permissions 2026-08-29 11:27:40 +08:00
XZH
3954e55b38 fix(llm): enable DeepSeek Pro native web search (#846) 2026-08-28 19:38:39 -07:00
Codex
a170658c89 Skip SDK-specific LightRAG tests without optional extra 2026-08-28 22:40:53 +00:00
Codex
cf2b93feac Skip LightRAG smoke tests without optional SDK 2026-08-28 22:31:44 +00:00
XZH
f3c613c842 fix(knowledge): explain scanned PDF parse failures 2026-08-28 12:40:39 -07:00
XZH
f65ce2abd5 fix(embedding): enable Jina retrieval roles 2026-08-28 09:23:28 -07:00
Codex
a87d6bfb72 fix(lightrag): retain uncertain initial candidates 2026-08-28 15:45:28 +00:00
Codex
cefc3471f2 fix(lightrag): preserve partially accepted ingress 2026-08-28 15:33:11 +00:00
Codex
8dce8ee545 Fix LightRAG append recovery and fixture tracking 2026-08-28 15:15:48 +00:00
Codex
6d02ff9299 Replace RAG-Anything with native LightRAG pipeline 2026-08-28 15:04:14 +00:00
ZQR1101
8a0ea496f4 fix(llm): disable DeepSeek flash thinking on openai bindings
openai bindings pointed at DeepSeek never inherited flash's thinking:disabled default, so mid-conversation rounds failed with reasoning_content must be passed back. Infer thinking controls from the model id and replay Chat Completions reasoning on tool-call turns.

Fixes #1058
2026-08-28 21:24:15 +08:00
weidongyu
e0664b21bb fix(question): validate topic before generation 2026-08-28 17:09:59 +08:00
Bingxi Zhao (Frank)
9e54429426 Merge codex/immersive-reading-v2 into dev
# Conflicts:
#	deeptutor/api/routers/mastery_path.py
#	tests/services/session/test_sqlite_store.py
#	web/app/(workspace)/home/[[...sessionId]]/page.tsx
#	web/components/sidebar/SidebarShell.tsx
2026-08-28 15:01:39 +08:00
Bingxi Zhao (Frank)
97a4d0eeef feat(reading): add immersive reading workspace 2026-08-28 14:58:48 +08:00