30 Commits

Author SHA1 Message Date
Bingxi Zhao (Frank)
399297e7f0 feat: preserve TypeScript engine migration and workspace updates 2026-10-18 23:09:10 +08:00
Bingxi Zhao (Frank)
b0385a315d feat(knowledge): choose storage and move individual bases 2026-09-27 11:04:33 +08:00
Bingxi Zhao (Frank)
de5ecb9b2a fix(tooltips): migrate data and admin button hints (#1526) 2026-09-27 10:25:50 +08:00
NoxsMedia
ac8cc4a97d fix: preserve selected embeddings in confirmed LightRAG rebuilds 2026-09-21 02:57:39 +00: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
NoxsMedia
7266c7aacf chore: sync PR #1265 with current dev 2026-09-07 23:33:46 +00:00
Bingxi Zhao (Frank)
e7d04fccfc fix(knowledge): validate KB names on the manager, and let a bad one be deleted
A knowledge-base name is three things at once: a kb_config.json key, a
directory under data/knowledge_bases, and a path segment in every per-KB API
route. `validate_knowledge_base_name` exists to keep those three uses
compatible — its docstring says so — but it was called from one of the eight
HTTP entry points that can write a name into the config. The seven connect-*
endpoints (Obsidian, MarginNote, folder, LightRAG server, WeKnora, IMA, and
the subagent connection) did `(name or "").strip()` and wrote the result.

A name holding a "/" registers fine that way and is then unreachable.
uvicorn percent-decodes the path before routing, so %2F is a real separator
by the time Starlette matches `{kb_name}` — compiled to `[^/]+`, which cannot
span it. All 29 per-KB routes 404, delete included, while the list endpoint
takes no path parameter and keeps rendering the KB. Connected KBs are also
exempt from the orphan prune, so nothing collects it either: visible, unusable,
and removable only by hand-editing kb_config.json.

Two changes, both needed. Validation moves onto the eight `register_*`
methods, which is the seam every route already goes through — no route file
changes, since they all map ValueError to 400 — and the now-unreachable
"name is required" guards go with it. And a path-free
`POST /knowledge-bases/delete` gives the entries that predate the guard a way
out; a body is never split into segments. Widening the path route to
`{kb_name:path}` would not work: it is declared ahead of the DELETE routes
for linked folders, GitHub sources and web sources, and a greedy converter
would silently swallow all three.

Two smaller fixes ride along. The delete handler's catch-all swallowed its
own HTTPException and answered 500 with "404: ... not found" in the detail;
it now re-raises. And CreateKbModal states the rule under the field instead
of letting an untranslated English 400 be the first the user hears of it.

test_marginnote4_kb's store-collision case used "My Lib" / "My/Lib"; the
slash is now refused before that guard is reached, so it uses "My.Lib" —
still a name the rule allows, still sanitized to the same My_Lib.db.
2026-09-08 00:31:59 +08:00
NoxsMedia
80d257d55e refactor: unify LightRAG defaults and confirmed rebuilds 2026-09-07 08:07:00 +00:00
NoxsMedia
814081f36d fix(lightrag): close role model audit gaps 2026-09-06 16:51:18 +00:00
NoxsMedia
4dd9254c0f refactor(lightrag): clarify role model controls 2026-09-06 13:23:33 +00:00
NoxsMedia
446b3aab7e feat(lightrag): configure independent role models and pinned vision indexing 2026-09-06 09:58:42 +00:00
NoxsMedia
9cd1912c14 feat: add LightRAG indexing model controls and provenance (#1174)
* feat(knowledge): add LightRAG indexing model controls

* fix(knowledge): close NOX-21 review findings

* fix(knowledge): resolve NOX-21 review blockers

* fix(knowledge): identify unpublished LightRAG builds

* style: format LightRAG indexing changes

* fix(knowledge): align indexing controls with LightRAG model

* fix(knowledge): close indexing UI review blockers

* style: format knowledge router
2026-09-03 15:56:55 +08:00
Bingxi Zhao (Frank)
cd195e977a refactor(web): split knowledge clients and engine forms 2026-09-01 18:55:55 +08:00
Bingxi Zhao (Frank)
cd286801b6 Merge pull request #1074 from evan188199-tech/codex/feat/weknora-server
# Conflicts:
#	web/components/knowledge/CreateKbModal.tsx
#	web/components/knowledge/EngineDetail.tsx
#	web/components/knowledge/KnowledgeHome.tsx
2026-08-31 19:40:31 +08: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
XZH
8460fb7ec5 feat(knowledge): add WeKnora retrieval connections (#918) 2026-08-28 16:47:43 -07:00
evan188199-tech
50f8ccbaa4 feat: split knowledge sync - add GitHub source sync (#903)
* feat(knowledge): add GitHub source sync

* fix(github-sync): contain downloaded paths inside the KB raw dir

Destinations were built as `raw_dir / rel` where `rel` is derived from the
GitHub tree/compare response — remote input. Two shapes escaped: a `..`
segment, and an absolute path, which is the quieter one because
`Path("/kb") / "/etc/x"` is `/etc/x`, silently discarding the base. The only
filters in the way checked the file extension and the glob, so a matching
path would have been written — and, on the removal branch, deleted — outside
the knowledge base.

git rejects both shapes in tree entries today, so this is defence in depth
rather than a live exploit; a downloader still should not delegate to the
remote the question of where it writes. One `_contained_dest` seam now guards
the full-sync write, the incremental write, and the removal, and logs what it
refused.

---------

Co-authored-by: XZH <cto@xzh.ai>
Co-authored-by: Frank <bingxizhao@novix.science>
2026-08-24 16:55:47 +08:00
Bingxi Zhao (Frank)
2af5ba7abf feat(knowledge): give MarginNote 4 libraries a frontend
The connected KB type landed with no way to create one and no way to
pair the add-on that fills it, so the feature was unreachable from the
app.

Connecting: a MarginNote card in the create modal's link sources. It
asks for a name and nothing else — `db_path` is deliberately not sent, so
the store's location keeps one rule and pairing, the add-on's syncs and
the capability binding cannot disagree.

Feeding it: a Devices tab on the library, with the paired-device list,
revoke, and the one-time token shown once at pairing (the server keeps
only a hash). Every call names its library through `X-MN4-KB`, which is
what makes the token findable by the syncs that present it.

The detail view's sections are now derived rather than fixed: a library
owns no raw files and builds no index, so Files / Add documents / Index
versions rendered empty against it, the header read "llamaindex ·
Default embedding" for a pipeline it never runs, Settings offered an
on-disk path that does not exist, and Retry indexing offered to re-run
nothing. Each now reports what the library actually has.
2026-08-21 22:51:05 +08:00
Bingxi Zhao (Frank)
31bf66b5e1 release: v1.5.15
Self-hostable PageIndex, a fileable question bank, and third-party plugins.

- PageIndex: adds PageIndex OSS as its own knowledge-base type, bound to
  the base's local library and driven by the configured LLM rather than a
  PageIndex API key. Retrieval moves off the built-in MCP server (removed)
  onto a workflow-owned reading loop that walks the document tree.
- Question bank: addEntryToCategory shipped in v1.3.6 and was never called
  from the frontend, so categories could be created but never filled. The
  quiz card now uses the shared CategoryMenu, the page is rebuilt around
  search / batch selection / an unfiled inbox, and a new question_bank tool
  lets the tutor file questions instead of misrouting them to write_note.
- Plugins: deeptutor.plugins was imported behind a try/except but the
  module never existed — implemented, plus a deeptutor.loop_capabilities
  group so third-party packages can register chat-loop capabilities.
  Builtins win on name collisions; broken entry points are skipped.
- Parsing: remote Apache Tika engine (TIKA_SERVER_URL), with no local
  package and no model download.
- LightRAG: the three indexing knobs from #877 get inputs under their own
  Indexing divider; unsupported keywords are dropped with a warning.
- Knowledge bases: uploads take a destination folder, same-named documents
  from different subtrees stop dropping one another, and linked folders
  keep their source-relative structure — closing #866.
- Book: a learning-capture inbox with an explicit status lifecycle, and
  drift warnings scoped to the KB documents that actually changed.
- Whisper: /whisper moves out of the primary nav into Learning Space →
  More Projects, credited to its contributor; the room needs its own
  capability package. The reusable half is CAPABILITY_COMPLETE forwarding
  of a capability-declared body and its declared extras.
- README: a Collaborate badge beside the Docs badge, in all twelve
  languages.
- Lint: nosec B608 on four false-positive question-bank queries (literal
  fragments only, every value bound), and three mypy fixes.

Release notes: assets/releases/ver1-5-15.md
2026-08-20 14:15:53 +08:00
Bukely_
07abbd7326 feat(pageindex): add OSS knowledge bases and reasoning-based retrieval (#907)
Adds PageIndex OSS as a knowledge-base type and moves PageIndex retrieval from traditional RAG to reasoning-based retrieval: a small workflow-owned agent loop reads the document tree instead of going through the built-in MCP server, which this removes.
2026-08-20 00:35:15 +08:00
Bingxi Zhao (Frank)
96d6df9eb1 release: v1.5.13
Book is the bulk of this one. Compilation outlives the request that
started it, so a bus owned by that request dropped every background event
and "watch your book being written" degraded into a frozen page; the
stream is now owned per book by the process and survives a refresh or a
reconnect. Reading progress is finally recorded — `visited_page_ids` and
`bookmarked_page_ids` had been declared but never written for the life of
the feature — and rolls up into a completion score and weak chapters. A
book can also leave the app now, as one self-contained Markdown document,
with non-ASCII titles surviving the download.

Two scheduling defects that were invisible in production are fixed: the
same page compiled twice concurrently (billed twice, one result
discarded), and a book grinding on through a provider outage until every
chapter was half-generated. The source sweep is bounded and allocated
round-robin rather than spent on the first few knowledge bases, and
retrieval now tells indexed bases from connected pointers, so an Obsidian
vault or a remote IMA library no longer contributes zero while looking
like a source with nothing relevant. Confirming a spine shows a live
per-chapter estimate derived from the Section Architect's own templates.

Also here: three home starter suggestions built from memory recall,
mastery-path handoff moved into one module that changes lease, session
preference, and live turn together, and account-level Tencent IMA
credentials with the per-KB pair still winning.

Notes: assets/releases/ver1-5-13.md

This commit also carries the README prose sync, the eleven translated
READMEs, the release-notes archive sweep, and the version bump. Two gate
fixes ride along: the `Stamped` protocol is declared read-only so the
frozen `EntityStamp` satisfies it, and six GraphRAG adapter tests that
reached a deep `graphrag` import without guarding it now skip like their
four neighbours instead of failing where the extra is not installed.
2026-08-17 11:22:26 +08:00
HarryH
773ae04ce7 修复 IMA 只读连接与原文检索 (#873)
* 文档:明确 IMA 只读连接流程

* 文档:细化 IMA 连接状态与安全边界

* 文档:制定 IMA 只读连接实现计划

* 测试:固定 IMA 知识库列表协议

* 功能:支持枚举 IMA 知识库

* 功能:新增安全的 IMA 知识库列表接口

* 修复:说明 IMA 按知识库连接状态

* 功能:增加 IMA Web 连接接口

* 功能:接入 IMA 只读知识库连接表单

* 文案:补齐 IMA 连接流程中英文

* 修复:适配 IMA 知识库列表字段

* 修复:完善 IMA 认证与凭据清理

* 格式:统一 IMA 模块代码样式

* fix: load IMA source content safely

---------

Co-authored-by: TyrionH-is-coding <TyrionH-is-coding@users.noreply.github.com>
Co-authored-by: Bingxi Zhao (Frank) <13051345080@163.com>
2026-08-17 00:34:04 +08:00
Bingxi Zhao (Frank)
ed6aedf892 fix(knowledge): stop the indexing poll from wiping the create-KB form (#691)
CreateKbModal's reset effect was keyed on the providers array, which the
4s background-indexing poll replaces on every tick, so typed input and
loaded files vanished while another KB was indexing. Reset only on the
closed-to-open transition, and keep the providers reference stable in
useKnowledgeBases when a refresh returns identical content.
2026-07-24 17:39:07 +08:00
BukeLy
2e82ad4d27 feat(pageindex): agentic retrieval via MCP tools + full document-endpoint format support
PageIndex deprecated its REST retrieval endpoint; deep retrieval is now
agentic through the hosted PageIndex MCP server, while search() serves
programmatic callers with real document tree outlines.

- New built-in "pageindex" MCP server entry, code-injected at manager load
  when an API key is configured (never persisted to mcp.json; user-defined
  entry wins; hot-reloads on key change). remove_document is blocked via a
  new MCPServerConfig.disabled_tools blocklist.
- Chat turns with a PageIndex KB attached get the server's tools preloaded
  under a narrowed implicit grant (KB access = permission), plus a system
  prompt block listing the KB's file -> doc_id manifest with usage notes.
  The rag tool's kb_name enum excludes PageIndex KBs (a pure-PageIndex
  conversation doesn't mount rag), so the agent reads those docs via MCP.
- PageIndexPipeline.search() now returns each document's tree outline
  (titles / pages / summaries) fetched over REST (GET /doc/{id}/?summary=true)
  as honest structural context for programmatic callers (book, co-writer,
  seed, CLI). No new error_type; existing not_configured / retrieval_error /
  needs_reindex semantics are unchanged. The dead REST retrieval client
  methods are deleted. Existing KBs need no migration.
- SUPPORTED_EXTENSIONS now mirrors POST /doc/: pdf, md, markdown, txt, docx,
  doc, pptx, ppt, xlsx, xls, csv (zip stays a local container); frontend
  format list + copy updated (en/zh).
2026-07-15 18:21:43 +08:00
Bingxi Zhao (Frank)
30b92dfe86 release: v1.4.12
LightRAG Server retrieval engine, PyMuPDF4LLM document parsing, and a
FAISS vector backend that makes large knowledge-base retrieval far faster.
Drop-in — existing knowledge bases keep working; re-index to move onto FAISS.

- LightRAG Server: connect a KB to a standalone LightRAG server over HTTP
  (no local index); per-KB server URL + optional API key, always available.
- PyMuPDF4LLM: lightweight, image-capable parsing engine (no CUDA, no model
  downloads); background install from Settings → Document Parsing.
- FAISS: faiss-cpu + llama-index-vector-stores-faiss as core deps, lazy
  import with graceful SimpleVectorStore fallback (issue #552).
- Release notes (ver1-4-12.md), version bump to 1.4.12, README prose +
  Releases row, and all 10 translated READMEs synced.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-24 16:24:08 +08:00
Bingxi Zhao (Frank)
eef785ae1e integrate lightrag-server & other fixes. 2026-06-24 15:54:12 +08:00
Bingxi Zhao (Frank)
7ac3a3ba79 release: v1.4.6
A broad consolidation release across four product surfaces.

- Learning Space: Space becomes a learning dashboard; My Agents imports
  local Claude Code / Codex chat history into resumable agents (with an
  objective explore_context briefing so the tutor never role-plays the
  user); Memory is promoted to a top-level /memory route; Partner
  conversations flow into Memory; EduHub skills install inline.
- Knowledge Center: /knowledge rebuilt as a console with per-engine
  detail pages; GraphRAG / PageIndex / LightRAG engines join LlamaIndex;
  linked-KB read-only mounts; Obsidian live-vault capability.
- Settings: pluggable document parsing (MinerU / Docling / MarkItDown)
  with a content-addressed cache and MinerU cloud/local backends; voice
  TTS/STT; image & video generation; rebuilt settings navigation.
- Platform: per-user capability gating by assigned model; Solve rebuilt
  on the chat loop with a per-step gate and mid-run failure fallback;
  username login + inline errors; CLI skill publish/update; picker
  polish; math-before-citation render fix.

Docs were split out to a standalone site, so site/ is now landing-page
only. Bumps __version__ to 1.4.6 and adds assets/releases/ver1-4-6.md.

Folds in mypy fixes surfaced by pre-commit (mineru/local Path typing,
knowledge/manager no-redef, explore_context token kwargs, CLI
set_dist_tag capability probe) plus prettier reformatting of
previously-committed web files.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-17 10:50:44 +08:00
Bingxi Zhao (Frank)
c9d387e2b6 super super great great update 2026-06-17 00:56:27 +08:00
Bingxi Zhao (Frank)
824bf778df fix: lint & logging system 2026-05-01 01:39:08 +08:00
Bingxi Zhao (Frank)
7fce54d98a chore: prepare v1.3.0 release
Made-with: Cursor
2026-04-27 21:09:25 +08:00