Delete model version
Delete a fine-tuned model for good, by its number, such as router@3: it no longer
answers or runs anything, and it no longer counts against the account’s storage. An id,
a name or an alias is refused with 422 invalid_reference. With adapter, the id the
caller saw, only while the number still names that model: 409 model_changed otherwise.
A family’s latest model is refused with 409 latest_model: roll the family back instead.
A model whose own switch is on, or that its family serves, is refused: switch it off if
it is on, and a family’s model can be deleted once the family, switched on, has moved to
its latest model. So is one an evaluation is still scoring. Its fine-tune’s history
stays. It can’t be undone, and deleting again changes nothing.
curl --request DELETE \
--url https://api.sqwish.ai/v1/models/{model_id} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.sqwish.ai/v1/models/{model_id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.delete(url, headers=headers)
print(response.text)const options = {method: 'DELETE', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.sqwish.ai/v1/models/{model_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"id": "<string>",
"deleted": true
}{
"error": {
"code": "<string>",
"message": "<string>",
"retryable": true,
"request_id": "<string>",
"details": [
{
"path": [
"<string>"
],
"message": "<string>",
"type": "<string>"
}
]
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"retryable": true,
"request_id": "<string>",
"details": [
{
"path": [
"<string>"
],
"message": "<string>",
"type": "<string>"
}
]
}
}Query Parameters
curl --request DELETE \
--url https://api.sqwish.ai/v1/models/{model_id} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.sqwish.ai/v1/models/{model_id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.delete(url, headers=headers)
print(response.text)const options = {method: 'DELETE', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.sqwish.ai/v1/models/{model_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"id": "<string>",
"deleted": true
}{
"error": {
"code": "<string>",
"message": "<string>",
"retryable": true,
"request_id": "<string>",
"details": [
{
"path": [
"<string>"
],
"message": "<string>",
"type": "<string>"
}
]
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"retryable": true,
"request_id": "<string>",
"details": [
{
"path": [
"<string>"
],
"message": "<string>",
"type": "<string>"
}
]
}
}