mirror of
https://github.com/hwchase17/langchain
synced 2024-11-06 03:20:49 +00:00
Update SageMaker Endpoint Embeddings docs to be up to date with current requirements (#8103)
- **Description:** Simple change of the Class that ContentHandler inherits from. To create an object of type SagemakerEndpointEmbeddings, the property content_handler must be of type EmbeddingsContentHandler not ContentHandlerBase anymore, - **Twitter handle:** @Juanjo_Torres11 Co-authored-by: Bagatur <baskaryan@gmail.com>
This commit is contained in:
parent
7cbe28ba9b
commit
1cc7d4c9eb
@ -39,11 +39,11 @@
|
|||||||
"source": [
|
"source": [
|
||||||
"from typing import Dict, List\n",
|
"from typing import Dict, List\n",
|
||||||
"from langchain.embeddings import SagemakerEndpointEmbeddings\n",
|
"from langchain.embeddings import SagemakerEndpointEmbeddings\n",
|
||||||
"from langchain.llms.sagemaker_endpoint import ContentHandlerBase\n",
|
"from langchain.embeddings.sagemaker_endpoint import EmbeddingsContentHandler\n",
|
||||||
"import json\n",
|
"import json\n",
|
||||||
"\n",
|
"\n",
|
||||||
"\n",
|
"\n",
|
||||||
"class ContentHandler(ContentHandlerBase):\n",
|
"class ContentHandler(EmbeddingsContentHandler):\n",
|
||||||
" content_type = \"application/json\"\n",
|
" content_type = \"application/json\"\n",
|
||||||
" accepts = \"application/json\"\n",
|
" accepts = \"application/json\"\n",
|
||||||
"\n",
|
"\n",
|
||||||
|
Loading…
Reference in New Issue
Block a user