Find answers from the community

Updated 2 years ago

Load error

At a glance

A community member is experiencing an error when loading a GPTSimpleVectorIndex from disk using version 0.5.9. The error occurs in the /llama_index/vector_stores/registry.py file with a KeyError: '__type__'. The community member suspects the issue is related to changes in the gpt_index/constants.py file, where the VECTOR_STORE_CONFIG_DICT_KEY was removed and two new keys were added: VECTOR_STORE_KEY and ADDITIONAL_QUERY_CONTEXT_KEY.

In the comments, other community members suggest trying to upgrade or re-create the index. The community member tried upgrading but it did not solve the issue. However, re-creating the index did solve the problem, as noted by the community member who said "yes, re creating the index solved the issue. Thanks @Logan M".

Hi, I'm having an error from version 0.5.9

GPTSimpleVectorIndex.load_from_disk('path_to_my_index')
is failing in /llama_index/vector_stores/registry.py with KeyError: '__type__'

I was checking the changelog of 0.5.9 but I can't figure what's the error, I gues it's is related with the change in gpt_index/constants.py :
VECTOR_STORE_CONFIG_DICT_KEY = "vector_store" was removed and these two keys were added:
Plain Text
VECTOR_STORE_KEY = "vector_store"
ADDITIONAL_QUERY_CONTEXT_KEY = "query_context"


but that's all I can see
L
e
f
5 comments
I'm assuming this is during index loading?

Have you tried upgrading? Otherwise is it possible to re-create the index?
upgrading didn't solve the issue but I didn't tried to re create the index
I will try that
I had similar and it was because my index-creating codebase and my inference codebase used diff. versions of llama ..!
yes, re creating the index solved the issue. Thanks @Logan M
Add a reply
Sign up and join the conversation on Discord