googleapis / googleapis/python-aiplatform

vertexai.preview.rag.retrieval_query() raises error

Abierto
#5,006 1 comentario 0 reacciones 0 asignados Ver en GitHub
api: vertex-ai
Lenguaje dominante
Python
Estrellas
905
Forks
465
Merge medio
1 d 13 h
PR fusionados (30 d)
44

Descripción

Hello,

I'm encountering an issue with my Vertex AI RAG retrieval query. It was functioning correctly previously, but now I'm receiving an "InternalServerError: 500 Failed to search for project xxxx" error.

```
Traceback (most recent call last):
File "/home/user/.pyenv/versions/gemini/lib/python3.12/site-packages/google/api_core/grpc_helpers.py", line 76, in error_remapped_callable
return callable_(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/user/.pyenv/versions/gemini/lib/python3.12/site-packages/grpc/_channel.py", line 1181, in __call__
return _end_unary_response_blocking(state, call, False, None)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/user/.pyenv/versions/gemini/lib/python3.12/site-packages/grpc/_channel.py", line 1006, in _end_unary_response_blocking
raise _InactiveRpcError(state) # pytype: disable=not-instantiable
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
grpc._channel._InactiveRpcError: <_InactiveRpcError of RPC that terminated with:
status = StatusCode.INTERNAL
details = "Failed to search for project xxxx"
debug_error_string = "UNKNOWN:Error received from peer ipv6:%5B2a00:1450:400e:805::200a%5D:443 {created_time:"2025-03-04T15:22:45.964149653+01:00", grpc_status:13, grpc_message:"Failed to search for project xxxx"}"
>

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

Traceback (most recent call last):
File "/home/user/.pyenv/versions/gemini/lib/python3.12/site-packages/vertexai/preview/rag/rag_retrieval.py", line 133, in retrieval_query
response = client.retrieve_contexts(request=request)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/user/.pyenv/versions/gemini/lib/python3.12/site-packages/google/cloud/aiplatform_v1beta1/services/vertex_rag_service/client.py", line 833, in retrieve_contexts
response = rpc(
^^^^
File "/home/user/.pyenv/versions/gemini/lib/python3.12/site-packages/google/api_core/gapic_v1/method.py", line 131, in __call__
return wrapped_func(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/user/.pyenv/versions/gemini/lib/python3.12/site-packages/google/api_core/grpc_helpers.py", line 78, in error_remapped_callable
raise exceptions.from_grpc_error(exc) from exc
google.api_core.exceptions.InternalServerError: 500 Failed to search for project xxxx

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

Traceback (most recent call last):
File "/home/user/gitlab/datascience-chatbot/vertex/gemini_only_query.py", line 11, in
response = rag.retrieval_query(
^^^^^^^^^^^^^^^^^^^^
File "/home/user/.pyenv/versions/gemini/lib/python3.12/site-packages/vertexai/preview/rag/rag_retrieval.py", line 135, in retrieval_query
raise RuntimeError("Failed in retrieving contexts due to: ", e) from e
RuntimeError: ('Failed in retrieving contexts due to: ', InternalServerError('Failed to search for project xxxx'))
```

I have not made any changes to the code, RAG configuration, or IAM permissions.

Could you please provide guidance on troubleshooting this error? I need to identify the root cause of the retrieval failure.

Specifically, I would like to know:

How to access detailed logs for the RAG retrieval process.
Where to check the status of my RAG corpus.
Any known recent issues with Vertex AI RAG that may be causing this.

Thank you for your assistance.

Guía de contribución

Abrir la guía de contribución

Evaluación

Este issue todavía no se ha evaluado.

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.