{"id":27774,"library":"g4fu","title":"g4fu","description":"Fork of the gpt4free repository providing a collection of powerful language models for educational purposes only. Current version 10.3.2.4, with rapid releases and occasional yanked versions.","status":"active","version":"10.3.2.4","language":"python","source_language":"en","source_url":"https://github.com/XInTheDark/gpt4free-u","tags":["gpt4free","language-models","fork","educational"],"install":[{"cmd":"pip install g4fu","lang":"bash","label":"PyPi"}],"dependencies":[],"imports":[{"note":"importing g4fu directly does not expose Client","wrong":"import g4fu","symbol":"Client","correct":"from g4fu import Client"},{"note":"g4fu.Completion is not a valid attribute; use from g4fu import Completion","wrong":"import g4fu.Completion","symbol":"Completion","correct":"from g4fu import Completion"}],"quickstart":{"code":"from g4fu import Client\n\nclient = Client(api_key=os.environ.get('G4FU_API_KEY', ''))\nresponse = client.chat.completions.create(\n    model='gpt-4',\n    messages=[{'role': 'user', 'content': 'Hello!'}]\n)\nprint(response.choices[0].message.content)","lang":"python","description":"Initialize a Client with an API key and send a chat completion request."},"warnings":[{"fix":"Use g4fu==10.3.2.4 in your requirements.","message":"The package is a fork and may have breaking changes from the original gpt4free. Always pin your version.","severity":"gotcha","affected_versions":"all"},{"fix":"Upgrade to 10.3.2.4 or later.","message":"Version 10.3.2.2 was yanked due to module loading issues. Avoid using that version.","severity":"breaking","affected_versions":"10.3.2.2"},{"fix":"Do not rely on it in production.","message":"The package is intended for educational purposes only and may be removed or changed without notice.","severity":"deprecated","affected_versions":"all"}],"env_vars":null,"last_verified":"2026-05-09T00:00:00.000Z","next_check":"2026-08-07T00:00:00.000Z","problems":[{"fix":"Update g4fu to >=10.3.2.4 and use 'from g4fu import Client'.","cause":"Outdated version or incorrect import path.","error":"ImportError: cannot import name 'Client' from 'g4fu'"},{"fix":"Install with 'pip install g4fu'.","cause":"Package not installed.","error":"ModuleNotFoundError: No module named 'g4fu'"}],"ecosystem":"pypi","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}