Skip to content

Commit a91b059

Browse files
localai-botmudler
andauthored
feat(swagger): update swagger (#9660)
Signed-off-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: mudler <2420543+mudler@users.noreply.github.com>
1 parent 4ef45bb commit a91b059

3 files changed

Lines changed: 346 additions & 0 deletions

File tree

swagger/docs.go

Lines changed: 124 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1156,6 +1156,130 @@ const docTemplate = `{
11561156
}
11571157
}
11581158
},
1159+
"/audio/transform": {
1160+
"post": {
1161+
"description": "Runs an audio-in / audio-out transform conditioned on an optional auxiliary reference signal. Concrete transforms include AEC + noise suppression + dereverberation (LocalVQE), voice conversion (reference = target speaker), and pitch shifting. The backend determines the operation; pass model-specific tuning via repeated ` + "`" + `params[\u003ckey\u003e]=\u003cvalue\u003e` + "`" + ` form fields.",
1162+
"consumes": [
1163+
"multipart/form-data"
1164+
],
1165+
"produces": [
1166+
"audio/x-wav"
1167+
],
1168+
"tags": [
1169+
"audio"
1170+
],
1171+
"summary": "Transform audio (echo cancellation, noise suppression, voice conversion, etc.)",
1172+
"parameters": [
1173+
{
1174+
"type": "string",
1175+
"description": "model",
1176+
"name": "model",
1177+
"in": "formData",
1178+
"required": true
1179+
},
1180+
{
1181+
"type": "file",
1182+
"description": "primary input audio file",
1183+
"name": "audio",
1184+
"in": "formData",
1185+
"required": true
1186+
},
1187+
{
1188+
"type": "file",
1189+
"description": "auxiliary reference audio (loopback for AEC, target voice for conversion, etc.)",
1190+
"name": "reference",
1191+
"in": "formData"
1192+
},
1193+
{
1194+
"type": "string",
1195+
"description": "wav | mp3 | ogg | flac",
1196+
"name": "response_format",
1197+
"in": "formData"
1198+
},
1199+
{
1200+
"type": "integer",
1201+
"description": "desired output sample rate",
1202+
"name": "sample_rate",
1203+
"in": "formData"
1204+
}
1205+
],
1206+
"responses": {
1207+
"200": {
1208+
"description": "transformed audio file",
1209+
"schema": {
1210+
"type": "string"
1211+
}
1212+
}
1213+
}
1214+
}
1215+
},
1216+
"/audio/transformations": {
1217+
"post": {
1218+
"description": "Runs an audio-in / audio-out transform conditioned on an optional auxiliary reference signal. Concrete transforms include AEC + noise suppression + dereverberation (LocalVQE), voice conversion (reference = target speaker), and pitch shifting. The backend determines the operation; pass model-specific tuning via repeated ` + "`" + `params[\u003ckey\u003e]=\u003cvalue\u003e` + "`" + ` form fields.",
1219+
"consumes": [
1220+
"multipart/form-data"
1221+
],
1222+
"produces": [
1223+
"audio/x-wav"
1224+
],
1225+
"tags": [
1226+
"audio"
1227+
],
1228+
"summary": "Transform audio (echo cancellation, noise suppression, voice conversion, etc.)",
1229+
"parameters": [
1230+
{
1231+
"type": "string",
1232+
"description": "model",
1233+
"name": "model",
1234+
"in": "formData",
1235+
"required": true
1236+
},
1237+
{
1238+
"type": "file",
1239+
"description": "primary input audio file",
1240+
"name": "audio",
1241+
"in": "formData",
1242+
"required": true
1243+
},
1244+
{
1245+
"type": "file",
1246+
"description": "auxiliary reference audio (loopback for AEC, target voice for conversion, etc.)",
1247+
"name": "reference",
1248+
"in": "formData"
1249+
},
1250+
{
1251+
"type": "string",
1252+
"description": "wav | mp3 | ogg | flac",
1253+
"name": "response_format",
1254+
"in": "formData"
1255+
},
1256+
{
1257+
"type": "integer",
1258+
"description": "desired output sample rate",
1259+
"name": "sample_rate",
1260+
"in": "formData"
1261+
}
1262+
],
1263+
"responses": {
1264+
"200": {
1265+
"description": "transformed audio file",
1266+
"schema": {
1267+
"type": "string"
1268+
}
1269+
}
1270+
}
1271+
}
1272+
},
1273+
"/audio/transformations/stream": {
1274+
"get": {
1275+
"description": "Streams binary PCM frames in (interleaved stereo: ch0=audio, ch1=reference) and out (mono). The first message must be a JSON ` + "`" + `session.update` + "`" + ` envelope describing model + sample format + frame size + backend params. Server emits binary PCM on the same cadence.",
1276+
"tags": [
1277+
"audio"
1278+
],
1279+
"summary": "Bidirectional realtime audio transform over WebSocket.",
1280+
"responses": {}
1281+
}
1282+
},
11591283
"/backend/monitor": {
11601284
"get": {
11611285
"tags": [

swagger/swagger.json

Lines changed: 124 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1153,6 +1153,130 @@
11531153
}
11541154
}
11551155
},
1156+
"/audio/transform": {
1157+
"post": {
1158+
"description": "Runs an audio-in / audio-out transform conditioned on an optional auxiliary reference signal. Concrete transforms include AEC + noise suppression + dereverberation (LocalVQE), voice conversion (reference = target speaker), and pitch shifting. The backend determines the operation; pass model-specific tuning via repeated `params[\u003ckey\u003e]=\u003cvalue\u003e` form fields.",
1159+
"consumes": [
1160+
"multipart/form-data"
1161+
],
1162+
"produces": [
1163+
"audio/x-wav"
1164+
],
1165+
"tags": [
1166+
"audio"
1167+
],
1168+
"summary": "Transform audio (echo cancellation, noise suppression, voice conversion, etc.)",
1169+
"parameters": [
1170+
{
1171+
"type": "string",
1172+
"description": "model",
1173+
"name": "model",
1174+
"in": "formData",
1175+
"required": true
1176+
},
1177+
{
1178+
"type": "file",
1179+
"description": "primary input audio file",
1180+
"name": "audio",
1181+
"in": "formData",
1182+
"required": true
1183+
},
1184+
{
1185+
"type": "file",
1186+
"description": "auxiliary reference audio (loopback for AEC, target voice for conversion, etc.)",
1187+
"name": "reference",
1188+
"in": "formData"
1189+
},
1190+
{
1191+
"type": "string",
1192+
"description": "wav | mp3 | ogg | flac",
1193+
"name": "response_format",
1194+
"in": "formData"
1195+
},
1196+
{
1197+
"type": "integer",
1198+
"description": "desired output sample rate",
1199+
"name": "sample_rate",
1200+
"in": "formData"
1201+
}
1202+
],
1203+
"responses": {
1204+
"200": {
1205+
"description": "transformed audio file",
1206+
"schema": {
1207+
"type": "string"
1208+
}
1209+
}
1210+
}
1211+
}
1212+
},
1213+
"/audio/transformations": {
1214+
"post": {
1215+
"description": "Runs an audio-in / audio-out transform conditioned on an optional auxiliary reference signal. Concrete transforms include AEC + noise suppression + dereverberation (LocalVQE), voice conversion (reference = target speaker), and pitch shifting. The backend determines the operation; pass model-specific tuning via repeated `params[\u003ckey\u003e]=\u003cvalue\u003e` form fields.",
1216+
"consumes": [
1217+
"multipart/form-data"
1218+
],
1219+
"produces": [
1220+
"audio/x-wav"
1221+
],
1222+
"tags": [
1223+
"audio"
1224+
],
1225+
"summary": "Transform audio (echo cancellation, noise suppression, voice conversion, etc.)",
1226+
"parameters": [
1227+
{
1228+
"type": "string",
1229+
"description": "model",
1230+
"name": "model",
1231+
"in": "formData",
1232+
"required": true
1233+
},
1234+
{
1235+
"type": "file",
1236+
"description": "primary input audio file",
1237+
"name": "audio",
1238+
"in": "formData",
1239+
"required": true
1240+
},
1241+
{
1242+
"type": "file",
1243+
"description": "auxiliary reference audio (loopback for AEC, target voice for conversion, etc.)",
1244+
"name": "reference",
1245+
"in": "formData"
1246+
},
1247+
{
1248+
"type": "string",
1249+
"description": "wav | mp3 | ogg | flac",
1250+
"name": "response_format",
1251+
"in": "formData"
1252+
},
1253+
{
1254+
"type": "integer",
1255+
"description": "desired output sample rate",
1256+
"name": "sample_rate",
1257+
"in": "formData"
1258+
}
1259+
],
1260+
"responses": {
1261+
"200": {
1262+
"description": "transformed audio file",
1263+
"schema": {
1264+
"type": "string"
1265+
}
1266+
}
1267+
}
1268+
}
1269+
},
1270+
"/audio/transformations/stream": {
1271+
"get": {
1272+
"description": "Streams binary PCM frames in (interleaved stereo: ch0=audio, ch1=reference) and out (mono). The first message must be a JSON `session.update` envelope describing model + sample format + frame size + backend params. Server emits binary PCM on the same cadence.",
1273+
"tags": [
1274+
"audio"
1275+
],
1276+
"summary": "Bidirectional realtime audio transform over WebSocket.",
1277+
"responses": {}
1278+
}
1279+
},
11561280
"/backend/monitor": {
11571281
"get": {
11581282
"tags": [

swagger/swagger.yaml

Lines changed: 98 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2896,6 +2896,104 @@ paths:
28962896
summary: Clear API traces
28972897
tags:
28982898
- monitoring
2899+
/audio/transform:
2900+
post:
2901+
consumes:
2902+
- multipart/form-data
2903+
description: Runs an audio-in / audio-out transform conditioned on an optional
2904+
auxiliary reference signal. Concrete transforms include AEC + noise suppression
2905+
+ dereverberation (LocalVQE), voice conversion (reference = target speaker),
2906+
and pitch shifting. The backend determines the operation; pass model-specific
2907+
tuning via repeated `params[<key>]=<value>` form fields.
2908+
parameters:
2909+
- description: model
2910+
in: formData
2911+
name: model
2912+
required: true
2913+
type: string
2914+
- description: primary input audio file
2915+
in: formData
2916+
name: audio
2917+
required: true
2918+
type: file
2919+
- description: auxiliary reference audio (loopback for AEC, target voice for
2920+
conversion, etc.)
2921+
in: formData
2922+
name: reference
2923+
type: file
2924+
- description: wav | mp3 | ogg | flac
2925+
in: formData
2926+
name: response_format
2927+
type: string
2928+
- description: desired output sample rate
2929+
in: formData
2930+
name: sample_rate
2931+
type: integer
2932+
produces:
2933+
- audio/x-wav
2934+
responses:
2935+
"200":
2936+
description: transformed audio file
2937+
schema:
2938+
type: string
2939+
summary: Transform audio (echo cancellation, noise suppression, voice conversion,
2940+
etc.)
2941+
tags:
2942+
- audio
2943+
/audio/transformations:
2944+
post:
2945+
consumes:
2946+
- multipart/form-data
2947+
description: Runs an audio-in / audio-out transform conditioned on an optional
2948+
auxiliary reference signal. Concrete transforms include AEC + noise suppression
2949+
+ dereverberation (LocalVQE), voice conversion (reference = target speaker),
2950+
and pitch shifting. The backend determines the operation; pass model-specific
2951+
tuning via repeated `params[<key>]=<value>` form fields.
2952+
parameters:
2953+
- description: model
2954+
in: formData
2955+
name: model
2956+
required: true
2957+
type: string
2958+
- description: primary input audio file
2959+
in: formData
2960+
name: audio
2961+
required: true
2962+
type: file
2963+
- description: auxiliary reference audio (loopback for AEC, target voice for
2964+
conversion, etc.)
2965+
in: formData
2966+
name: reference
2967+
type: file
2968+
- description: wav | mp3 | ogg | flac
2969+
in: formData
2970+
name: response_format
2971+
type: string
2972+
- description: desired output sample rate
2973+
in: formData
2974+
name: sample_rate
2975+
type: integer
2976+
produces:
2977+
- audio/x-wav
2978+
responses:
2979+
"200":
2980+
description: transformed audio file
2981+
schema:
2982+
type: string
2983+
summary: Transform audio (echo cancellation, noise suppression, voice conversion,
2984+
etc.)
2985+
tags:
2986+
- audio
2987+
/audio/transformations/stream:
2988+
get:
2989+
description: 'Streams binary PCM frames in (interleaved stereo: ch0=audio, ch1=reference)
2990+
and out (mono). The first message must be a JSON `session.update` envelope
2991+
describing model + sample format + frame size + backend params. Server emits
2992+
binary PCM on the same cadence.'
2993+
responses: {}
2994+
summary: Bidirectional realtime audio transform over WebSocket.
2995+
tags:
2996+
- audio
28992997
/backend/monitor:
29002998
get:
29012999
parameters:

0 commit comments

Comments
 (0)