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

Pro Search errors - Llama3 + searxng #71

Open
LaneBirmingham opened this issue Jul 8, 2024 · 0 comments
Open

Pro Search errors - Llama3 + searxng #71

LaneBirmingham opened this issue Jul 8, 2024 · 0 comments

Comments

@LaneBirmingham
Copy link

I have encountered some errors when using the prosearch feature with Llama3 + searxng.

It is unclear to me the root cause of the KeyError: 'name' error.

I also found that queries following the initial error fail due to a QueryPlan validation issue.

INFO:     192.168.0.65:65266 - "POST /chat HTTP/1.1" 200 OK
all values are hidden
Give Feedback / Get Help: https://github.com/BerriAI/litellm/issues/new
LiteLLM.Info: If you need to debug this error, use `litellm.set_verbose=True'.
all values are hidden
all values are hidden
Provider List: https://docs.litellm.ai/docs/providers
all values are hidden
all values are hidden
Give Feedback / Get Help: https://github.com/BerriAI/litellm/issues/new
LiteLLM.Info: If you need to debug this error, use `litellm.set_verbose=True'.
all values are hidden
all values are hidden
Provider List: https://docs.litellm.ai/docs/providers
all values are hidden
Traceback (most recent call last):
  File "/workspace/.venv/lib/python3.11/site-packages/litellm/main.py", line 2325, in completion
    generator = ollama_chat.get_ollama_response(
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/workspace/.venv/lib/python3.11/site-packages/litellm/llms/ollama_chat.py", line 307, in get_ollama_response
    "name": function_call["name"],
            ~~~~~~~~~~~~~^^^^^^^^
KeyError: 'name'
all values are hidden
During handling of the above exception, another exception occurred:
all values are hidden
Traceback (most recent call last):
  File "/workspace/src/backend/agent_search.py", line 311, in stream_pro_search_qa
    async for event in stream_pro_search_objects(request, llm, query, session):
  File "/workspace/src/backend/agent_search.py", line 115, in stream_pro_search_objects
    query_plan = llm.structured_complete(
                 ^^^^^^^^^^^^^^^^^^^^^^^^
  File "/workspace/src/backend/llm/base.py", line 53, in structured_complete
    return self.client.chat.completions.create(
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/workspace/.venv/lib/python3.11/site-packages/instructor/client.py", line 91, in create
    return self.create_fn(
           ^^^^^^^^^^^^^^^
  File "/workspace/.venv/lib/python3.11/site-packages/instructor/patch.py", line 143, in new_create_sync
    response = retry_sync(
               ^^^^^^^^^^^
  File "/workspace/.venv/lib/python3.11/site-packages/instructor/retry.py", line 152, in retry_sync
    for attempt in max_retries:
  File "/workspace/.venv/lib/python3.11/site-packages/tenacity/__init__.py", line 435, in __iter__
    do = self.iter(retry_state=retry_state)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/workspace/.venv/lib/python3.11/site-packages/tenacity/__init__.py", line 368, in iter
    result = action(retry_state)
             ^^^^^^^^^^^^^^^^^^^
  File "/workspace/.venv/lib/python3.11/site-packages/tenacity/__init__.py", line 410, in exc_check
    raise retry_exc.reraise()
          ^^^^^^^^^^^^^^^^^^^
  File "/workspace/.venv/lib/python3.11/site-packages/tenacity/__init__.py", line 183, in reraise
    raise self.last_attempt.result()
          ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/concurrent/futures/_base.py", line 449, in result
    return self.__get_result()
           ^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/concurrent/futures/_base.py", line 401, in __get_result
    raise self._exception
  File "/workspace/.venv/lib/python3.11/site-packages/instructor/retry.py", line 155, in retry_sync
    response = func(*args, **kwargs)
               ^^^^^^^^^^^^^^^^^^^^^
  File "/workspace/.venv/lib/python3.11/site-packages/litellm/utils.py", line 3473, in wrapper
    raise e
  File "/workspace/.venv/lib/python3.11/site-packages/litellm/utils.py", line 3364, in wrapper
    result = original_function(*args, **kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/workspace/.venv/lib/python3.11/site-packages/litellm/main.py", line 2519, in completion
    raise exception_type(
          ^^^^^^^^^^^^^^^
  File "/workspace/.venv/lib/python3.11/site-packages/litellm/utils.py", line 9990, in exception_type
    raise e
  File "/workspace/.venv/lib/python3.11/site-packages/litellm/utils.py", line 9965, in exception_type
    raise APIConnectionError(
litellm.exceptions.APIConnectionError: 'name'
all values are hidden
During handling of the above exception, another exception occurred:
all values are hidden
Traceback (most recent call last):
  File "/workspace/src/backend/main.py", line 111, in generator
    async for obj in stream_fn(request=chat_request, session=session):
  File "/workspace/src/backend/agent_search.py", line 317, in stream_pro_search_qa
    raise HTTPException(status_code=500, detail=detail)
fastapi.exceptions.HTTPException: 500: 'name'

image

image

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