类class
agentscope.app.storageKnowledgeBaseRecord
class KnowledgeBaseRecord(_RecordBase)
源码Source
agentscope/app/storage/_model/_knowledge_base.py:87–144知识库记录,在多次调用之间保存和恢复会话与记忆数据。位于 agentscope.app.storage 包,继承自 _RecordBase。
Stores per-user metadata for a knowledge base; the actual chunks
and vectors live in the configured VectorStoreBase backend.
Each record is the canonical authorisation gate: HTTP handlers and
middleware look the record up by (user_id, id) before talking
to the vector store.
属性摘要Attribute Summary
| 属性Attribute | 类型Type | 说明Description | 值Value |
|---|---|---|---|
user_id | str | 所有者用户标识。 | Field(description='The owner user id.') |
data | KnowledgeBaseData | 数据字段。 | — |
属性详情Attribute Detail
user_id
str = Field(description='The owner user id.')所有者用户标识。
The owner user id.
源码Source
agentscope/app/storage/_model/_knowledge_base.py:97data
KnowledgeBaseData数据字段。声明为 KnowledgeBaseData。
The data field.
源码Source
agentscope/app/storage/_model/_knowledge_base.py:100