forked from mudler/LocalAI
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathswagger.yaml
More file actions
2022 lines (2022 loc) · 49 KB
/
Copy pathswagger.yaml
File metadata and controls
2022 lines (2022 loc) · 49 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
basePath: /
definitions:
config.Gallery:
properties:
name:
type: string
url:
type: string
type: object
functions.Function:
properties:
description:
type: string
name:
type: string
parameters:
additionalProperties: {}
type: object
strict:
type: boolean
type: object
functions.Item:
properties:
properties:
additionalProperties: {}
type: object
type:
type: string
type: object
functions.JSONFunctionStructure:
properties:
$defs:
additionalProperties: {}
type: object
anyOf:
items:
$ref: '#/definitions/functions.Item'
type: array
oneOf:
items:
$ref: '#/definitions/functions.Item'
type: array
type: object
functions.Tool:
properties:
function:
$ref: '#/definitions/functions.Function'
type:
type: string
type: object
gallery.File:
properties:
filename:
type: string
sha256:
type: string
uri:
type: string
type: object
gallery.GalleryBackend:
properties:
alias:
type: string
backend:
description: |-
Backend is the resolved backend engine for this model (e.g. "llama-cpp").
Populated at load time from overrides, inline config, or the URL-referenced config file.
type: string
capabilities:
additionalProperties:
type: string
type: object
description:
type: string
files:
description: AdditionalFiles are used to add additional files to the model
items:
$ref: '#/definitions/gallery.File'
type: array
gallery:
allOf:
- $ref: '#/definitions/config.Gallery'
description: Gallery is a reference to the gallery which contains the model
icon:
type: string
installed:
description: Installed is used to indicate if the model is installed or not
type: boolean
license:
type: string
mirrors:
items:
type: string
type: array
name:
type: string
size:
description: |-
Size is an optional hardcoded model size string (e.g. "500MB", "14.5GB").
Used when the size cannot be estimated automatically.
type: string
tags:
items:
type: string
type: array
uri:
type: string
url:
type: string
urls:
items:
type: string
type: array
type: object
gallery.GalleryModel:
properties:
backend:
description: |-
Backend is the resolved backend engine for this model (e.g. "llama-cpp").
Populated at load time from overrides, inline config, or the URL-referenced config file.
type: string
config_file:
additionalProperties: {}
description: config_file is read in the situation where URL is blank - and
therefore this is a base config.
type: object
description:
type: string
files:
description: AdditionalFiles are used to add additional files to the model
items:
$ref: '#/definitions/gallery.File'
type: array
gallery:
allOf:
- $ref: '#/definitions/config.Gallery'
description: Gallery is a reference to the gallery which contains the model
icon:
type: string
installed:
description: Installed is used to indicate if the model is installed or not
type: boolean
license:
type: string
name:
type: string
overrides:
additionalProperties: {}
description: Overrides are used to override the configuration of the model
located at URL
type: object
size:
description: |-
Size is an optional hardcoded model size string (e.g. "500MB", "14.5GB").
Used when the size cannot be estimated automatically.
type: string
tags:
items:
type: string
type: array
url:
type: string
urls:
items:
type: string
type: array
type: object
galleryop.OpStatus:
properties:
cancellable:
description: Cancellable is true if the operation can be cancelled
type: boolean
cancelled:
description: Cancelled is true if the operation was cancelled
type: boolean
deletion:
description: Deletion is true if the operation is a deletion
type: boolean
downloaded_size:
type: string
error: {}
file_name:
type: string
file_size:
type: string
gallery_element_name:
type: string
message:
type: string
processed:
type: boolean
progress:
type: number
type: object
localai.GalleryBackend:
properties:
id:
type: string
type: object
localai.GalleryModel:
properties:
backend:
description: |-
Backend is the resolved backend engine for this model (e.g. "llama-cpp").
Populated at load time from overrides, inline config, or the URL-referenced config file.
type: string
config_file:
additionalProperties: {}
description: config_file is read in the situation where URL is blank - and
therefore this is a base config.
type: object
description:
type: string
files:
description: AdditionalFiles are used to add additional files to the model
items:
$ref: '#/definitions/gallery.File'
type: array
gallery:
allOf:
- $ref: '#/definitions/config.Gallery'
description: Gallery is a reference to the gallery which contains the model
icon:
type: string
id:
type: string
installed:
description: Installed is used to indicate if the model is installed or not
type: boolean
license:
type: string
name:
type: string
overrides:
additionalProperties: {}
description: Overrides are used to override the configuration of the model
located at URL
type: object
size:
description: |-
Size is an optional hardcoded model size string (e.g. "500MB", "14.5GB").
Used when the size cannot be estimated automatically.
type: string
tags:
items:
type: string
type: array
url:
type: string
urls:
items:
type: string
type: array
type: object
proto.MemoryUsageData:
properties:
breakdown:
additionalProperties:
format: int64
type: integer
type: object
total:
type: integer
type: object
proto.StatusResponse:
properties:
memory:
$ref: '#/definitions/proto.MemoryUsageData'
state:
$ref: '#/definitions/proto.StatusResponse_State'
type: object
proto.StatusResponse_State:
enum:
- 0
- 1
- 2
- -1
format: int32
type: integer
x-enum-varnames:
- StatusResponse_UNINITIALIZED
- StatusResponse_BUSY
- StatusResponse_READY
- StatusResponse_ERROR
proto.VADResponse:
properties:
segments:
items:
$ref: '#/definitions/proto.VADSegment'
type: array
type: object
proto.VADSegment:
properties:
end:
type: number
start:
type: number
type: object
schema.AnthropicContentBlock:
properties:
content: {}
id:
type: string
input:
additionalProperties: {}
type: object
is_error:
type: boolean
name:
type: string
source:
$ref: '#/definitions/schema.AnthropicImageSource'
text:
type: string
tool_use_id:
type: string
type:
type: string
type: object
schema.AnthropicImageSource:
properties:
data:
type: string
media_type:
type: string
type:
type: string
type: object
schema.AnthropicMessage:
properties:
content: {}
role:
type: string
type: object
schema.AnthropicRequest:
properties:
max_tokens:
type: integer
messages:
items:
$ref: '#/definitions/schema.AnthropicMessage'
type: array
metadata:
additionalProperties:
type: string
type: object
model:
type: string
stop_sequences:
items:
type: string
type: array
stream:
type: boolean
system:
type: string
temperature:
type: number
tool_choice: {}
tools:
items:
$ref: '#/definitions/schema.AnthropicTool'
type: array
top_k:
type: integer
top_p:
type: number
type: object
schema.AnthropicResponse:
properties:
content:
items:
$ref: '#/definitions/schema.AnthropicContentBlock'
type: array
id:
type: string
model:
type: string
role:
type: string
stop_reason:
type: string
stop_sequence:
type: string
type:
type: string
usage:
$ref: '#/definitions/schema.AnthropicUsage'
type: object
schema.AnthropicTool:
properties:
description:
type: string
input_schema:
additionalProperties: {}
type: object
name:
type: string
type: object
schema.AnthropicUsage:
properties:
input_tokens:
type: integer
output_tokens:
type: integer
type: object
schema.BackendMonitorRequest:
properties:
model:
type: string
type: object
schema.BackendResponse:
properties:
id:
type: string
status_url:
type: string
type: object
schema.Choice:
properties:
delta:
$ref: '#/definitions/schema.Message'
finish_reason:
type: string
index:
type: integer
logprobs:
$ref: '#/definitions/schema.Logprobs'
message:
$ref: '#/definitions/schema.Message'
text:
type: string
type: object
schema.Detection:
properties:
class_name:
type: string
height:
type: number
width:
type: number
x:
type: number
"y":
type: number
type: object
schema.DetectionRequest:
properties:
image:
type: string
model:
type: string
type: object
schema.DetectionResponse:
properties:
detections:
items:
$ref: '#/definitions/schema.Detection'
type: array
type: object
schema.ElevenLabsSoundGenerationRequest:
properties:
bpm:
type: integer
caption:
type: string
do_sample:
type: boolean
duration_seconds:
type: number
instrumental:
description: 'Simple mode: use text as description; optional instrumental
/ vocal_language'
type: boolean
keyscale:
type: string
language:
type: string
lyrics:
type: string
model_id:
type: string
prompt_influence:
type: number
text:
type: string
think:
description: Advanced mode
type: boolean
timesignature:
type: string
vocal_language:
type: string
type: object
schema.FunctionCall:
properties:
arguments:
type: string
name:
type: string
type: object
schema.GalleryResponse:
properties:
estimated_size_bytes:
type: integer
estimated_size_display:
type: string
estimated_vram_bytes:
type: integer
estimated_vram_display:
type: string
status:
type: string
uuid:
type: string
type: object
schema.InputTokensDetails:
properties:
image_tokens:
type: integer
text_tokens:
type: integer
type: object
schema.Item:
properties:
b64_json:
type: string
index:
type: integer
object:
type: string
url:
description: Images
type: string
type: object
schema.JINADocumentResult:
properties:
document:
$ref: '#/definitions/schema.JINAText'
index:
type: integer
relevance_score:
type: number
type: object
schema.JINARerankRequest:
properties:
backend:
type: string
documents:
items:
type: string
type: array
model:
type: string
query:
type: string
top_n:
type: integer
type: object
schema.JINARerankResponse:
properties:
model:
type: string
results:
items:
$ref: '#/definitions/schema.JINADocumentResult'
type: array
usage:
$ref: '#/definitions/schema.JINAUsageInfo'
type: object
schema.JINAText:
properties:
text:
type: string
type: object
schema.JINAUsageInfo:
properties:
prompt_tokens:
type: integer
total_tokens:
type: integer
type: object
schema.LogprobContent:
properties:
bytes:
items:
type: integer
type: array
id:
type: integer
logprob:
type: number
token:
type: string
top_logprobs:
items:
$ref: '#/definitions/schema.LogprobContent'
type: array
type: object
schema.Logprobs:
properties:
content:
items:
$ref: '#/definitions/schema.LogprobContent'
type: array
type: object
schema.LogprobsValue:
properties:
enabled:
description: true if logprobs should be returned
type: boolean
type: object
schema.Message:
properties:
content:
description: The message content
function_call:
description: A result of a function call
name:
description: The message name (used for tools calls)
type: string
reasoning:
description: Reasoning content extracted from <thinking>...</thinking> tags
type: string
role:
description: The message role
type: string
string_audios:
items:
type: string
type: array
string_content:
type: string
string_images:
items:
type: string
type: array
string_videos:
items:
type: string
type: array
tool_call_id:
type: string
tool_calls:
items:
$ref: '#/definitions/schema.ToolCall'
type: array
type: object
schema.ModelsDataResponse:
properties:
data:
items:
$ref: '#/definitions/schema.OpenAIModel'
type: array
object:
type: string
type: object
schema.NodeData:
properties:
id:
type: string
lastSeen:
type: string
name:
type: string
serviceID:
type: string
tunnelAddress:
type: string
type: object
schema.ORAnnotation:
properties:
end_index:
type: integer
start_index:
type: integer
title:
type: string
type:
description: url_citation
type: string
url:
type: string
type: object
schema.ORContentPart:
properties:
annotations:
description: REQUIRED for output_text - must always be present (use [])
items:
$ref: '#/definitions/schema.ORAnnotation'
type: array
detail:
description: low|high|auto for images
type: string
file_data:
type: string
file_url:
type: string
filename:
type: string
image_url:
type: string
logprobs:
description: REQUIRED for output_text - must always be present (use [])
items:
$ref: '#/definitions/schema.ORLogProb'
type: array
refusal:
type: string
text:
description: REQUIRED for output_text - must always be present (even if empty)
type: string
type:
description: input_text|input_image|input_file|output_text|refusal
type: string
type: object
schema.ORError:
properties:
code:
type: string
message:
type: string
param:
type: string
type:
description: invalid_request|not_found|server_error|model_error|too_many_requests
type: string
type: object
schema.ORFunctionTool:
properties:
description:
type: string
name:
type: string
parameters:
additionalProperties: {}
type: object
strict:
description: Always include in response
type: boolean
type:
description: always "function"
type: string
type: object
schema.ORIncompleteDetails:
properties:
reason:
type: string
type: object
schema.ORInputTokensDetails:
properties:
cached_tokens:
description: Always include, even if 0
type: integer
type: object
schema.ORItemField:
properties:
arguments:
type: string
call_id:
description: Function call fields
type: string
content:
description: string or []ORContentPart for messages
encrypted_content:
description: Provider-specific encrypted content
type: string
id:
description: Present for all output items
type: string
name:
type: string
output:
description: Function call output fields
role:
description: Message fields
type: string
status:
description: in_progress|completed|incomplete
type: string
summary:
description: Reasoning fields (for type == "reasoning")
items:
$ref: '#/definitions/schema.ORContentPart'
type: array
type:
description: message|function_call|function_call_output|reasoning|item_reference
type: string
type: object
schema.ORLogProb:
properties:
bytes:
items:
type: integer
type: array
logprob:
type: number
token:
type: string
top_logprobs:
items:
$ref: '#/definitions/schema.ORTopLogProb'
type: array
type: object
schema.OROutputTokensDetails:
properties:
reasoning_tokens:
description: Always include, even if 0
type: integer
type: object
schema.ORReasoning:
properties:
effort:
type: string
summary:
type: string
type: object
schema.ORReasoningParam:
properties:
effort:
description: '"none"|"low"|"medium"|"high"|"xhigh"'
type: string
summary:
description: '"auto"|"concise"|"detailed"'
type: string
type: object
schema.ORResponseResource:
properties:
background:
type: boolean
completed_at:
description: 'Required: present as number or null'
type: integer
created_at:
type: integer
error:
allOf:
- $ref: '#/definitions/schema.ORError'
description: Always present, null if no error
frequency_penalty:
type: number
id:
type: string
incomplete_details:
allOf:
- $ref: '#/definitions/schema.ORIncompleteDetails'
description: Always present, null if complete
instructions:
type: string
max_output_tokens:
type: integer
max_tool_calls:
description: nullable
type: integer
metadata:
additionalProperties:
type: string
description: Metadata and operational flags
type: object
model:
type: string
object:
description: always "response"
type: string
output:
items:
$ref: '#/definitions/schema.ORItemField'
type: array
parallel_tool_calls:
type: boolean
presence_penalty:
type: number
previous_response_id:
type: string
prompt_cache_key:
description: nullable
type: string
reasoning:
allOf:
- $ref: '#/definitions/schema.ORReasoning'
description: nullable
safety_identifier:
description: Safety and caching
type: string
service_tier:
type: string
status:
description: in_progress|completed|failed|incomplete
type: string
store:
type: boolean
temperature:
description: Sampling parameters (always required)
type: number
text:
allOf:
- $ref: '#/definitions/schema.ORTextConfig'
description: Text format configuration
tool_choice: {}
tools:
description: Tool-related fields
items:
$ref: '#/definitions/schema.ORFunctionTool'
type: array
top_logprobs:
description: Default to 0
type: integer
top_p:
type: number
truncation:
description: Truncation and reasoning
type: string
usage:
allOf:
- $ref: '#/definitions/schema.ORUsage'
description: Usage statistics
type: object
schema.ORTextConfig:
properties:
format:
$ref: '#/definitions/schema.ORTextFormat'
type: object
schema.ORTextFormat:
properties:
type:
description: '"text" or "json_schema"'
type: string
type: object
schema.ORTopLogProb:
properties:
bytes:
items:
type: integer
type: array
logprob:
type: number
token:
type: string
type: object
schema.ORUsage:
properties:
input_tokens:
type: integer
input_tokens_details:
allOf:
- $ref: '#/definitions/schema.ORInputTokensDetails'
description: Always present
output_tokens:
type: integer
output_tokens_details:
allOf:
- $ref: '#/definitions/schema.OROutputTokensDetails'
description: Always present
total_tokens:
type: integer
type: object
schema.OpenAIModel:
properties:
id:
type: string
object:
type: string
type: object
schema.OpenAIRequest:
properties:
backend:
type: string
batch:
description: Custom parameters - not present in the OpenAI API
type: integer
clip_skip:
description: Diffusers
type: integer
echo:
type: boolean
encoding_format:
description: 'Embedding encoding format: "float" (default) or "base64" (OpenAI
Node.js SDK default)'
type: string
file:
description: whisper
type: string
files:
description: Multiple input images for img2img or inpainting
items:
type: string
type: array
frequency_penalty:
type: number
function_call:
description: might be a string or an object
functions:
description: A list of available functions to call
items:
$ref: '#/definitions/functions.Function'
type: array
grammar:
description: A grammar to constrain the LLM output
type: string
grammar_json_functions: