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

The chat is not working, but the notebook is ok #414

Closed
sanchomuzax opened this issue Oct 21, 2023 · 5 comments
Closed

The chat is not working, but the notebook is ok #414

sanchomuzax opened this issue Oct 21, 2023 · 5 comments
Labels
bug Something isn't working

Comments

@sanchomuzax
Copy link

Description

As you can see, the chat is not working for me, but the notebook is ok.
image

Reproduce

I don't know what causes the error, but I noticed that the API key specified in the chat settings menu is not visible after entering it.

Before saving:

image

After the 1st click on button:

image

After the 2nd click on button (is the menu empty?):

image

Context

  • Operating System and version: Windows 10
  • Browser and version: Edge 118.0.2088.57
  • JupyterLab version:
    IPython : 8.16.1
    ipykernel : 6.25.2
    ipywidgets : 8.1.1
    jupyter_client : 8.4.0
    jupyter_core : 5.4.0
    jupyter_server : 2.8.0
    jupyterlab : 4.0.7
    nbclient : 0.8.0
    nbconvert : 7.9.2
    nbformat : 5.9.2
    notebook : 7.0.6
    qtconsole : 5.4.4
    traitlets : 5.11.2
  • Language model:
    image
@sanchomuzax sanchomuzax added the bug Something isn't working label Oct 21, 2023
@welcome
Copy link

welcome bot commented Oct 21, 2023

Thank you for opening your first issue in this project! Engagement like this is essential for open source projects! 🤗

If you haven't done so already, check out Jupyter's Code of Conduct. Also, please try to follow the issue template as it helps other other community members to contribute more effectively.
welcome
You can meet the other Jovyans by joining our Discourse forum. There is also an intro thread there where you can stop by and say Hi! 👋

Welcome to the Jupyter community! 🎉

@krassowski
Copy link
Member

I suspect that the full error message traceback could be helpful to maintainers, can you scroll down in the chat window, copy it and paste here?

@sanchomuzax
Copy link
Author

Traceback (most recent call last):
File "C:\Users\attila.virag\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.11_qbz5n2kfra8p0\LocalCache\local-packages\Python311\site-packages\jupyter_ai\chat_handlers\base.py", line 39, in process_message
await self._process_message(message)
File "C:\Users\attila.virag\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.11_qbz5n2kfra8p0\LocalCache\local-packages\Python311\site-packages\jupyter_ai\chat_handlers\default.py", line 87, in _process_message
response = await self.llm_chain.apredict(input=message.body, stop=["\nHuman:"])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\attila.virag\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.11_qbz5n2kfra8p0\LocalCache\local-packages\Python311\site-packages\langchain\chains\llm.py", line 274, in apredict
return (await self.acall(kwargs, callbacks=callbacks))[self.output_key]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\attila.virag\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.11_qbz5n2kfra8p0\LocalCache\local-packages\Python311\site-packages\langchain\chains\base.py", line 375, in acall
raise e
File "C:\Users\attila.virag\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.11_qbz5n2kfra8p0\LocalCache\local-packages\Python311\site-packages\langchain\chains\base.py", line 369, in acall
await self._acall(inputs, run_manager=run_manager)
File "C:\Users\attila.virag\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.11_qbz5n2kfra8p0\LocalCache\local-packages\Python311\site-packages\langchain\chains\llm.py", line 239, in _acall
response = await self.agenerate([inputs], run_manager=run_manager)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\attila.virag\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.11_qbz5n2kfra8p0\LocalCache\local-packages\Python311\site-packages\langchain\chains\llm.py", line 117, in agenerate
return await self.llm.agenerate_prompt(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\attila.virag\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.11_qbz5n2kfra8p0\LocalCache\local-packages\Python311\site-packages\langchain\chat_models\base.py", line 479, in agenerate_prompt
return await self.agenerate(
^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\attila.virag\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.11_qbz5n2kfra8p0\LocalCache\local-packages\Python311\site-packages\langchain\chat_models\base.py", line 439, in agenerate
raise exceptions[0]
File "C:\Users\attila.virag\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.11_qbz5n2kfra8p0\LocalCache\local-packages\Python311\site-packages\langchain\chat_models\base.py", line 540, in _agenerate_with_cache
return await self._agenerate(
^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\attila.virag\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.11_qbz5n2kfra8p0\LocalCache\local-packages\Python311\site-packages\langchain\chat_models\openai.py", line 420, in _agenerate
response = await acompletion_with_retry(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\attila.virag\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.11_qbz5n2kfra8p0\LocalCache\local-packages\Python311\site-packages\langchain\chat_models\openai.py", line 97, in acompletion_with_retry
return await completion_with_retry(**kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\attila.virag\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.11_qbz5n2kfra8p0\LocalCache\local-packages\Python311\site-packages\tenacity_asyncio.py", line 88, in async_wrapped
return await fn(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\attila.virag\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.11_qbz5n2kfra8p0\LocalCache\local-packages\Python311\site-packages\tenacity_asyncio.py", line 47, in call
do = self.iter(retry_state=retry_state)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\attila.virag\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.11_qbz5n2kfra8p0\LocalCache\local-packages\Python311\site-packages\tenacity_init
.py", line 314, in iter
return fut.result()
^^^^^^^^^^^^
File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.11_3.11.1776.0_x64__qbz5n2kfra8p0\Lib\concurrent\futures_base.py", line 449, in result
return self.__get_result()
^^^^^^^^^^^^^^^^^^^
File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.11_3.11.1776.0_x64__qbz5n2kfra8p0\Lib\concurrent\futures_base.py", line 401, in __get_result
raise self._exception
File "C:\Users\attila.virag\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.11_qbz5n2kfra8p0\LocalCache\local-packages\Python311\site-packages\tenacity_asyncio.py", line 50, in call
result = await fn(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\attila.virag\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.11_qbz5n2kfra8p0\LocalCache\local-packages\Python311\site-packages\langchain\chat_models\openai.py", line 95, in _completion_with_retry
return await llm.client.acreate(**kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\attila.virag\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.11_qbz5n2kfra8p0\LocalCache\local-packages\Python311\site-packages\openai\api_resources\chat_completion.py", line 45, in acreate
return await super().acreate(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\attila.virag\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.11_qbz5n2kfra8p0\LocalCache\local-packages\Python311\site-packages\openai\api_resources\abstract\engine_api_resource.py", line 219, in acreate
response, _, api_key = await requestor.arequest(
^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\attila.virag\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.11_qbz5n2kfra8p0\LocalCache\local-packages\Python311\site-packages\openai\api_requestor.py", line 384, in arequest
resp, got_stream = await self._interpret_async_response(result, stream)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\attila.virag\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.11_qbz5n2kfra8p0\LocalCache\local-packages\Python311\site-packages\openai\api_requestor.py", line 738, in _interpret_async_response
self._interpret_response_line(
File "C:\Users\attila.virag\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.11_qbz5n2kfra8p0\LocalCache\local-packages\Python311\site-packages\openai\api_requestor.py", line 775, in _interpret_response_line
raise self.handle_error_response(
openai.error.AuthenticationError: No such organization: XXXXXX..

@3coins
Copy link
Collaborator

3coins commented Oct 21, 2023

@sanchomuzax
This error seems to be pointing to the organization that you have entered in the Chat Settings Panel. Can you double-check that it is a correct value or try removing it.

@sanchomuzax
Copy link
Author

Thank you very much! Your answer is the solution. I deleted the cell value, now the chat is working.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants