added llm and rag queries
This commit is contained in:
@@ -15,9 +15,4 @@ def create_and_index(
|
||||
return embeddings
|
||||
|
||||
|
||||
def query_embedding(
|
||||
embeddings: Embeddings, query: str, limit: int = 100
|
||||
) -> list[str]:
|
||||
"""Search embeddings and return matching texts."""
|
||||
results = embeddings.search(query, limit)
|
||||
return [r["text"] for r in results]
|
||||
|
||||
|
||||
Reference in New Issue
Block a user