fixed duplicat enrichment
This commit is contained in:
@@ -172,13 +172,7 @@ def fetch_bm25_corpus_records(session: Session) -> list[dict[str, object]]:
|
||||
EbookSource.author.label("source_author"),
|
||||
EbookChapter.title.label("chapter_title"),
|
||||
EbookChunk.page_label.label("page_label"),
|
||||
func.concat_ws(
|
||||
" ",
|
||||
EbookSource.title,
|
||||
EbookSource.author,
|
||||
EbookChapter.title,
|
||||
EbookChunk.search_text,
|
||||
).label("bm25_text"),
|
||||
EbookChunk.search_text.label("bm25_text"),
|
||||
)
|
||||
.select_from(EbookChunk)
|
||||
.join(EbookSource, EbookSource.id == EbookChunk.source_id)
|
||||
|
||||
Reference in New Issue
Block a user