Skip to content

Support default namespace document compatibility - #117

Merged
suguanYang merged 5 commits into
mainfrom
feat/suguan/default-namespace-compat
Jun 27, 2026
Merged

Support default namespace document compatibility#117
suguanYang merged 5 commits into
mainfrom
feat/suguan/default-namespace-compat

Conversation

@suguanYang

@suguanYang suguanYang commented Jun 26, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Sends new Notebook uploads to Knowhere namespace default with safe documentMetadata for display/client origin.
  • Lists compatible published Knowhere documents from both default and the legacy workspace namespace, then localizes those documents into regular Notebook sources rows before UI, chunks, archive, and chat flows use them.
  • Removes the synthetic knowhere-doc:* remote source action path; chunk/archive routes now require a localized Notebook source row or a canonical demo source.
  • Adds a workspace/document unique partial index so localization is idempotent by workspace_id + knowhere_document_id for live rows.
  • Preserves active Notebook upload reconciliation state during localization so rows with a local parsing job keep their knowhereJobId until the existing job workflow stores parse assets and marks the source ready.
  • Queries chat retrieval across default plus the legacy workspace namespace and merges successful retrieval responses.
  • Uses the SDK-shaped job creation contract for upload metadata and stores the planned Knowhere documentId directly when job creation returns it.

Companion backend PR: Ontos-AI/knowhere#177
Companion SDK PR: Ontos-AI/knowhere-node-sdk#99

Testing

  • ./node_modules/.bin/vitest run src/domains/sources/route-service.test.ts src/domains/sources/source-row-repository.test.ts 'src/app/api/sources/[sourceId]/route.test.ts' 'src/app/api/sources/[sourceId]/chunks/route.test.ts' src/domains/workspace/initial-state.test.ts src/domains/chat/route-service.test.ts src/domains/chat/index.test.ts src/domains/sources/upload.test.ts src/integrations/knowhere.test.ts
  • ./node_modules/.bin/tsc --noEmit --pretty false
  • changed-file ./node_modules/.bin/eslint ...
  • git diff --check

Notes:

  • Notebook AGENTS asks to consult effect-solutions for Effect changes, but effect-solutions is not installed on this machine (command not found), so this follows existing local Effect patterns.

@vercel

vercel Bot commented Jun 26, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
knowhere-notebook-staging Ready Ready Preview, Comment Jun 26, 2026 7:12pm
1 Skipped Deployment
Project Deployment Actions Updated (UTC)
knowhere-notebook Ignored Ignored Preview Jun 26, 2026 7:12pm

Request Review

@suguanYang
suguanYang merged commit 1dedcb4 into main Jun 27, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant