mirror of
https://github.com/HeyPuter/puter.git
synced 2026-05-04 16:40:41 +00:00
no_extra_params in together service to prevent defaults from being specified (#2275)
This commit is contained in:
@@ -191,6 +191,7 @@ class AIInterfaceService extends BaseService {
|
||||
frame_images: { type: 'json', optional: true },
|
||||
metadata: { type: 'json', optional: true },
|
||||
input_reference: { type: 'file', optional: true },
|
||||
no_extra_params: { type: 'flag', optional: true },
|
||||
},
|
||||
result_choices: [
|
||||
{
|
||||
|
||||
@@ -69,6 +69,7 @@ class TogetherVideoGenerationService extends BaseService {
|
||||
prompt,
|
||||
model: requestedModel,
|
||||
seconds,
|
||||
no_extra_params,
|
||||
duration,
|
||||
width,
|
||||
height,
|
||||
@@ -102,7 +103,12 @@ class TogetherVideoGenerationService extends BaseService {
|
||||
}, DEFAULT_TEST_VIDEO_URL);
|
||||
}
|
||||
|
||||
const normalizedSeconds = this.#coercePositiveInteger(seconds ?? duration) ?? DEFAULT_DURATION_SECONDS;
|
||||
let normalizedSeconds = this.#coercePositiveInteger(seconds ?? duration);
|
||||
|
||||
if ( ! no_extra_params )
|
||||
{
|
||||
normalizedSeconds ??= DEFAULT_DURATION_SECONDS;
|
||||
}
|
||||
|
||||
const actor = Context.get('actor');
|
||||
if ( ! actor ) {
|
||||
|
||||
Reference in New Issue
Block a user