Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

list index out of range error while loading knowledge_base using LanceDb #1855

Open
AhmadShaik opened this issue Jan 22, 2025 · 0 comments
Open

Comments

@AhmadShaik
Copy link

I am trying to create a TextKnowledgeBase using LanceDb with Ollamaembedder model. The script worked for some documents and started throwing below error, I tried running multiple times, but the got the same error.
The total text documents are nearly 10k and all contains data. The error is coming at around 100th file.

vector_db = LanceDb(
    table_name="recipes",
    uri="/tmp/lancedb",
    embedder=OllamaEmbedder()
)

knowledge_base = TextKnowledgeBase(
    path=txt_path,
    vector_db=vector_db
    # vector_db=ChromaDb(collection="auto_zone", embedder=OllamaEmbedder()),
    # chunking_strategy=SemanticChunking()
)

knowledge_base.load(recreate=False)

Error Message

Exception has occurred: IndexError
list index out of range
  File "/media/ahamad/work/projects/auto_zone/Autozone_experiments/knowledge_base.py", line 43, in <module>
    knowledge_base.load(recreate=False)
IndexError: list index out of range
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant