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

API request return a 500 Server Error frequently #270

Open
SarahOssama opened this issue Feb 22, 2024 · 4 comments
Open

API request return a 500 Server Error frequently #270

SarahOssama opened this issue Feb 22, 2024 · 4 comments

Comments

@SarahOssama
Copy link

this is what i get and i checked and made sure that my key is in the env variables

Traceback (most recent call last):
File "C:\Users\sosman\AppData\Local\Programs\Python\Python311\Lib\site-packages\spacy_llm\models\rest\palm\model.py", line 64, in _request
r.raise_for_status()
File "C:\Users\sosman\AppData\Local\Programs\Python\Python311\Lib\site-packages\requests\models.py", line 1021, in raise_for_status
raise HTTPError(http_error_msg, response=self)
requests.exceptions.HTTPError: 500 Server Error: Internal Server Error for url: https://generativelanguage.googleapis.com/v1beta3/models/text-bison-001:generateText?key=AIzaSyB2CE2CyMvaa_LPbboyk09rZgTEkmoZoTk

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File "e:\Projects\IV&VTesting\Attempts\Variable Classification\NERSpacy\demo.py", line 41, in
NER()
File "e:\Projects\IV&VTesting\Attempts\Variable Classification\NERSpacy\demo.py", line 31, in NER
doc = nlp(text)
^^^^^^^^^
File "C:\Users\sosman\AppData\Local\Programs\Python\Python311\Lib\site-packages\spacy\language.py", line 1054, in call
error_handler(name, proc, [doc], e)
File "C:\Users\sosman\AppData\Local\Programs\Python\Python311\Lib\site-packages\spacy\util.py", line 1704, in raise_error
raise e
File "C:\Users\sosman\AppData\Local\Programs\Python\Python311\Lib\site-packages\spacy\language.py", line 1049, in call
doc = proc(doc, **component_cfg.get(name, {})) # type: ignore[call-arg]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\sosman\AppData\Local\Programs\Python\Python311\Lib\site-packages\spacy_llm\pipeline\llm.py", line 161, in call
docs = self._process_docs([doc])
^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\sosman\AppData\Local\Programs\Python\Python311\Lib\site-packages\spacy_llm\pipeline\llm.py", line 215, in _process_docs
responses_iters = tee(self._model(prompts_iters[0]), n_iters)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\sosman\AppData\Local\Programs\Python\Python311\Lib\site-packages\spacy_llm\models\rest\palm\model.py", line 87, in call
responses = [
^
File "C:\Users\sosman\AppData\Local\Programs\Python\Python311\Lib\site-packages\spacy_llm\models\rest\palm\model.py", line 88, in
_request(
File "C:\Users\sosman\AppData\Local\Programs\Python\Python311\Lib\site-packages\spacy_llm\models\rest\palm\model.py", line 70, in _request
raise ValueError(f"Request to PaLM API failed: {error_message}") from ex
ValueError: Request to PaLM API failed: An internal error has occurred. Please retry or report in https://developers.generativeai.google/guide/troubleshooting

@ShayKaiserman
Copy link

It happened to me too right now. I used the API before and it was never a problem..

@SarahOssama
Copy link
Author

Yes it works a min and then goes down again

@jun0wanan
Copy link

Yes it works a min and then goes down again

I also have this problem ....

Who can help us ?

@Halhawasi
Copy link

I also have this problem

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

4 participants