Quota exceeded no matter what the quota is in langchain notebook example
When attempting to run https://github.com/GoogleCloudPlatform/generative-ai/blob/main/language/use-cases/document-qa/question_answering_documents_langchain.ipynb in cell 18
doc_ids = me.add_texts(texts=texts, metadatas=metadatas)
I get a
ResourceExhausted: 429 Quota exceeded for aiplatform.googleapis.com/online_prediction_requests_per_base_model with base model: textembedding-gecko. Please submit a quota increase request. https://cloud.google.com/vertex-ai/docs/quotas.
My quota is not exceeded however (and I increased it) when checking the quota dashboard in GCP.
I attempted to limit the scope using
doc_ids = me.add_texts(texts=texts[0], metadatas=metadatas[0])
and receive the same error.
This is just a quick hack so I could get the notebook to work:
def add_docs_to_index(start, end):
doc_ids = me.add_texts(texts=texts[start:end], metadatas=metadatas[start:end])
return end
loaded = 50
document_count = len(texts)
increment = 50
while loaded + increment <= document_count:
start = loaded + 1
end = start + increment
indexed = add_docs_to_index(start, end)
print('indexed = ', indexed)
loaded += increment
remaining = document_count - loaded
add_docs_to_index(loaded +1, remaining)
Was also getting a key error for document _name in the metadatas list of dicts. Looking at the metadata there was only source and chunk
@inardini Can you take a look at this?