Skip to content

Commit 0367ddf

Browse files
committed
fix: bug
1 parent 6b05a0a commit 0367ddf

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

packages/backend/server/src/plugins/copilot/tools/doc-semantic-search.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,9 @@ function clearEmbeddingChunk(chunk: ChunkSimilarity): ChunkSimilarity {
2525
if (FILTER_PREFIX.some(prefix => lines[0].startsWith(prefix))) {
2626
lines.shift();
2727
maxLines--;
28+
} else {
29+
// only process consecutive metadata rows
30+
break;
2831
}
2932
}
3033
return { ...chunk, content: lines.join('\n') };

0 commit comments

Comments
 (0)