private-gpt icon indicating copy to clipboard operation
private-gpt copied to clipboard

chromadb.errors.NoIndexException: Index not found, please create an instance before querying

Open Nixon-hk opened this issue 1 year ago • 7 comments

Dear guys, I just tried to implement my private gpt in collab, and after I implement the code !python /content/drive/MyDrive/my-git-repo/privateGPT.py

and it goes this error after I enter the question in query:

File "/usr/local/lib/python3.10/dist-packages/chromadb/db/index/hnswlib.py", line 240, in get_nearest_neighbors raise NoIndexException( chromadb.errors.NoIndexException: Index not found, please create an instance before querying

Does someone have any idea to solve this ? Thanks a lot!!!

Environment

  • OS / hardware: collab
  • Python version [e.g. 3.10.3]

Nixon-hk avatar May 20 '23 23:05 Nixon-hk

This could be because your index was not loaded successfully. Was your ingest.py successful?

Elicherla01 avatar May 21 '23 02:05 Elicherla01

I had this same problem today, it happened to me when I called the script from another location. Navigate to where you have the installation and you will see that the ingest works fine.

psegovias avatar May 21 '23 02:05 psegovias

https://github.com/maozdemir/privateGPT-colab

maozdemir avatar May 21 '23 11:05 maozdemir

https://github.com/maozdemir/privateGPT-colab

Thanks for your suggestion! But I found some error when loading this koala-7B-GGML package

image

Thanks again!!

Nixon-hk avatar May 21 '23 22:05 Nixon-hk

This could be because your index was not loaded successfully. Was your ingest.py successful? Thank you so much for your suggestion ! It seems succesful to load the ingest.py ! still do not know where the problems are gpt

Nixon-hk avatar May 21 '23 23:05 Nixon-hk

I had this same problem today, it happened to me when I called the script from another location. Navigate to where you have the installation and you will see that the ingest works fine.

Thanks for your suggestions! But seems the ingest.py work fine with right location? gpt And here is my constants.py file gpt_3

Thanks again!

Nixon-hk avatar May 21 '23 23:05 Nixon-hk

This could be because your index was not loaded successfully. Was your ingest.py successful? I just found that there seems an error detected in my ingest.py, seems the "Import "constants" could not be resolvedPyright(reportMissingImports)", but I do not know why it happended. Do you have any ideas? Thanks a lot!! gpt_2

And here is my constants.py file gpt_3 Thanks a lot!!

Nixon-hk avatar May 22 '23 00:05 Nixon-hk