Skip to content

Commit cc7f909

Browse files
feat(api): api update
1 parent 6e0a4dd commit cc7f909

File tree

5 files changed

+38
-2
lines changed

5 files changed

+38
-2
lines changed

.stats.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
configured_endpoints: 9
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lmnt-kaikato-aryp6r%2Flmnt-com-cda06fc480f98d0d27b29a256bc0b4bd10e8700b0d74d9cf97ad8a17c1645252.yml
3-
openapi_spec_hash: 34cd66cad890377b644bcc5b53c0e1a4
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lmnt-kaikato-aryp6r%2Flmnt-com-65c2c6c535ed9613a2ec066fcb37e028c45e1a6cf67639d3f3b7d76b067cd3cf.yml
3+
openapi_spec_hash: 53f47fb39d900e20ae936b3ea9bafa40
44
config_hash: ad76a808facacf5f53e58d591653bac6

src/lmnt/resources/speech.py

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -163,6 +163,7 @@ def generate(
163163
*,
164164
text: str,
165165
voice: str,
166+
debug: bool | NotGiven = NOT_GIVEN,
166167
format: Literal["aac", "mp3", "ulaw", "wav", "webm", "pcm_s16le", "pcm_f32le"] | NotGiven = NOT_GIVEN,
167168
language: Literal[
168169
"auto",
@@ -215,6 +216,9 @@ def generate(
215216
voice: The voice id of the voice to use; voice ids can be retrieved by calls to
216217
`List voices` or `Voice info`.
217218
219+
debug: When set to true, the generated speech will also be saved to your
220+
[clip library](https://app.lmnt.com/clips) in the LMNT playground.
221+
218222
format: The desired output format of the audio. If you are using a streaming endpoint,
219223
you'll generate audio faster by selecting a streamable format since chunks are
220224
encoded and returned as they're generated. For non-streamable formats, the
@@ -268,6 +272,7 @@ def generate(
268272
{
269273
"text": text,
270274
"voice": voice,
275+
"debug": debug,
271276
"format": format,
272277
"language": language,
273278
"model": model,
@@ -289,6 +294,7 @@ def generate_detailed(
289294
*,
290295
text: str,
291296
voice: str,
297+
debug: bool | NotGiven = NOT_GIVEN,
292298
format: Literal["aac", "mp3", "ulaw", "wav", "webm", "pcm_s16le", "pcm_f32le"] | NotGiven = NOT_GIVEN,
293299
language: Literal[
294300
"auto",
@@ -340,6 +346,9 @@ def generate_detailed(
340346
voice: The voice id of the voice to use; voice ids can be retrieved by calls to
341347
`List voices` or `Voice info`.
342348
349+
debug: When set to true, the generated speech will also be saved to your
350+
[clip library](https://app.lmnt.com/clips) in the LMNT playground.
351+
343352
format: The desired output format of the audio. If you are using a streaming endpoint,
344353
you'll generate audio faster by selecting a streamable format since chunks are
345354
encoded and returned as they're generated. For non-streamable formats, the
@@ -394,6 +403,7 @@ def generate_detailed(
394403
{
395404
"text": text,
396405
"voice": voice,
406+
"debug": debug,
397407
"format": format,
398408
"language": language,
399409
"model": model,
@@ -546,6 +556,7 @@ async def generate(
546556
*,
547557
text: str,
548558
voice: str,
559+
debug: bool | NotGiven = NOT_GIVEN,
549560
format: Literal["aac", "mp3", "ulaw", "wav", "webm", "pcm_s16le", "pcm_f32le"] | NotGiven = NOT_GIVEN,
550561
language: Literal[
551562
"auto",
@@ -598,6 +609,9 @@ async def generate(
598609
voice: The voice id of the voice to use; voice ids can be retrieved by calls to
599610
`List voices` or `Voice info`.
600611
612+
debug: When set to true, the generated speech will also be saved to your
613+
[clip library](https://app.lmnt.com/clips) in the LMNT playground.
614+
601615
format: The desired output format of the audio. If you are using a streaming endpoint,
602616
you'll generate audio faster by selecting a streamable format since chunks are
603617
encoded and returned as they're generated. For non-streamable formats, the
@@ -651,6 +665,7 @@ async def generate(
651665
{
652666
"text": text,
653667
"voice": voice,
668+
"debug": debug,
654669
"format": format,
655670
"language": language,
656671
"model": model,
@@ -672,6 +687,7 @@ async def generate_detailed(
672687
*,
673688
text: str,
674689
voice: str,
690+
debug: bool | NotGiven = NOT_GIVEN,
675691
format: Literal["aac", "mp3", "ulaw", "wav", "webm", "pcm_s16le", "pcm_f32le"] | NotGiven = NOT_GIVEN,
676692
language: Literal[
677693
"auto",
@@ -723,6 +739,9 @@ async def generate_detailed(
723739
voice: The voice id of the voice to use; voice ids can be retrieved by calls to
724740
`List voices` or `Voice info`.
725741
742+
debug: When set to true, the generated speech will also be saved to your
743+
[clip library](https://app.lmnt.com/clips) in the LMNT playground.
744+
726745
format: The desired output format of the audio. If you are using a streaming endpoint,
727746
you'll generate audio faster by selecting a streamable format since chunks are
728747
encoded and returned as they're generated. For non-streamable formats, the
@@ -777,6 +796,7 @@ async def generate_detailed(
777796
{
778797
"text": text,
779798
"voice": voice,
799+
"debug": debug,
780800
"format": format,
781801
"language": language,
782802
"model": model,

src/lmnt/types/speech_generate_detailed_params.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,12 @@ class SpeechGenerateDetailedParams(TypedDict, total=False):
1717
`List voices` or `Voice info`.
1818
"""
1919

20+
debug: bool
21+
"""
22+
When set to true, the generated speech will also be saved to your
23+
[clip library](https://app.lmnt.com/clips) in the LMNT playground.
24+
"""
25+
2026
format: Literal["aac", "mp3", "ulaw", "wav", "webm", "pcm_s16le", "pcm_f32le"]
2127
"""The desired output format of the audio.
2228

src/lmnt/types/speech_generate_params.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,12 @@ class SpeechGenerateParams(TypedDict, total=False):
1717
`List voices` or `Voice info`.
1818
"""
1919

20+
debug: bool
21+
"""
22+
When set to true, the generated speech will also be saved to your
23+
[clip library](https://app.lmnt.com/clips) in the LMNT playground.
24+
"""
25+
2026
format: Literal["aac", "mp3", "ulaw", "wav", "webm", "pcm_s16le", "pcm_f32le"]
2127
"""The desired output format of the audio.
2228

tests/api_resources/test_speech.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -108,6 +108,7 @@ def test_method_generate_with_all_params(self, client: Lmnt, respx_mock: MockRou
108108
speech = client.speech.generate(
109109
text="hello world.",
110110
voice="leah",
111+
debug=True,
111112
format="aac",
112113
language="auto",
113114
model="blizzard",
@@ -166,6 +167,7 @@ def test_method_generate_detailed_with_all_params(self, client: Lmnt) -> None:
166167
speech = client.speech.generate_detailed(
167168
text="hello world.",
168169
voice="leah",
170+
debug=True,
169171
format="aac",
170172
language="auto",
171173
model="blizzard",
@@ -290,6 +292,7 @@ async def test_method_generate_with_all_params(self, async_client: AsyncLmnt, re
290292
speech = await async_client.speech.generate(
291293
text="hello world.",
292294
voice="leah",
295+
debug=True,
293296
format="aac",
294297
language="auto",
295298
model="blizzard",
@@ -348,6 +351,7 @@ async def test_method_generate_detailed_with_all_params(self, async_client: Asyn
348351
speech = await async_client.speech.generate_detailed(
349352
text="hello world.",
350353
voice="leah",
354+
debug=True,
351355
format="aac",
352356
language="auto",
353357
model="blizzard",

0 commit comments

Comments
 (0)