mirror of
https://github.com/MODSetter/SurfSense.git
synced 2026-06-28 21:49:40 +02:00
fix(chunks): set position on remaining chunk insert paths
document_converters, the github size-fallback chunker, revert_service restores, and the kb-persistence middleware now write explicit positions (the middleware read path also orders by position).
This commit is contained in:
parent
7d55aaf2c1
commit
5a71769dba
4 changed files with 43 additions and 12 deletions
|
|
@ -525,6 +525,7 @@ async def _simple_chunk_content(content: str, chunk_size: int = 4000) -> list:
|
|||
Chunk(
|
||||
content=chunk_text,
|
||||
embedding=embed_text(chunk_text),
|
||||
position=len(chunks),
|
||||
)
|
||||
)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue