CHAT-303 P0 | material 会话检索范围:只检索当前资料 #87

Closed
opened 2026-06-06 16:23:23 +08:00 by wangdl · 1 comment
Owner

目标

资料会话的 loadContext 只检索当前资料内容。

检索内容

  • 当前资料全文(分块取前 N 个 chunk)
  • 当前资料生成的知识点
  • 当前资料相关笔记
  • 若携带 readingPosition,附加上下文

system prompt

你正在回答当前资料的问题。优先基于当前资料回答。引用来源应指向该资料。

## 目标 资料会话的 loadContext 只检索当前资料内容。 ## 检索内容 - 当前资料全文(分块取前 N 个 chunk) - 当前资料生成的知识点 - 当前资料相关笔记 - 若携带 readingPosition,附加上下文 ## system prompt 你正在回答当前资料的问题。优先基于当前资料回答。引用来源应指向该资料。
wangdl added this to the M7:ChatScope 会话系统 — 学习对象绑定的上下文会话 milestone 2026-06-06 16:23:23 +08:00
Author
Owner

完成情况

loadContextByScope case material:

  • 检索范围: 只检索 sourceRef = scopeId 的知识点
  • SQL: WHERE knowledgeBaseId = kbId AND sourceRef = scopeId AND deletedAt IS NULL
  • 涉及: src/modules/rag-chat/rag-chat.service.ts
## 完成情况 loadContextByScope case material: - 检索范围: 只检索 sourceRef = scopeId 的知识点 - SQL: WHERE knowledgeBaseId = kbId AND sourceRef = scopeId AND deletedAt IS NULL - 涉及: src/modules/rag-chat/rag-chat.service.ts
Sign in to join this conversation.
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: wangdl/api-server#87
No description provided.