| import g4f |
| import gradio as gr |
| import nest_asyncio |
| nest_asyncio.apply() |
|
|
|
|
| |
|
|
|
|
| import g4f |
|
|
| g4f.debug.logging = True |
| g4f.check_version = False |
| print(g4f.version) |
| print(g4f.Provider.Ails.params) |
|
|
|
|
|
|
|
|
| def rr(i): |
|
|
| response = g4f.ChatCompletion.create( |
| model=g4f.models.gpt_35_turbo_16k, |
| messages=[{"role": "user", "content": i}], |
| ) |
| |
|
|
| |
| return response |
|
|
| iface = gr.Interface( |
| fn=rr, |
| inputs=gr.Textbox(label="Question:", lines=4), |
| outputs=gr.Textbox(label="Réponse"), |
| title="bot", |
| description="By Isa Ibn Maryam. 😂😂 Vas dormir ! Espace fermé ! ") |
| iface.launch() |