MIDORIBIN / langchain-gpt4free

LangChain x gpt4free
MIT License
170 stars 38 forks source link

ValidationError: 3 validation errors for G4FLLM #7

Open wileewang opened 1 year ago

wileewang commented 1 year ago

running script:

from g4f import Provider, models from langchain.llms.base import LLM from langchain_g4f import G4FLLM def main(): llm: LLM = G4FLLM( model=models.gpt_35_turbo, provider=Provider.Aichat, ) res = llm("hello") print(res) # Hello! How can I assist you today?

main()

ValidationError: 3 validation errors for G4FLLM model -> best_provider subclass of BaseProvider expected (type=type_error.subclass; expected_class=BaseProvider) model -> best_provider wrong tuple length 12, expected 1 (type=value_error.tuple.length; actual_length=12; expected_length=1) model str type expected (type=type_error.str)

MIDORIBIN commented 1 year ago

@wileewang Thanks for the report. We have confirmed that the problem you reported occurs.

However, due to the gpt4free issue, we are unable to address it from this repository. Please wait for me to submit a pull request to gpt4free. I will let you know when it is resolved.

Yusufibin commented 1 year ago

@MIDORIBIN It's always the same