mirror of
https://github.com/khoaliber/khoj.git
synced 2026-03-02 21:19:12 +00:00
Rename 'embed' key to more generic 'compiled' for jsonl extracted results
- While it's true those strings are going to be used to generated embeddings, the more generic term allows them to be used elsewhere as well - Their main property is that they are processed, compiled for usage by semantic search - Unlike the 'raw' string which contains the external representation of the data, as is
This commit is contained in:
@@ -13,9 +13,9 @@ from src.search_filter import date_filter
|
||||
def test_date_filter():
|
||||
embeddings = torch.randn(3, 10)
|
||||
entries = [
|
||||
{'embed': '', 'raw': 'Entry with no date'},
|
||||
{'embed': '', 'raw': 'April Fools entry: 1984-04-01'},
|
||||
{'embed': '', 'raw': 'Entry with date:1984-04-02'}]
|
||||
{'compiled': '', 'raw': 'Entry with no date'},
|
||||
{'compiled': '', 'raw': 'April Fools entry: 1984-04-01'},
|
||||
{'compiled': '', 'raw': 'Entry with date:1984-04-02'}]
|
||||
|
||||
q_with_no_date_filter = 'head tail'
|
||||
ret_query, ret_entries, ret_emb = date_filter.date_filter(q_with_no_date_filter, entries.copy(), embeddings)
|
||||
|
||||
Reference in New Issue
Block a user