mirror of
https://github.com/arc53/DocsGPT.git
synced 2025-11-29 08:33:20 +00:00
(fix:chunks) preserve paths
This commit is contained in:
@@ -156,14 +156,18 @@ const DocumentChunks: React.FC<DocumentChunksProps> = ({
|
||||
|
||||
const handleAddChunk = (title: string, text: string) => {
|
||||
try {
|
||||
const metadata = {
|
||||
source: path || documentName,
|
||||
source_id: documentId,
|
||||
title: title,
|
||||
};
|
||||
|
||||
userService
|
||||
.addChunk(
|
||||
{
|
||||
id: documentId,
|
||||
text: text,
|
||||
metadata: {
|
||||
title: title,
|
||||
},
|
||||
metadata: metadata,
|
||||
},
|
||||
token,
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user