gpt4free icon indicating copy to clipboard operation
gpt4free copied to clipboard

All providers failed

Open mytricker0 opened this issue 2 years ago • 3 comments

I get this error

    raise RuntimeError("\n".join(["All providers failed:"] + [
RuntimeError: All providers failed:
Ylokh: CurlError: Failed to perform, ErrCode: 28, Reason: 'Operation timed out after 30001 milliseconds with 0 bytes received'. This may be a libcurl error, See https://curl.se/libcurl/c/libcurl-errors.html first for more details.
Myshell: RuntimeError: Received unexpected message: need_verify_captcha

When i'm running this script:

import g4f

def generate(prompt):


    response = g4f.ChatCompletion.create(
        model=g4f.models.gpt_4,
        messages=[{"role": "user", "content": prompt}],
        stream=False,
    )  # alterative model setting


    return response 

mytricker0 avatar Oct 02 '23 17:10 mytricker0

Try out GPT 3.5 or "default":

    model=g4f.models.gpt_35_turbo,
    or
    model=g4f.models.default,

Free GPT 4 providers are rare

hlohaus avatar Oct 02 '23 17:10 hlohaus

use the bing provider, that works fine for me

DoxrGitHub avatar Oct 03 '23 01:10 DoxrGitHub

Bumping this issue because it has been open for 7 days with no activity. Closing automatically in 7 days unless it becomes active again.

github-actions[bot] avatar Oct 11 '23 00:10 github-actions[bot]