Skip to content

Commit 372a9e9

Browse files
🌿 Fern Regeneration -- March 20, 2024 (#414)
* SDK regeneration * Update docs for 5.0.0 --------- Co-authored-by: fern-api <115122769+fern-api[bot]@users.noreply.github.com> Co-authored-by: Billy Trend <[email protected]>
1 parent 37a2746 commit 372a9e9

File tree

5 files changed

+13
-21
lines changed

5 files changed

+13
-21
lines changed

4.0.0-5.0.0-migration-guide.md

Lines changed: 3 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
## `cohere==4` to `cohere==5` migration guide
22

3-
As we migrate from the handwritten manually-maintained sdk to our auto-generated sdk, there are some breaking changes that must be accomodated during migration. These should mostly improve the developer experience but thank you for bearing with us as we make these changes.
3+
As we migrate from the handwritten manually-maintained sdk to our auto-generated sdk, there are some breaking changes that must be accommodated during migration. These should mostly improve the developer experience but thank you for bearing with us as we make these changes.
44

55
### Installation
66

@@ -30,29 +30,21 @@ for event in stream:
3030

3131
The following lists name the functions that are not in the new SDK and what their ongoing support status is.
3232

33-
#### Not yet supported
34-
35-
* loglikelihood
36-
* wait_for_dataset
37-
* wait_for_embed_job
38-
3933
#### No longer supported
4034

35+
* check_api_key
36+
* loglikelihood
4137
* batch_generate
4238
* codebook
4339
* batch_tokenize
4440
* batch_detokenize
45-
* check_api_key
4641
* detect_language
4742
* generate_feedback
4843
* generate_preference_feedback
4944
* create_cluster_job
5045
* get_cluster_job
5146
* list_cluster_jobs
5247
* wait_for_cluster_job
53-
54-
#### Status unknown
55-
5648
* create_custom_model
5749
* wait_for_custom_model
5850
* get_custom_model

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,13 @@
88

99
The Cohere Python SDK provides access to the Cohere API from Python.
1010

11-
<!--- ## ✨🪩✨ Announcing Cohere's new Python SDK ✨🪩✨
11+
## ✨🪩✨ Announcing Cohere's new Python SDK ✨🪩✨
1212

13-
We are very excited to publish this brand new Python SDK. We will continuously update this library with all of the latest features in our API. Please create issues where you have feedback so that we can continue to improve the developer experience! --->
13+
We are very excited to publish this brand-new Python SDK. We will continuously update this library with all the latest features in our API. Please create issues where you have feedback so that we can continue to improve the developer experience!
1414

15-
## 5.0.0 alpha 🚀
15+
## cohere==5.0.0 Migration Guide
1616

17-
We will release our brand new cohere-python SDK on the 18th of March 2024! If you'd like to get a head start by installing the alpha version, please go ahead and use pip install --pre --upgrade cohere. Thanks for your patience as we make breaking changes where necessary. If you have any issues using it, we will respond to github issues as soon as possible.
17+
We have created a [migration guide](4.0.0-5.0.0-migration-guide.md) to help you through the process. If you have any questions, please feel free to open an issue and we will respond to you asap.
1818

1919
## Documentation
2020

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[tool.poetry]
22
name = "cohere"
3-
version = "5.0.0a12"
3+
version = "5.0.0"
44
description = ""
55
readme = "README.md"
66
authors = []

src/cohere/client.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ def __init__(
9999
list_datasets: Never = moved_function("list_datasets", ".datasets.list")
100100
delete_dataset: Never = moved_function("delete_dataset", ".datasets.delete")
101101
get_dataset_usage: Never = moved_function("get_dataset_usage", ".datasets.get_usage")
102-
wait_for_dataset: Never = deprecated_function("wait_for_dataset")
102+
wait_for_dataset: Never = moved_function("wait_for_dataset", ".wait")
103103
_check_response: Never = deprecated_function("_check_response")
104104
_request: Never = deprecated_function("_request")
105105
create_cluster_job: Never = deprecated_function("create_cluster_job")
@@ -110,7 +110,7 @@ def __init__(
110110
list_embed_jobs: Never = moved_function("list_embed_jobs", ".embed_jobs.list")
111111
get_embed_job: Never = moved_function("get_embed_job", ".embed_jobs.get")
112112
cancel_embed_job: Never = moved_function("cancel_embed_job", ".embed_jobs.cancel")
113-
wait_for_embed_job: Never = deprecated_function("wait_for_embed_job")
113+
wait_for_embed_job: Never = moved_function("wait_for_embed_job", ".wait")
114114
create_custom_model: Never = deprecated_function("create_custom_model")
115115
wait_for_custom_model: Never = deprecated_function("wait_for_custom_model")
116116
_upload_dataset: Never = deprecated_function("_upload_dataset")
@@ -170,7 +170,7 @@ def __init__(
170170
list_datasets: Never = moved_function("list_datasets", ".datasets.list")
171171
delete_dataset: Never = moved_function("delete_dataset", ".datasets.delete")
172172
get_dataset_usage: Never = moved_function("get_dataset_usage", ".datasets.get_usage")
173-
wait_for_dataset: Never = deprecated_function("wait_for_dataset")
173+
wait_for_dataset: Never = moved_function("wait_for_dataset", ".wait")
174174
_check_response: Never = deprecated_function("_check_response")
175175
_request: Never = deprecated_function("_request")
176176
create_cluster_job: Never = deprecated_function("create_cluster_job")
@@ -181,7 +181,7 @@ def __init__(
181181
list_embed_jobs: Never = moved_function("list_embed_jobs", ".embed_jobs.list")
182182
get_embed_job: Never = moved_function("get_embed_job", ".embed_jobs.get")
183183
cancel_embed_job: Never = moved_function("cancel_embed_job", ".embed_jobs.cancel")
184-
wait_for_embed_job: Never = deprecated_function("wait_for_embed_job")
184+
wait_for_embed_job: Never = moved_function("wait_for_embed_job", ".wait")
185185
create_custom_model: Never = deprecated_function("create_custom_model")
186186
wait_for_custom_model: Never = deprecated_function("wait_for_custom_model")
187187
_upload_dataset: Never = deprecated_function("_upload_dataset")

src/cohere/core/client_wrapper.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ def get_headers(self) -> typing.Dict[str, str]:
2323
headers: typing.Dict[str, str] = {
2424
"X-Fern-Language": "Python",
2525
"X-Fern-SDK-Name": "cohere",
26-
"X-Fern-SDK-Version": "5.0.0a12",
26+
"X-Fern-SDK-Version": "5.0.0",
2727
}
2828
if self._client_name is not None:
2929
headers["X-Client-Name"] = self._client_name

0 commit comments

Comments
 (0)