File size: 438 Bytes
f5776d3 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 |
# ToDo
# Start Weaviate Embedded
# Add Toy Data
# Connect DSPy
# Test this API
"""
from dspy.retrieve.weaviate_rm import WeaviateRM
retriever_model = WeaviateRM("WeaviateBlogChunk", weaviate_client=weaviate_client)
dspy.settings.configure(rm=retriever_model)
retrieve = dspy.Retrieve(k=1)
topK_passages = retrieve("what are the stages in planning, sanctioning and execution of public works").passages
assert(type(topK_passages))
""" |