You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
query_engine = SubQuestionQueryEngine.from_defaults(
query_engine_tools=query_engine_tools, response_synthesizer=response_synthesizer,
service_context=service_context,question_gen=question_gen,
) . I am trying to use SubQuestionQueryEngine using LLAMA 2 model and it throws .local/lib/python3.10/site-packages/llama_index/core/query_engine/sub_question_query_engine.py", line 234, in _aquery_subq
query_engine = self._query_engines[sub_q.tool_name]
KeyError: 'uber_10k' error , I tried using LLMQuestionGenerator with custom service context passed into it and played with number of maximum tokens but nothing helped to resolve the issue . So, if anyone could help me with this issue would be great.
The KeyError: 'uber_10k' error indicates that the SubQuestionQueryEngine cannot find a query engine named uber_10k in its _query_engines dictionary. This usually means that the tool uber_10k is either not registered or not correctly initialized in the query_engine_tools sequence you're passing to SubQuestionQueryEngine. Here's how you can address this issue:
Verify Tool Registration: Make sure the uber_10k tool is correctly included in the query_engine_tools with the right name attribute.
Check Tool Initialization: Ensure that the query engine for uber_10k is properly initialized and included when creating the SubQuestionQueryEngine.
Consistency in Configuration: If the tool's name or initialization logic has changed, ensure these changes are applied consistently across your application.
If uber_10k is intended for use, confirming its registration and initialization should solve the problem. If it's not meant to be used, ensure no sub-questions are generated that require this tool. This might involve adjusting the LLMQuestionGenerator or its configuration to avoid generating sub-questions targeting uber_10k.
About Dosu
This response is meant to be useful and save you time. It is not meant to be a precise solution, but rather a starting point for your own research.
Help me be more useful! Please leave a 👍 if this is helpful and 👎 if it is irrelevant.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
query_engine = SubQuestionQueryEngine.from_defaults(
query_engine_tools=query_engine_tools, response_synthesizer=response_synthesizer,
service_context=service_context,question_gen=question_gen,
) . I am trying to use SubQuestionQueryEngine using LLAMA 2 model and it throws .local/lib/python3.10/site-packages/llama_index/core/query_engine/sub_question_query_engine.py", line 234, in _aquery_subq
query_engine = self._query_engines[sub_q.tool_name]
KeyError: 'uber_10k' error , I tried using LLMQuestionGenerator with custom service context passed into it and played with number of maximum tokens but nothing helped to resolve the issue . So, if anyone could help me with this issue would be great.
Beta Was this translation helpful? Give feedback.
All reactions