Skip to content
This repository was archived by the owner on May 13, 2026. It is now read-only.
This repository was archived by the owner on May 13, 2026. It is now read-only.

Unable to use the chat function #79

@UnlimitedCookies

Description

@UnlimitedCookies

We have no idea what the issue is here.

Error chatting
2 validation errors for LLMChain
llm
  instance of Runnable expected (type=type_error.arbitrary_type; expected_arbitrary_type=Runnable)
llm
  instance of Runnable expected (type=type_error.arbitrary_type; expected_arbitrary_type=Runnable)
ERROR:root:2 validation errors for LLMChain
llm
  instance of Runnable expected (type=type_error.arbitrary_type; expected_arbitrary_type=Runnable)
llm
  instance of Runnable expected (type=type_error.arbitrary_type; expected_arbitrary_type=Runnable)
Traceback (most recent call last):
  File "/home/user/Git/langchain-chatbot/handlers/base.py", line 187, in chat
    bot = ConversationalRetrievalChain.from_llm(
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/user/.cache/pypoetry/virtualenvs/langchain-chatbot-mUNeNTez-py3.11/lib/python3.11/site-packages/langchain/chains/conversational_retrieval/base.py", line 372, in from_llm
    doc_chain = load_qa_chain(
                ^^^^^^^^^^^^^^
  File "/home/user/.cache/pypoetry/virtualenvs/langchain-chatbot-mUNeNTez-py3.11/lib/python3.11/site-packages/langchain/chains/question_answering/__init__.py", line 249, in load_qa_chain
    return loader_mapping[chain_type](
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/user/.cache/pypoetry/virtualenvs/langchain-chatbot-mUNeNTez-py3.11/lib/python3.11/site-packages/langchain/chains/question_answering/__init__.py", line 73, in _load_stuff_chain
    llm_chain = LLMChain(
                ^^^^^^^^^
  File "/home/user/.cache/pypoetry/virtualenvs/langchain-chatbot-mUNeNTez-py3.11/lib/python3.11/site-packages/langchain_core/load/serializable.py", line 120, in __init__
    super().__init__(**kwargs)
  File "/home/user/.cache/pypoetry/virtualenvs/langchain-chatbot-mUNeNTez-py3.11/lib/python3.11/site-packages/pydantic/v1/main.py", line 341, in __init__
    raise validation_error
pydantic.v1.error_wrappers.ValidationError: 2 validation errors for LLMChain
llm
  instance of Runnable expected (type=type_error.arbitrary_type; expected_arbitrary_type=Runnable)
llm
  instance of Runnable expected (type=type_error.arbitrary_type; expected_arbitrary_type=Runnable)
INFO: 127.0.0.1:49988 - "POST /chat HTTP/1.1" 500 Internal Server Error

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions