Files
langchain/langchain
Sasmitha Manathunga 5c97f70bf1 Fix CohereError: embed is not an available endpoint on this model (#637)
Running the Cohere embeddings example from the docs:

```python
from langchain.embeddings import CohereEmbeddings
embeddings = CohereEmbeddings(cohere_api_key= cohere_api_key)

text = "This is a test document."
query_result = embeddings.embed_query(text)
doc_result = embeddings.embed_documents([text])
```

I get the error:

```bash
CohereError(message=res['message'], http_status=response.status_code, headers=response.headers)      
cohere.error.CohereError: embed is not an available endpoint on this model
```

This is because the `model` string is set to `medium` which is not
currently available.

From the Cohere docs:

> Currently available models are small and large (default)
2023-01-17 22:26:07 -08:00
..
2023-01-15 16:45:16 -08:00
2023-01-14 08:09:25 -08:00
2023-01-06 07:58:38 -08:00
2023-01-15 17:07:21 -08:00
2023-01-11 05:52:19 -08:00
2022-10-24 14:51:15 -07:00
2022-11-12 11:22:32 -08:00
2022-12-18 21:51:23 -05:00
2022-12-06 21:55:02 -08:00
2023-01-15 17:07:21 -08:00
2022-11-14 22:05:41 -08:00