Skip to content
This repository has been archived by the owner on Feb 3, 2025. It is now read-only.

[BUG] Followed the docs, does not work as expected, used both anthropic API and openAI API key #110

Open
eff-kay opened this issue Jan 21, 2025 · 0 comments

Comments

@eff-kay
Copy link

eff-kay commented Jan 21, 2025

Describe the bug
A clear and concise description of what the bug is.

To Reproduce
Steps to reproduce the behavior:

  1. did pip install
  2. ran sage-chat hugging-face/transformers
  3. gradio runs, but upon first questions. returns an error.

I asusmed this is because indexing is not done

performed index, still not working.

Expected behavior
Chat to work

Screenshots
If applicable, add screenshots to help explain your problem.

Setup (please complete the following information):

  • Python version: 3.11
  • OS: 13.66

LOGS

  File "/Users/faizank/workspace/experiments/sage/venv/lib/python3.11/site-packages/gradio/utils.py", line 691, in async_iteration
    return await anext(iterator)
           ^^^^^^^^^^^^^^^^^^^^^
  File "/Users/faizank/workspace/experiments/sage/sage/chat.py", line 105, in _predict
    sources = [(doc.metadata["file_path"], doc.metadata["url"]) for doc in event["data"]["output"]]
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: 'NoneType' object is not iterable
ERROR:asyncio:Task exception was never retrieved
future: <Task finished name='Task-174' coro=<<async_generator_athrow without __name__>()> exception=BadRequestError("Error code: 400 - {'type': 'error', 'error': {'type': 'invalid_request_error', 'message': 'system.0: Input does not match the expected shape.'}}")>
Traceback (most recent call last):
@eff-kay eff-kay changed the title [BUG] Followed the docs, does not work as expected, used anthropic API. [BUG] Followed the docs, does not work as expected, used both anthropic API and openAI API key Jan 21, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant