Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions .fern/metadata.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"cliVersion": "4.23.0",
"cliVersion": "4.48.0",
"generatorName": "fernapi/fern-python-sdk",
"generatorVersion": "4.63.4",
"generatorConfig": {
Expand Down Expand Up @@ -79,6 +79,6 @@
}
]
},
"originGitCommit": "7ffcb80a5edaf952524b88ad8960151e148ff39b",
"sdkVersion": "5.21.1"
"originGitCommit": "40f3fd11b9fd6b445b024a2fcf6f2e67f6181147",
"sdkVersion": "5.21.2"
}
8 changes: 4 additions & 4 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ dynamic = ["version"]

[tool.poetry]
name = "cohere"
version = "5.21.1"
version = "5.21.2"
description = ""
readme = "README.md"
authors = []
Expand Down
8 changes: 0 additions & 8 deletions reference.md
Original file line number Diff line number Diff line change
Expand Up @@ -5505,14 +5505,6 @@ client.finetuning.update_finetuned_model(
<dl>
<dd>

**status:** `typing.Optional[Status]` — Current stage in the life-cycle of the fine-tuned model.

</dd>
</dl>

<dl>
<dd>

**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.

</dd>
Expand Down
4 changes: 2 additions & 2 deletions src/cohere/core/client_wrapper.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,12 +29,12 @@ def get_headers(self) -> typing.Dict[str, str]:
import platform

headers: typing.Dict[str, str] = {
"User-Agent": "cohere/5.21.1",
"User-Agent": "cohere/5.21.2",
"X-Fern-Language": "Python",
"X-Fern-Runtime": f"python/{platform.python_version()}",
"X-Fern-Platform": f"{platform.system().lower()}/{platform.release()}",
"X-Fern-SDK-Name": "cohere",
"X-Fern-SDK-Version": "5.21.1",
"X-Fern-SDK-Version": "5.21.2",
**(self.get_custom_headers() or {}),
}
if self._client_name is not None:
Expand Down
27 changes: 4 additions & 23 deletions src/cohere/finetuning/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
from .finetuning.types.list_finetuned_models_response import ListFinetunedModelsResponse
from .finetuning.types.list_training_step_metrics_response import ListTrainingStepMetricsResponse
from .finetuning.types.settings import Settings
from .finetuning.types.status import Status
from .finetuning.types.update_finetuned_model_response import UpdateFinetunedModelResponse
from .raw_client import AsyncRawFinetuningClient, RawFinetuningClient

Expand Down Expand Up @@ -202,13 +201,7 @@ def delete_finetuned_model(
return _response.data

def update_finetuned_model(
self,
id: str,
*,
name: str,
settings: Settings,
status: typing.Optional[Status] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
self, id: str, *, name: str, settings: Settings, request_options: typing.Optional[RequestOptions] = None
) -> UpdateFinetunedModelResponse:
"""
Updates the fine-tuned model with the given ID. The model will be updated with the new settings and name provided in the request body.
Expand All @@ -224,9 +217,6 @@ def update_finetuned_model(
settings : Settings
FinetunedModel settings such as dataset, hyperparameters...

status : typing.Optional[Status]
Current stage in the life-cycle of the fine-tuned model.

request_options : typing.Optional[RequestOptions]
Request-specific configuration.

Expand Down Expand Up @@ -256,7 +246,7 @@ def update_finetuned_model(
)
"""
_response = self._raw_client.update_finetuned_model(
id, name=name, settings=settings, status=status, request_options=request_options
id, name=name, settings=settings, request_options=request_options
)
return _response.data

Expand Down Expand Up @@ -593,13 +583,7 @@ async def main() -> None:
return _response.data

async def update_finetuned_model(
self,
id: str,
*,
name: str,
settings: Settings,
status: typing.Optional[Status] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
self, id: str, *, name: str, settings: Settings, request_options: typing.Optional[RequestOptions] = None
) -> UpdateFinetunedModelResponse:
"""
Updates the fine-tuned model with the given ID. The model will be updated with the new settings and name provided in the request body.
Expand All @@ -615,9 +599,6 @@ async def update_finetuned_model(
settings : Settings
FinetunedModel settings such as dataset, hyperparameters...

status : typing.Optional[Status]
Current stage in the life-cycle of the fine-tuned model.

request_options : typing.Optional[RequestOptions]
Request-specific configuration.

Expand Down Expand Up @@ -655,7 +636,7 @@ async def main() -> None:
asyncio.run(main())
"""
_response = await self._raw_client.update_finetuned_model(
id, name=name, settings=settings, status=status, request_options=request_options
id, name=name, settings=settings, request_options=request_options
)
return _response.data

Expand Down
25 changes: 2 additions & 23 deletions src/cohere/finetuning/raw_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@
from .finetuning.types.list_finetuned_models_response import ListFinetunedModelsResponse
from .finetuning.types.list_training_step_metrics_response import ListTrainingStepMetricsResponse
from .finetuning.types.settings import Settings
from .finetuning.types.status import Status
from .finetuning.types.update_finetuned_model_response import UpdateFinetunedModelResponse
from pydantic import ValidationError

Expand Down Expand Up @@ -501,13 +500,7 @@ def delete_finetuned_model(
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)

def update_finetuned_model(
self,
id: str,
*,
name: str,
settings: Settings,
status: typing.Optional[Status] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
self, id: str, *, name: str, settings: Settings, request_options: typing.Optional[RequestOptions] = None
) -> HttpResponse[UpdateFinetunedModelResponse]:
"""
Updates the fine-tuned model with the given ID. The model will be updated with the new settings and name provided in the request body.
Expand All @@ -523,9 +516,6 @@ def update_finetuned_model(
settings : Settings
FinetunedModel settings such as dataset, hyperparameters...

status : typing.Optional[Status]
Current stage in the life-cycle of the fine-tuned model.

request_options : typing.Optional[RequestOptions]
Request-specific configuration.

Expand All @@ -542,7 +532,6 @@ def update_finetuned_model(
"settings": convert_and_respect_annotation_metadata(
object_=settings, annotation=Settings, direction="write"
),
"status": status,
},
headers={
"content-type": "application/json",
Expand Down Expand Up @@ -1368,13 +1357,7 @@ async def delete_finetuned_model(
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)

async def update_finetuned_model(
self,
id: str,
*,
name: str,
settings: Settings,
status: typing.Optional[Status] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
self, id: str, *, name: str, settings: Settings, request_options: typing.Optional[RequestOptions] = None
) -> AsyncHttpResponse[UpdateFinetunedModelResponse]:
"""
Updates the fine-tuned model with the given ID. The model will be updated with the new settings and name provided in the request body.
Expand All @@ -1390,9 +1373,6 @@ async def update_finetuned_model(
settings : Settings
FinetunedModel settings such as dataset, hyperparameters...

status : typing.Optional[Status]
Current stage in the life-cycle of the fine-tuned model.

request_options : typing.Optional[RequestOptions]
Request-specific configuration.

Expand All @@ -1409,7 +1389,6 @@ async def update_finetuned_model(
"settings": convert_and_respect_annotation_metadata(
object_=settings, annotation=Settings, direction="write"
),
"status": status,
},
headers={
"content-type": "application/json",
Expand Down
Loading