Find answers from the community

s
F
Y
a
P
Updated last month

Anyone know what is causing this

Anyone know what is causing this ---------------------------------------------------------------------------
ImportError Traceback (most recent call last)
Cell In[5], line 1
----> 1 from llama_index import download_loader, GPTSimpleVectorIndex
2 from pathlib import Path

File ~/.local/lib/python3.9/site-packages/llama_index/init.py:18
15 from llama_index.embeddings.openai import OpenAIEmbedding
17 # structured
---> 18 from llama_index.indices.common.struct_store.base import SQLDocumentContextBuilder
19 from llama_index.indices.composability.graph import ComposableGraph
20 from llama_index.indices.empty import GPTEmptyIndex

File ~/.local/lib/python3.9/site-packages/llama_index/indices/common/struct_store/base.py:9
7 from llama_index.data_structs.node_v2 import Node
8 from llama_index.data_structs.table import StructDatapoint
----> 9 from llama_index.indices.response.builder import ResponseBuilder, TextChunk
10 from llama_index.indices.service_context import ServiceContext
11 from llama_index.langchain_helpers.chain_wrapper import LLMPredictor

File ~/.local/lib/python3.9/site-packages/llama_index/indices/response/builder.py:18
16 from llama_index.data_structs.node_v2 import Node, NodeWithScore
17 from llama_index.docstore_v2 import DocumentStore
---> 18 from llama_index.indices.common.tree.base import GPTTreeIndexBuilder
19 from llama_index.indices.service_context import ServiceContext
...
33 )
34 from llama_index.indices.service_context import ServiceContext
35 from llama_index.optimization.optimizer import BaseTokenUsageOptimizer

ImportError: cannot import name 'RESPONSE_TEXT_TYPE' from partially initialized module 'llama_index.indices.response.builder' (most likely due to a circular import) (/home/gregtanaka/.local/lib/python3.9/site-packages/llama_index/indices/response/builder.py)
j
G
2 comments
sorry for the delay @Greg Tanaka ! just landed a PR and upgraded llama-index to 0.5.4, could you try reinstalling and let me know if issue persists? https://github.com/jerryjliu/llama_index/pull/1001
Thanks. I upgraded my python version and it seemed to fix it
Add a reply
Sign up and join the conversation on Discord