Skip to content

Commit c3f22d3

Browse files
andreaonofrei01jean-malogithub-actions[bot]speakeasybot
authored
fix: change constFieldCasing from upper to normal (#361)
* fix: change constFieldCasing from upper to normal Keep const fields lowercase (e.g., `role` instead of `ROLE`) to match the actual API values and align with the private SDK. * fix: rm outdated examples and add flush * chore: update excluded files list in run_examples.sh Add async_realtime_transcription_dual_delay_microphone.py to the excluded files list in the run_examples.sh script to prevent it from being executed during example runs. * fix(examples): update excluded job example file name The script was excluding an incorrect file name ("job.py") in the exclude_files array, which has been updated to the correct name ("jobs.py") to ensure the proper example is skipped during execution. * fix: typing * chore(version): bump version to 1.12.4 Update the package version to 1.12.4 in preparation for a new release. * ## Python SDK Changes: (#365) * `mistral.beta.conversations.start()`: * `request.inputs.[array].[]` **Changed** **Breaking** ⚠️ * `response` **Changed** **Breaking** ⚠️ * `mistral.beta.conversations.list()`: `response.[]` **Changed** **Breaking** ⚠️ * `mistral.beta.conversations.get()`: `response` **Changed** **Breaking** ⚠️ * `mistral.beta.conversations.append()`: * `request.inputs.[array].[]` **Changed** **Breaking** ⚠️ * `response` **Changed** **Breaking** ⚠️ * `mistral.beta.conversations.get_history()`: `response` **Changed** **Breaking** ⚠️ * `mistral.beta.conversations.get_messages()`: `response` **Changed** **Breaking** ⚠️ * `mistral.beta.conversations.restart()`: * `request.inputs.[array].[]` **Changed** **Breaking** ⚠️ * `response` **Changed** **Breaking** ⚠️ * `mistral.beta.conversations.start_stream()`: * `request.inputs.[array].[]` **Changed** **Breaking** ⚠️ * `response.[].data` **Changed** **Breaking** ⚠️ * `mistral.beta.conversations.append_stream()`: * `request.inputs.[array].[]` **Changed** **Breaking** ⚠️ * `response.[].data` **Changed** **Breaking** ⚠️ * `mistral.beta.conversations.restart_stream()`: * `request.inputs.[array].[]` **Changed** **Breaking** ⚠️ * `response.[].data` **Changed** **Breaking** ⚠️ * `mistral.beta.agents.create()`: `response.object` **Changed** **Breaking** ⚠️ * `mistral.beta.agents.list()`: `response.[].object` **Changed** **Breaking** ⚠️ * `mistral.beta.agents.get()`: `response.object` **Changed** **Breaking** ⚠️ * `mistral.beta.agents.update()`: `response.object` **Changed** **Breaking** ⚠️ * `mistral.beta.agents.update_version()`: `response.object` **Changed** **Breaking** ⚠️ * `mistral.beta.agents.list_versions()`: `response.[].object` **Changed** **Breaking** ⚠️ * `mistral.beta.agents.get_version()`: `response.object` **Changed** **Breaking** ⚠️ * `mistral.chat.complete()`: * `request.messages.[]` **Changed** **Breaking** ⚠️ * `response.choices.[].message` **Changed** **Breaking** ⚠️ * `mistral.chat.stream()`: * `request.messages.[]` **Changed** **Breaking** ⚠️ * `response.[].data.choices.[].delta.content.[array].[]` **Changed** **Breaking** ⚠️ * `mistral.fim.complete()`: `response.choices.[].message` **Changed** **Breaking** ⚠️ * `mistral.fim.stream()`: `response.[].data.choices.[].delta.content.[array].[]` **Changed** **Breaking** ⚠️ * `mistral.agents.complete()`: * `request.messages.[]` **Changed** **Breaking** ⚠️ * `response.choices.[].message` **Changed** **Breaking** ⚠️ * `mistral.agents.stream()`: * `request.messages.[]` **Changed** **Breaking** ⚠️ * `response.[].data.choices.[].delta.content.[array].[]` **Changed** **Breaking** ⚠️ * `mistral.classifiers.moderate_chat()`: * `request.inputs.[array].[]` **Changed** **Breaking** ⚠️ * `mistral.classifiers.classify_chat()`: * `request.inputs.[inputs].messages.[]` **Changed** **Breaking** ⚠️ * `mistral.ocr.process()`: `request.document` **Changed** **Breaking** ⚠️ * `mistral.audio.transcriptions.complete()`: `response.segments.[].type` **Changed** **Breaking** ⚠️ * `mistral.audio.transcriptions.stream()`: `response.[].data` **Changed** **Breaking** ⚠️ Co-authored-by: speakeasybot <bot@speakeasyapi.dev> --------- Co-authored-by: jean-malo <jm@mistral.ai> Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: speakeasybot <bot@speakeasyapi.dev>
1 parent 2b8a126 commit c3f22d3

187 files changed

Lines changed: 1448 additions & 1666 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.speakeasy/gen.lock

Lines changed: 300 additions & 448 deletions
Large diffs are not rendered by default.

.speakeasy/gen.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ generation:
2626
generateNewTests: false
2727
skipResponseBodyAssertions: false
2828
python:
29-
version: 1.12.3
29+
version: 1.12.4
3030
additionalDependencies:
3131
dev:
3232
pytest: ^8.2.2
@@ -39,7 +39,7 @@ python:
3939
- Mistral
4040
baseErrorName: MistralError
4141
clientServerStatusCodesAsErrors: true
42-
constFieldCasing: upper
42+
constFieldCasing: normal
4343
defaultErrorName: SDKError
4444
description: Python Client SDK for the Mistral AI API.
4545
enableCustomCodeRegions: true

.speakeasy/workflow.lock

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,11 @@ sources:
1414
- latest
1515
mistral-openapi:
1616
sourceNamespace: mistral-openapi
17-
sourceRevisionDigest: sha256:68e24d172497384492f80cf1ec23b4fc8ad59fa199d511ef160a0fbc64aa0647
18-
sourceBlobDigest: sha256:de8480a3fb194b27118816d5960d922d9ee87d35c00768fa64086bf232c8cef7
17+
sourceRevisionDigest: sha256:c29a0b26265277cc94c25291ddb42a83d5ce6dd3d1fb195ddfb142684200e5ba
18+
sourceBlobDigest: sha256:088d68c900b858d8056dfbb9df4f6bc51dfebb62e947a2a5a47004c61b9fea39
1919
tags:
2020
- latest
21-
- speakeasy-sdk-regen-v1-1771338985
21+
- speakeasy-sdk-regen-fix-const-field-casing-normal-v1-1771609036
2222
targets:
2323
mistralai-azure-sdk:
2424
source: mistral-azure-source
@@ -37,10 +37,10 @@ targets:
3737
mistralai-sdk:
3838
source: mistral-openapi
3939
sourceNamespace: mistral-openapi
40-
sourceRevisionDigest: sha256:68e24d172497384492f80cf1ec23b4fc8ad59fa199d511ef160a0fbc64aa0647
41-
sourceBlobDigest: sha256:de8480a3fb194b27118816d5960d922d9ee87d35c00768fa64086bf232c8cef7
40+
sourceRevisionDigest: sha256:c29a0b26265277cc94c25291ddb42a83d5ce6dd3d1fb195ddfb142684200e5ba
41+
sourceBlobDigest: sha256:088d68c900b858d8056dfbb9df4f6bc51dfebb62e947a2a5a47004c61b9fea39
4242
codeSamplesNamespace: mistral-openapi-code-samples
43-
codeSamplesRevisionDigest: sha256:017e32d4895b127fb81874746a264c38fb6e7f9afb57f482416bbc9be1208501
43+
codeSamplesRevisionDigest: sha256:544546b133aca1fea03d3874b8ebc68206115f16fb0047949d9ea64b162674ed
4444
workflow:
4545
workflowVersion: 1.0.0
4646
speakeasyVersion: 1.685.0

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -146,8 +146,8 @@ with Mistral(
146146

147147
res = mistral.chat.complete(model="mistral-large-latest", messages=[
148148
{
149-
"content": "Who is the best French painter? Answer in one short sentence.",
150149
"role": "user",
150+
"content": "Who is the best French painter? Answer in one short sentence.",
151151
},
152152
], stream=False, response_format={
153153
"type": "text",
@@ -175,8 +175,8 @@ async def main():
175175

176176
res = await mistral.chat.complete_async(model="mistral-large-latest", messages=[
177177
{
178-
"content": "Who is the best French painter? Answer in one short sentence.",
179178
"role": "user",
179+
"content": "Who is the best French painter? Answer in one short sentence.",
180180
},
181181
], stream=False, response_format={
182182
"type": "text",
@@ -254,8 +254,8 @@ with Mistral(
254254

255255
res = mistral.agents.complete(messages=[
256256
{
257-
"content": "Who is the best French painter? Answer in one short sentence.",
258257
"role": "user",
258+
"content": "Who is the best French painter? Answer in one short sentence.",
259259
},
260260
], agent_id="<id>", stream=False, response_format={
261261
"type": "text",
@@ -283,8 +283,8 @@ async def main():
283283

284284
res = await mistral.agents.complete_async(messages=[
285285
{
286-
"content": "Who is the best French painter? Answer in one short sentence.",
287286
"role": "user",
287+
"content": "Who is the best French painter? Answer in one short sentence.",
288288
},
289289
], agent_id="<id>", stream=False, response_format={
290290
"type": "text",

RELEASES.md

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -398,4 +398,14 @@ Based on:
398398
### Generated
399399
- [python v1.12.3] .
400400
### Releases
401-
- [PyPI v1.12.3] https://pypi.org/project/mistralai/1.12.3 - .
401+
- [PyPI v1.12.3] https://pypi.org/project/mistralai/1.12.3 - .
402+
403+
## 2026-02-20 17:36:54
404+
### Changes
405+
Based on:
406+
- OpenAPI Doc
407+
- Speakeasy CLI 1.685.0 (2.794.1) https://github.com/speakeasy-api/speakeasy
408+
### Generated
409+
- [python v1.12.4] .
410+
### Releases
411+
- [PyPI v1.12.4] https://pypi.org/project/mistralai/1.12.4 - .

USAGE.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@ with Mistral(
1515

1616
res = mistral.chat.complete(model="mistral-large-latest", messages=[
1717
{
18-
"content": "Who is the best French painter? Answer in one short sentence.",
1918
"role": "user",
19+
"content": "Who is the best French painter? Answer in one short sentence.",
2020
},
2121
], stream=False, response_format={
2222
"type": "text",
@@ -44,8 +44,8 @@ async def main():
4444

4545
res = await mistral.chat.complete_async(model="mistral-large-latest", messages=[
4646
{
47-
"content": "Who is the best French painter? Answer in one short sentence.",
4847
"role": "user",
48+
"content": "Who is the best French painter? Answer in one short sentence.",
4949
},
5050
], stream=False, response_format={
5151
"type": "text",
@@ -123,8 +123,8 @@ with Mistral(
123123

124124
res = mistral.agents.complete(messages=[
125125
{
126-
"content": "Who is the best French painter? Answer in one short sentence.",
127126
"role": "user",
127+
"content": "Who is the best French painter? Answer in one short sentence.",
128128
},
129129
], agent_id="<id>", stream=False, response_format={
130130
"type": "text",
@@ -152,8 +152,8 @@ async def main():
152152

153153
res = await mistral.agents.complete_async(messages=[
154154
{
155-
"content": "Who is the best French painter? Answer in one short sentence.",
156155
"role": "user",
156+
"content": "Who is the best French painter? Answer in one short sentence.",
157157
},
158158
], agent_id="<id>", stream=False, response_format={
159159
"type": "text",

docs/models/agent.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
| `description` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A |
1414
| `handoffs` | List[*str*] | :heavy_minus_sign: | N/A |
1515
| `metadata` | Dict[str, *Any*] | :heavy_minus_sign: | N/A |
16-
| `object` | [Optional[models.AgentObject]](../models/agentobject.md) | :heavy_minus_sign: | N/A |
16+
| `object` | *Optional[Literal["agent"]]* | :heavy_minus_sign: | N/A |
1717
| `id` | *str* | :heavy_check_mark: | N/A |
1818
| `version` | *int* | :heavy_check_mark: | N/A |
1919
| `versions` | List[*int*] | :heavy_check_mark: | N/A |

docs/models/agentconversation.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
| `name` | *OptionalNullable[str]* | :heavy_minus_sign: | Name given to the conversation. |
99
| `description` | *OptionalNullable[str]* | :heavy_minus_sign: | Description of the what the conversation is about. |
1010
| `metadata` | Dict[str, *Any*] | :heavy_minus_sign: | Custom metadata for the conversation. |
11-
| `object` | [Optional[models.AgentConversationObject]](../models/agentconversationobject.md) | :heavy_minus_sign: | N/A |
11+
| `object` | *Optional[Literal["conversation"]]* | :heavy_minus_sign: | N/A |
1212
| `id` | *str* | :heavy_check_mark: | N/A |
1313
| `created_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_check_mark: | N/A |
1414
| `updated_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_check_mark: | N/A |

docs/models/agentconversationobject.md

Lines changed: 0 additions & 8 deletions
This file was deleted.

docs/models/agenthandoffdoneevent.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,11 @@
33

44
## Fields
55

6-
| Field | Type | Required | Description |
7-
| ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ |
8-
| `type` | [Optional[models.AgentHandoffDoneEventType]](../models/agenthandoffdoneeventtype.md) | :heavy_minus_sign: | N/A |
9-
| `created_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_minus_sign: | N/A |
10-
| `output_index` | *Optional[int]* | :heavy_minus_sign: | N/A |
11-
| `id` | *str* | :heavy_check_mark: | N/A |
12-
| `next_agent_id` | *str* | :heavy_check_mark: | N/A |
13-
| `next_agent_name` | *str* | :heavy_check_mark: | N/A |
6+
| Field | Type | Required | Description |
7+
| -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- |
8+
| `type` | *Optional[Literal["agent.handoff.done"]]* | :heavy_minus_sign: | N/A |
9+
| `created_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_minus_sign: | N/A |
10+
| `output_index` | *Optional[int]* | :heavy_minus_sign: | N/A |
11+
| `id` | *str* | :heavy_check_mark: | N/A |
12+
| `next_agent_id` | *str* | :heavy_check_mark: | N/A |
13+
| `next_agent_name` | *str* | :heavy_check_mark: | N/A |

0 commit comments

Comments
 (0)