Feat/support parent child chunk (#12092)
This commit is contained in:
parent
017d7538ae
commit
9231fdbf4c
54 changed files with 2578 additions and 808 deletions
19
api/core/entities/knowledge_entities.py
Normal file
19
api/core/entities/knowledge_entities.py
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
from typing import Optional
|
||||
|
||||
from pydantic import BaseModel
|
||||
|
||||
|
||||
class PreviewDetail(BaseModel):
|
||||
content: str
|
||||
child_chunks: Optional[list[str]] = None
|
||||
|
||||
|
||||
class QAPreviewDetail(BaseModel):
|
||||
question: str
|
||||
answer: str
|
||||
|
||||
|
||||
class IndexingEstimate(BaseModel):
|
||||
total_segments: int
|
||||
preview: list[PreviewDetail]
|
||||
qa_preview: Optional[list[QAPreviewDetail]] = None
|
||||
Loading…
Add table
Add a link
Reference in a new issue