Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to start simple text chat without Twilio credentials #3

Open
Leopaexd opened this issue Feb 7, 2025 · 1 comment
Open

Unable to start simple text chat without Twilio credentials #3

Leopaexd opened this issue Feb 7, 2025 · 1 comment

Comments

@Leopaexd
Copy link

Leopaexd commented Feb 7, 2025

Trying to start simple text chat with:

import gradio as gr
import openai_gradio

gr.load("gpt-4o-mini", src=openai_gradio.registry).launch()

But got the following error:

Traceback (most recent call last):
  File "A:\AI\tools\FastAPIProject\GradioAssistant\app.py", line 5, in <module>
    gr.load("gpt-4o-mini", src=openai_gradio.registry).launch()
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "A:\AI\tools\FastAPIProject\GradioAssistant\.venv\Lib\site-packages\gradio\external.py", line 91, in load
    return src(name, token, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "A:\AI\tools\FastAPIProject\GradioAssistant\.venv\Lib\site-packages\openai_gradio\__init__.py", line 187, in registry
    rtc_configuration=get_twilio_turn_credentials(twilio_sid, twilio_token),
                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "A:\AI\tools\FastAPIProject\GradioAssistant\.venv\Lib\site-packages\gradio_webrtc\credentials.py", line 38, in get_twilio_turn_credentials
    token = client.tokens.create()
            ^^^^^^^^^^^^^^^^^^^^^^
  File "A:\AI\tools\FastAPIProject\GradioAssistant\.venv\Lib\site-packages\twilio\rest\api\v2010\account\token.py", line 102, in create
    payload = self._version.create(
              ^^^^^^^^^^^^^^^^^^^^^
  File "A:\AI\tools\FastAPIProject\GradioAssistant\.venv\Lib\site-packages\twilio\base\version.py", line 463, in create
    return self._parse_create(method, uri, response)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "A:\AI\tools\FastAPIProject\GradioAssistant\.venv\Lib\site-packages\twilio\base\version.py", line 435, in _parse_create
    raise self.exception(method, uri, response, "Unable to create record")
twilio.base.exceptions.TwilioRestException: HTTP 401 error: Unable to create record: Authentication Error - No credentials provided 

Expected Behavior:
The text chat should launch without requiring Twilio credentials.

Environment:
Python 3.11.3
openai-gradio version: 0.0.6
twilio version: 9.4.4 (installed as requirement for openai-gradio)
gradio_webrtc version: 0.0.30

@Shamik-07
Copy link

I don't see any contributors and i don't think this repo is actively maintained.
Your best bet is to just create one yourself by looking at https://www.gradio.app/guides/creating-a-chatbot-fast

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants