community[patch]: Fixed 'coroutine' object is not subscriptable error (#15986)

- **Description:** Added parenthesis in return statement of
aembed_query() funtion to fix 'coroutine' object is not subscriptable
error.
  - **Dependencies:** NA

Co-authored-by: H161961 <Raunak.Raunak@Honeywell.com>
This commit is contained in:
Raunak 2024-01-16 00:04:10 +05:30 committed by GitHub
parent 14244bd7e5
commit c0773ab329
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -144,5 +144,5 @@ class HuggingFaceHubEmbeddings(BaseModel, Embeddings):
Returns:
Embeddings for the text.
"""
response = await self.aembed_documents([text])[0]
response = (await self.aembed_documents([text]))[0]
return response