toradb.integrations.
Example
Requirements
Install ToraDB with Install. LlamaIndex packages are optional depending on your integration layer. For a full walkthrough, runpython examples/full_example.py (section 17).Documentation Index
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
ToraDBLlamaIndexStore adapter
toradb.integrations.
import toradb
from toradb.integrations import ToraDBLlamaIndexStore
db = toradb.local("./my_db")
articles = db.table("articles")
li_store = ToraDBLlamaIndexStore.from_table(articles)
class SimpleNode:
def __init__(self, text: str):
self.text = text
li_store.add([
SimpleNode("Summary of Nikola Tesla AC motor patents and demonstrations"),
])
result = li_store.query("AC motor Tesla", similarity_top_k=2)
print(result.to_pandas())
python examples/full_example.py (section 17).