weave-typescript 0.8.0 → 0.9.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/weaveapi/llmx/v1/capabilities.pb.d.ts +188 -17
- package/dist/weaveapi/llmx/v1/capabilities.pb.js +438 -162
- package/dist/weaveapi/llmx/v1/model.pb.d.ts +1 -11
- package/dist/weaveapi/llmx/v1/model.pb.js +7 -135
- package/dist/weaveapi/llmx/v1/pricing.pb.d.ts +142 -0
- package/dist/weaveapi/llmx/v1/pricing.pb.js +825 -0
- package/package.json +1 -1
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
// protoc unknown
|
|
6
6
|
// source: weaveapi/llmx/v1/capabilities.proto
|
|
7
7
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
8
|
-
exports.FineTuning = exports.Embeddings = exports.Video = exports.Audio = exports.Reasoning = exports.Caching = exports.SystemPrompt = exports.ToolUse = exports.Vision = exports.FunctionCalling = exports.Streaming = exports.StructuredResponse = exports.Capability = exports.Hyperparameter = exports.DistanceMetric = exports.ReasoningStrategy = exports.CacheStrategy = exports.ToolType = exports.VideoFormat = exports.AudioFormat = exports.ImageFormat = exports.JsonSchemaType = exports.DataFormat = exports.CapabilityType = exports.protobufPackage = void 0;
|
|
8
|
+
exports.FineTuning = exports.Embeddings = exports.Video = exports.Audio = exports.Reasoning = exports.Caching = exports.SystemPrompt = exports.ToolUse = exports.Vision = exports.FunctionCalling = exports.Streaming = exports.StructuredResponse = exports.Text = exports.Capability = exports.ModalityDirection = exports.Hyperparameter = exports.DistanceMetric = exports.ReasoningStrategy = exports.CacheStrategy = exports.ToolType = exports.VideoFormat = exports.AudioFormat = exports.ImageFormat = exports.JsonSchemaType = exports.DataFormat = exports.CapabilityType = exports.protobufPackage = void 0;
|
|
9
9
|
exports.capabilityTypeFromJSON = capabilityTypeFromJSON;
|
|
10
10
|
exports.capabilityTypeToJSON = capabilityTypeToJSON;
|
|
11
11
|
exports.dataFormatFromJSON = dataFormatFromJSON;
|
|
@@ -28,6 +28,8 @@ exports.distanceMetricFromJSON = distanceMetricFromJSON;
|
|
|
28
28
|
exports.distanceMetricToJSON = distanceMetricToJSON;
|
|
29
29
|
exports.hyperparameterFromJSON = hyperparameterFromJSON;
|
|
30
30
|
exports.hyperparameterToJSON = hyperparameterToJSON;
|
|
31
|
+
exports.modalityDirectionFromJSON = modalityDirectionFromJSON;
|
|
32
|
+
exports.modalityDirectionToJSON = modalityDirectionToJSON;
|
|
31
33
|
/* eslint-disable */
|
|
32
34
|
const wire_1 = require("@bufbuild/protobuf/wire");
|
|
33
35
|
exports.protobufPackage = "weaveapi.llmx.v1";
|
|
@@ -35,18 +37,21 @@ exports.protobufPackage = "weaveapi.llmx.v1";
|
|
|
35
37
|
var CapabilityType;
|
|
36
38
|
(function (CapabilityType) {
|
|
37
39
|
CapabilityType[CapabilityType["CAPABILITY_TYPE_UNSPECIFIED"] = 0] = "CAPABILITY_TYPE_UNSPECIFIED";
|
|
38
|
-
|
|
39
|
-
CapabilityType[CapabilityType["
|
|
40
|
-
|
|
41
|
-
CapabilityType[CapabilityType["
|
|
42
|
-
CapabilityType[CapabilityType["
|
|
43
|
-
CapabilityType[CapabilityType["
|
|
44
|
-
CapabilityType[CapabilityType["
|
|
45
|
-
CapabilityType[CapabilityType["
|
|
46
|
-
CapabilityType[CapabilityType["
|
|
47
|
-
CapabilityType[CapabilityType["
|
|
48
|
-
CapabilityType[CapabilityType["
|
|
49
|
-
CapabilityType[CapabilityType["
|
|
40
|
+
/** CAPABILITY_TYPE_TEXT - Basic text input/output capability */
|
|
41
|
+
CapabilityType[CapabilityType["CAPABILITY_TYPE_TEXT"] = 1] = "CAPABILITY_TYPE_TEXT";
|
|
42
|
+
/** CAPABILITY_TYPE_STRUCTURED_RESPONSE - Structured output (JSON, XML, etc.) */
|
|
43
|
+
CapabilityType[CapabilityType["CAPABILITY_TYPE_STRUCTURED_RESPONSE"] = 2] = "CAPABILITY_TYPE_STRUCTURED_RESPONSE";
|
|
44
|
+
CapabilityType[CapabilityType["CAPABILITY_TYPE_STREAMING"] = 3] = "CAPABILITY_TYPE_STREAMING";
|
|
45
|
+
CapabilityType[CapabilityType["CAPABILITY_TYPE_FUNCTION_CALLING"] = 4] = "CAPABILITY_TYPE_FUNCTION_CALLING";
|
|
46
|
+
CapabilityType[CapabilityType["CAPABILITY_TYPE_VISION"] = 5] = "CAPABILITY_TYPE_VISION";
|
|
47
|
+
CapabilityType[CapabilityType["CAPABILITY_TYPE_TOOL_USE"] = 6] = "CAPABILITY_TYPE_TOOL_USE";
|
|
48
|
+
CapabilityType[CapabilityType["CAPABILITY_TYPE_SYSTEM_PROMPT"] = 7] = "CAPABILITY_TYPE_SYSTEM_PROMPT";
|
|
49
|
+
CapabilityType[CapabilityType["CAPABILITY_TYPE_CACHING"] = 8] = "CAPABILITY_TYPE_CACHING";
|
|
50
|
+
CapabilityType[CapabilityType["CAPABILITY_TYPE_REASONING"] = 9] = "CAPABILITY_TYPE_REASONING";
|
|
51
|
+
CapabilityType[CapabilityType["CAPABILITY_TYPE_AUDIO"] = 10] = "CAPABILITY_TYPE_AUDIO";
|
|
52
|
+
CapabilityType[CapabilityType["CAPABILITY_TYPE_VIDEO"] = 11] = "CAPABILITY_TYPE_VIDEO";
|
|
53
|
+
CapabilityType[CapabilityType["CAPABILITY_TYPE_EMBEDDINGS"] = 12] = "CAPABILITY_TYPE_EMBEDDINGS";
|
|
54
|
+
CapabilityType[CapabilityType["CAPABILITY_TYPE_FINE_TUNING"] = 13] = "CAPABILITY_TYPE_FINE_TUNING";
|
|
50
55
|
CapabilityType[CapabilityType["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
51
56
|
})(CapabilityType || (exports.CapabilityType = CapabilityType = {}));
|
|
52
57
|
function capabilityTypeFromJSON(object) {
|
|
@@ -55,39 +60,42 @@ function capabilityTypeFromJSON(object) {
|
|
|
55
60
|
case "CAPABILITY_TYPE_UNSPECIFIED":
|
|
56
61
|
return CapabilityType.CAPABILITY_TYPE_UNSPECIFIED;
|
|
57
62
|
case 1:
|
|
63
|
+
case "CAPABILITY_TYPE_TEXT":
|
|
64
|
+
return CapabilityType.CAPABILITY_TYPE_TEXT;
|
|
65
|
+
case 2:
|
|
58
66
|
case "CAPABILITY_TYPE_STRUCTURED_RESPONSE":
|
|
59
67
|
return CapabilityType.CAPABILITY_TYPE_STRUCTURED_RESPONSE;
|
|
60
|
-
case
|
|
68
|
+
case 3:
|
|
61
69
|
case "CAPABILITY_TYPE_STREAMING":
|
|
62
70
|
return CapabilityType.CAPABILITY_TYPE_STREAMING;
|
|
63
|
-
case
|
|
71
|
+
case 4:
|
|
64
72
|
case "CAPABILITY_TYPE_FUNCTION_CALLING":
|
|
65
73
|
return CapabilityType.CAPABILITY_TYPE_FUNCTION_CALLING;
|
|
66
|
-
case
|
|
74
|
+
case 5:
|
|
67
75
|
case "CAPABILITY_TYPE_VISION":
|
|
68
76
|
return CapabilityType.CAPABILITY_TYPE_VISION;
|
|
69
|
-
case
|
|
77
|
+
case 6:
|
|
70
78
|
case "CAPABILITY_TYPE_TOOL_USE":
|
|
71
79
|
return CapabilityType.CAPABILITY_TYPE_TOOL_USE;
|
|
72
|
-
case
|
|
80
|
+
case 7:
|
|
73
81
|
case "CAPABILITY_TYPE_SYSTEM_PROMPT":
|
|
74
82
|
return CapabilityType.CAPABILITY_TYPE_SYSTEM_PROMPT;
|
|
75
|
-
case
|
|
83
|
+
case 8:
|
|
76
84
|
case "CAPABILITY_TYPE_CACHING":
|
|
77
85
|
return CapabilityType.CAPABILITY_TYPE_CACHING;
|
|
78
|
-
case
|
|
86
|
+
case 9:
|
|
79
87
|
case "CAPABILITY_TYPE_REASONING":
|
|
80
88
|
return CapabilityType.CAPABILITY_TYPE_REASONING;
|
|
81
|
-
case
|
|
89
|
+
case 10:
|
|
82
90
|
case "CAPABILITY_TYPE_AUDIO":
|
|
83
91
|
return CapabilityType.CAPABILITY_TYPE_AUDIO;
|
|
84
|
-
case
|
|
92
|
+
case 11:
|
|
85
93
|
case "CAPABILITY_TYPE_VIDEO":
|
|
86
94
|
return CapabilityType.CAPABILITY_TYPE_VIDEO;
|
|
87
|
-
case
|
|
95
|
+
case 12:
|
|
88
96
|
case "CAPABILITY_TYPE_EMBEDDINGS":
|
|
89
97
|
return CapabilityType.CAPABILITY_TYPE_EMBEDDINGS;
|
|
90
|
-
case
|
|
98
|
+
case 13:
|
|
91
99
|
case "CAPABILITY_TYPE_FINE_TUNING":
|
|
92
100
|
return CapabilityType.CAPABILITY_TYPE_FINE_TUNING;
|
|
93
101
|
case -1:
|
|
@@ -100,6 +108,8 @@ function capabilityTypeToJSON(object) {
|
|
|
100
108
|
switch (object) {
|
|
101
109
|
case CapabilityType.CAPABILITY_TYPE_UNSPECIFIED:
|
|
102
110
|
return "CAPABILITY_TYPE_UNSPECIFIED";
|
|
111
|
+
case CapabilityType.CAPABILITY_TYPE_TEXT:
|
|
112
|
+
return "CAPABILITY_TYPE_TEXT";
|
|
103
113
|
case CapabilityType.CAPABILITY_TYPE_STRUCTURED_RESPONSE:
|
|
104
114
|
return "CAPABILITY_TYPE_STRUCTURED_RESPONSE";
|
|
105
115
|
case CapabilityType.CAPABILITY_TYPE_STREAMING:
|
|
@@ -815,10 +825,58 @@ function hyperparameterToJSON(object) {
|
|
|
815
825
|
return "UNRECOGNIZED";
|
|
816
826
|
}
|
|
817
827
|
}
|
|
828
|
+
/** Modality direction - whether a modality supports input, output, or both */
|
|
829
|
+
var ModalityDirection;
|
|
830
|
+
(function (ModalityDirection) {
|
|
831
|
+
ModalityDirection[ModalityDirection["MODALITY_DIRECTION_UNSPECIFIED"] = 0] = "MODALITY_DIRECTION_UNSPECIFIED";
|
|
832
|
+
/** MODALITY_DIRECTION_INPUT_ONLY - Can only process/analyze (e.g., image analysis) */
|
|
833
|
+
ModalityDirection[ModalityDirection["MODALITY_DIRECTION_INPUT_ONLY"] = 1] = "MODALITY_DIRECTION_INPUT_ONLY";
|
|
834
|
+
/** MODALITY_DIRECTION_OUTPUT_ONLY - Can only generate (e.g., TTS without STT) */
|
|
835
|
+
ModalityDirection[ModalityDirection["MODALITY_DIRECTION_OUTPUT_ONLY"] = 2] = "MODALITY_DIRECTION_OUTPUT_ONLY";
|
|
836
|
+
/** MODALITY_DIRECTION_INPUT_OUTPUT - Can both process and generate */
|
|
837
|
+
ModalityDirection[ModalityDirection["MODALITY_DIRECTION_INPUT_OUTPUT"] = 3] = "MODALITY_DIRECTION_INPUT_OUTPUT";
|
|
838
|
+
ModalityDirection[ModalityDirection["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
839
|
+
})(ModalityDirection || (exports.ModalityDirection = ModalityDirection = {}));
|
|
840
|
+
function modalityDirectionFromJSON(object) {
|
|
841
|
+
switch (object) {
|
|
842
|
+
case 0:
|
|
843
|
+
case "MODALITY_DIRECTION_UNSPECIFIED":
|
|
844
|
+
return ModalityDirection.MODALITY_DIRECTION_UNSPECIFIED;
|
|
845
|
+
case 1:
|
|
846
|
+
case "MODALITY_DIRECTION_INPUT_ONLY":
|
|
847
|
+
return ModalityDirection.MODALITY_DIRECTION_INPUT_ONLY;
|
|
848
|
+
case 2:
|
|
849
|
+
case "MODALITY_DIRECTION_OUTPUT_ONLY":
|
|
850
|
+
return ModalityDirection.MODALITY_DIRECTION_OUTPUT_ONLY;
|
|
851
|
+
case 3:
|
|
852
|
+
case "MODALITY_DIRECTION_INPUT_OUTPUT":
|
|
853
|
+
return ModalityDirection.MODALITY_DIRECTION_INPUT_OUTPUT;
|
|
854
|
+
case -1:
|
|
855
|
+
case "UNRECOGNIZED":
|
|
856
|
+
default:
|
|
857
|
+
return ModalityDirection.UNRECOGNIZED;
|
|
858
|
+
}
|
|
859
|
+
}
|
|
860
|
+
function modalityDirectionToJSON(object) {
|
|
861
|
+
switch (object) {
|
|
862
|
+
case ModalityDirection.MODALITY_DIRECTION_UNSPECIFIED:
|
|
863
|
+
return "MODALITY_DIRECTION_UNSPECIFIED";
|
|
864
|
+
case ModalityDirection.MODALITY_DIRECTION_INPUT_ONLY:
|
|
865
|
+
return "MODALITY_DIRECTION_INPUT_ONLY";
|
|
866
|
+
case ModalityDirection.MODALITY_DIRECTION_OUTPUT_ONLY:
|
|
867
|
+
return "MODALITY_DIRECTION_OUTPUT_ONLY";
|
|
868
|
+
case ModalityDirection.MODALITY_DIRECTION_INPUT_OUTPUT:
|
|
869
|
+
return "MODALITY_DIRECTION_INPUT_OUTPUT";
|
|
870
|
+
case ModalityDirection.UNRECOGNIZED:
|
|
871
|
+
default:
|
|
872
|
+
return "UNRECOGNIZED";
|
|
873
|
+
}
|
|
874
|
+
}
|
|
818
875
|
function createBaseCapability() {
|
|
819
876
|
return {
|
|
820
877
|
type: 0,
|
|
821
878
|
enabled: false,
|
|
879
|
+
text: undefined,
|
|
822
880
|
structuredResponse: undefined,
|
|
823
881
|
streaming: undefined,
|
|
824
882
|
functionCalling: undefined,
|
|
@@ -831,6 +889,7 @@ function createBaseCapability() {
|
|
|
831
889
|
video: undefined,
|
|
832
890
|
embeddings: undefined,
|
|
833
891
|
fineTuning: undefined,
|
|
892
|
+
additionalInfo: "",
|
|
834
893
|
};
|
|
835
894
|
}
|
|
836
895
|
exports.Capability = {
|
|
@@ -841,41 +900,47 @@ exports.Capability = {
|
|
|
841
900
|
if (message.enabled !== false) {
|
|
842
901
|
writer.uint32(16).bool(message.enabled);
|
|
843
902
|
}
|
|
903
|
+
if (message.text !== undefined) {
|
|
904
|
+
exports.Text.encode(message.text, writer.uint32(26).fork()).join();
|
|
905
|
+
}
|
|
844
906
|
if (message.structuredResponse !== undefined) {
|
|
845
|
-
exports.StructuredResponse.encode(message.structuredResponse, writer.uint32(
|
|
907
|
+
exports.StructuredResponse.encode(message.structuredResponse, writer.uint32(34).fork()).join();
|
|
846
908
|
}
|
|
847
909
|
if (message.streaming !== undefined) {
|
|
848
|
-
exports.Streaming.encode(message.streaming, writer.uint32(
|
|
910
|
+
exports.Streaming.encode(message.streaming, writer.uint32(42).fork()).join();
|
|
849
911
|
}
|
|
850
912
|
if (message.functionCalling !== undefined) {
|
|
851
|
-
exports.FunctionCalling.encode(message.functionCalling, writer.uint32(
|
|
913
|
+
exports.FunctionCalling.encode(message.functionCalling, writer.uint32(50).fork()).join();
|
|
852
914
|
}
|
|
853
915
|
if (message.vision !== undefined) {
|
|
854
|
-
exports.Vision.encode(message.vision, writer.uint32(
|
|
916
|
+
exports.Vision.encode(message.vision, writer.uint32(58).fork()).join();
|
|
855
917
|
}
|
|
856
918
|
if (message.toolUse !== undefined) {
|
|
857
|
-
exports.ToolUse.encode(message.toolUse, writer.uint32(
|
|
919
|
+
exports.ToolUse.encode(message.toolUse, writer.uint32(66).fork()).join();
|
|
858
920
|
}
|
|
859
921
|
if (message.systemPrompt !== undefined) {
|
|
860
|
-
exports.SystemPrompt.encode(message.systemPrompt, writer.uint32(
|
|
922
|
+
exports.SystemPrompt.encode(message.systemPrompt, writer.uint32(74).fork()).join();
|
|
861
923
|
}
|
|
862
924
|
if (message.caching !== undefined) {
|
|
863
|
-
exports.Caching.encode(message.caching, writer.uint32(
|
|
925
|
+
exports.Caching.encode(message.caching, writer.uint32(82).fork()).join();
|
|
864
926
|
}
|
|
865
927
|
if (message.reasoning !== undefined) {
|
|
866
|
-
exports.Reasoning.encode(message.reasoning, writer.uint32(
|
|
928
|
+
exports.Reasoning.encode(message.reasoning, writer.uint32(90).fork()).join();
|
|
867
929
|
}
|
|
868
930
|
if (message.audio !== undefined) {
|
|
869
|
-
exports.Audio.encode(message.audio, writer.uint32(
|
|
931
|
+
exports.Audio.encode(message.audio, writer.uint32(98).fork()).join();
|
|
870
932
|
}
|
|
871
933
|
if (message.video !== undefined) {
|
|
872
|
-
exports.Video.encode(message.video, writer.uint32(
|
|
934
|
+
exports.Video.encode(message.video, writer.uint32(106).fork()).join();
|
|
873
935
|
}
|
|
874
936
|
if (message.embeddings !== undefined) {
|
|
875
|
-
exports.Embeddings.encode(message.embeddings, writer.uint32(
|
|
937
|
+
exports.Embeddings.encode(message.embeddings, writer.uint32(114).fork()).join();
|
|
876
938
|
}
|
|
877
939
|
if (message.fineTuning !== undefined) {
|
|
878
|
-
exports.FineTuning.encode(message.fineTuning, writer.uint32(
|
|
940
|
+
exports.FineTuning.encode(message.fineTuning, writer.uint32(122).fork()).join();
|
|
941
|
+
}
|
|
942
|
+
if (message.additionalInfo !== "") {
|
|
943
|
+
writer.uint32(130).string(message.additionalInfo);
|
|
879
944
|
}
|
|
880
945
|
return writer;
|
|
881
946
|
},
|
|
@@ -904,86 +969,100 @@ exports.Capability = {
|
|
|
904
969
|
if (tag !== 26) {
|
|
905
970
|
break;
|
|
906
971
|
}
|
|
907
|
-
message.
|
|
972
|
+
message.text = exports.Text.decode(reader, reader.uint32());
|
|
908
973
|
continue;
|
|
909
974
|
}
|
|
910
975
|
case 4: {
|
|
911
976
|
if (tag !== 34) {
|
|
912
977
|
break;
|
|
913
978
|
}
|
|
914
|
-
message.
|
|
979
|
+
message.structuredResponse = exports.StructuredResponse.decode(reader, reader.uint32());
|
|
915
980
|
continue;
|
|
916
981
|
}
|
|
917
982
|
case 5: {
|
|
918
983
|
if (tag !== 42) {
|
|
919
984
|
break;
|
|
920
985
|
}
|
|
921
|
-
message.
|
|
986
|
+
message.streaming = exports.Streaming.decode(reader, reader.uint32());
|
|
922
987
|
continue;
|
|
923
988
|
}
|
|
924
989
|
case 6: {
|
|
925
990
|
if (tag !== 50) {
|
|
926
991
|
break;
|
|
927
992
|
}
|
|
928
|
-
message.
|
|
993
|
+
message.functionCalling = exports.FunctionCalling.decode(reader, reader.uint32());
|
|
929
994
|
continue;
|
|
930
995
|
}
|
|
931
996
|
case 7: {
|
|
932
997
|
if (tag !== 58) {
|
|
933
998
|
break;
|
|
934
999
|
}
|
|
935
|
-
message.
|
|
1000
|
+
message.vision = exports.Vision.decode(reader, reader.uint32());
|
|
936
1001
|
continue;
|
|
937
1002
|
}
|
|
938
1003
|
case 8: {
|
|
939
1004
|
if (tag !== 66) {
|
|
940
1005
|
break;
|
|
941
1006
|
}
|
|
942
|
-
message.
|
|
1007
|
+
message.toolUse = exports.ToolUse.decode(reader, reader.uint32());
|
|
943
1008
|
continue;
|
|
944
1009
|
}
|
|
945
1010
|
case 9: {
|
|
946
1011
|
if (tag !== 74) {
|
|
947
1012
|
break;
|
|
948
1013
|
}
|
|
949
|
-
message.
|
|
1014
|
+
message.systemPrompt = exports.SystemPrompt.decode(reader, reader.uint32());
|
|
950
1015
|
continue;
|
|
951
1016
|
}
|
|
952
1017
|
case 10: {
|
|
953
1018
|
if (tag !== 82) {
|
|
954
1019
|
break;
|
|
955
1020
|
}
|
|
956
|
-
message.
|
|
1021
|
+
message.caching = exports.Caching.decode(reader, reader.uint32());
|
|
957
1022
|
continue;
|
|
958
1023
|
}
|
|
959
1024
|
case 11: {
|
|
960
1025
|
if (tag !== 90) {
|
|
961
1026
|
break;
|
|
962
1027
|
}
|
|
963
|
-
message.
|
|
1028
|
+
message.reasoning = exports.Reasoning.decode(reader, reader.uint32());
|
|
964
1029
|
continue;
|
|
965
1030
|
}
|
|
966
1031
|
case 12: {
|
|
967
1032
|
if (tag !== 98) {
|
|
968
1033
|
break;
|
|
969
1034
|
}
|
|
970
|
-
message.
|
|
1035
|
+
message.audio = exports.Audio.decode(reader, reader.uint32());
|
|
971
1036
|
continue;
|
|
972
1037
|
}
|
|
973
1038
|
case 13: {
|
|
974
1039
|
if (tag !== 106) {
|
|
975
1040
|
break;
|
|
976
1041
|
}
|
|
977
|
-
message.
|
|
1042
|
+
message.video = exports.Video.decode(reader, reader.uint32());
|
|
978
1043
|
continue;
|
|
979
1044
|
}
|
|
980
1045
|
case 14: {
|
|
981
1046
|
if (tag !== 114) {
|
|
982
1047
|
break;
|
|
983
1048
|
}
|
|
1049
|
+
message.embeddings = exports.Embeddings.decode(reader, reader.uint32());
|
|
1050
|
+
continue;
|
|
1051
|
+
}
|
|
1052
|
+
case 15: {
|
|
1053
|
+
if (tag !== 122) {
|
|
1054
|
+
break;
|
|
1055
|
+
}
|
|
984
1056
|
message.fineTuning = exports.FineTuning.decode(reader, reader.uint32());
|
|
985
1057
|
continue;
|
|
986
1058
|
}
|
|
1059
|
+
case 16: {
|
|
1060
|
+
if (tag !== 130) {
|
|
1061
|
+
break;
|
|
1062
|
+
}
|
|
1063
|
+
message.additionalInfo = reader.string();
|
|
1064
|
+
continue;
|
|
1065
|
+
}
|
|
987
1066
|
}
|
|
988
1067
|
if ((tag & 7) === 4 || tag === 0) {
|
|
989
1068
|
break;
|
|
@@ -996,6 +1075,7 @@ exports.Capability = {
|
|
|
996
1075
|
return {
|
|
997
1076
|
type: isSet(object.type) ? capabilityTypeFromJSON(object.type) : 0,
|
|
998
1077
|
enabled: isSet(object.enabled) ? globalThis.Boolean(object.enabled) : false,
|
|
1078
|
+
text: isSet(object.text) ? exports.Text.fromJSON(object.text) : undefined,
|
|
999
1079
|
structuredResponse: isSet(object.structuredResponse)
|
|
1000
1080
|
? exports.StructuredResponse.fromJSON(object.structuredResponse)
|
|
1001
1081
|
: undefined,
|
|
@@ -1010,6 +1090,7 @@ exports.Capability = {
|
|
|
1010
1090
|
video: isSet(object.video) ? exports.Video.fromJSON(object.video) : undefined,
|
|
1011
1091
|
embeddings: isSet(object.embeddings) ? exports.Embeddings.fromJSON(object.embeddings) : undefined,
|
|
1012
1092
|
fineTuning: isSet(object.fineTuning) ? exports.FineTuning.fromJSON(object.fineTuning) : undefined,
|
|
1093
|
+
additionalInfo: isSet(object.additionalInfo) ? globalThis.String(object.additionalInfo) : "",
|
|
1013
1094
|
};
|
|
1014
1095
|
},
|
|
1015
1096
|
toJSON(message) {
|
|
@@ -1020,6 +1101,9 @@ exports.Capability = {
|
|
|
1020
1101
|
if (message.enabled !== false) {
|
|
1021
1102
|
obj.enabled = message.enabled;
|
|
1022
1103
|
}
|
|
1104
|
+
if (message.text !== undefined) {
|
|
1105
|
+
obj.text = exports.Text.toJSON(message.text);
|
|
1106
|
+
}
|
|
1023
1107
|
if (message.structuredResponse !== undefined) {
|
|
1024
1108
|
obj.structuredResponse = exports.StructuredResponse.toJSON(message.structuredResponse);
|
|
1025
1109
|
}
|
|
@@ -1056,16 +1140,20 @@ exports.Capability = {
|
|
|
1056
1140
|
if (message.fineTuning !== undefined) {
|
|
1057
1141
|
obj.fineTuning = exports.FineTuning.toJSON(message.fineTuning);
|
|
1058
1142
|
}
|
|
1143
|
+
if (message.additionalInfo !== "") {
|
|
1144
|
+
obj.additionalInfo = message.additionalInfo;
|
|
1145
|
+
}
|
|
1059
1146
|
return obj;
|
|
1060
1147
|
},
|
|
1061
1148
|
create(base) {
|
|
1062
1149
|
return exports.Capability.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
1063
1150
|
},
|
|
1064
1151
|
fromPartial(object) {
|
|
1065
|
-
var _a, _b;
|
|
1152
|
+
var _a, _b, _c;
|
|
1066
1153
|
const message = createBaseCapability();
|
|
1067
1154
|
message.type = (_a = object.type) !== null && _a !== void 0 ? _a : 0;
|
|
1068
1155
|
message.enabled = (_b = object.enabled) !== null && _b !== void 0 ? _b : false;
|
|
1156
|
+
message.text = (object.text !== undefined && object.text !== null) ? exports.Text.fromPartial(object.text) : undefined;
|
|
1069
1157
|
message.structuredResponse = (object.structuredResponse !== undefined && object.structuredResponse !== null)
|
|
1070
1158
|
? exports.StructuredResponse.fromPartial(object.structuredResponse)
|
|
1071
1159
|
: undefined;
|
|
@@ -1098,6 +1186,148 @@ exports.Capability = {
|
|
|
1098
1186
|
message.fineTuning = (object.fineTuning !== undefined && object.fineTuning !== null)
|
|
1099
1187
|
? exports.FineTuning.fromPartial(object.fineTuning)
|
|
1100
1188
|
: undefined;
|
|
1189
|
+
message.additionalInfo = (_c = object.additionalInfo) !== null && _c !== void 0 ? _c : "";
|
|
1190
|
+
return message;
|
|
1191
|
+
},
|
|
1192
|
+
};
|
|
1193
|
+
function createBaseText() {
|
|
1194
|
+
return {
|
|
1195
|
+
direction: 0,
|
|
1196
|
+
maxInputLength: 0,
|
|
1197
|
+
maxOutputLength: 0,
|
|
1198
|
+
supportedLanguages: [],
|
|
1199
|
+
supportsConversation: false,
|
|
1200
|
+
supportsContext: false,
|
|
1201
|
+
};
|
|
1202
|
+
}
|
|
1203
|
+
exports.Text = {
|
|
1204
|
+
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
1205
|
+
if (message.direction !== 0) {
|
|
1206
|
+
writer.uint32(8).int32(message.direction);
|
|
1207
|
+
}
|
|
1208
|
+
if (message.maxInputLength !== 0) {
|
|
1209
|
+
writer.uint32(16).int32(message.maxInputLength);
|
|
1210
|
+
}
|
|
1211
|
+
if (message.maxOutputLength !== 0) {
|
|
1212
|
+
writer.uint32(24).int32(message.maxOutputLength);
|
|
1213
|
+
}
|
|
1214
|
+
for (const v of message.supportedLanguages) {
|
|
1215
|
+
writer.uint32(34).string(v);
|
|
1216
|
+
}
|
|
1217
|
+
if (message.supportsConversation !== false) {
|
|
1218
|
+
writer.uint32(40).bool(message.supportsConversation);
|
|
1219
|
+
}
|
|
1220
|
+
if (message.supportsContext !== false) {
|
|
1221
|
+
writer.uint32(48).bool(message.supportsContext);
|
|
1222
|
+
}
|
|
1223
|
+
return writer;
|
|
1224
|
+
},
|
|
1225
|
+
decode(input, length) {
|
|
1226
|
+
const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
|
|
1227
|
+
let end = length === undefined ? reader.len : reader.pos + length;
|
|
1228
|
+
const message = createBaseText();
|
|
1229
|
+
while (reader.pos < end) {
|
|
1230
|
+
const tag = reader.uint32();
|
|
1231
|
+
switch (tag >>> 3) {
|
|
1232
|
+
case 1: {
|
|
1233
|
+
if (tag !== 8) {
|
|
1234
|
+
break;
|
|
1235
|
+
}
|
|
1236
|
+
message.direction = reader.int32();
|
|
1237
|
+
continue;
|
|
1238
|
+
}
|
|
1239
|
+
case 2: {
|
|
1240
|
+
if (tag !== 16) {
|
|
1241
|
+
break;
|
|
1242
|
+
}
|
|
1243
|
+
message.maxInputLength = reader.int32();
|
|
1244
|
+
continue;
|
|
1245
|
+
}
|
|
1246
|
+
case 3: {
|
|
1247
|
+
if (tag !== 24) {
|
|
1248
|
+
break;
|
|
1249
|
+
}
|
|
1250
|
+
message.maxOutputLength = reader.int32();
|
|
1251
|
+
continue;
|
|
1252
|
+
}
|
|
1253
|
+
case 4: {
|
|
1254
|
+
if (tag !== 34) {
|
|
1255
|
+
break;
|
|
1256
|
+
}
|
|
1257
|
+
message.supportedLanguages.push(reader.string());
|
|
1258
|
+
continue;
|
|
1259
|
+
}
|
|
1260
|
+
case 5: {
|
|
1261
|
+
if (tag !== 40) {
|
|
1262
|
+
break;
|
|
1263
|
+
}
|
|
1264
|
+
message.supportsConversation = reader.bool();
|
|
1265
|
+
continue;
|
|
1266
|
+
}
|
|
1267
|
+
case 6: {
|
|
1268
|
+
if (tag !== 48) {
|
|
1269
|
+
break;
|
|
1270
|
+
}
|
|
1271
|
+
message.supportsContext = reader.bool();
|
|
1272
|
+
continue;
|
|
1273
|
+
}
|
|
1274
|
+
}
|
|
1275
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
1276
|
+
break;
|
|
1277
|
+
}
|
|
1278
|
+
reader.skip(tag & 7);
|
|
1279
|
+
}
|
|
1280
|
+
return message;
|
|
1281
|
+
},
|
|
1282
|
+
fromJSON(object) {
|
|
1283
|
+
return {
|
|
1284
|
+
direction: isSet(object.direction) ? modalityDirectionFromJSON(object.direction) : 0,
|
|
1285
|
+
maxInputLength: isSet(object.maxInputLength) ? globalThis.Number(object.maxInputLength) : 0,
|
|
1286
|
+
maxOutputLength: isSet(object.maxOutputLength) ? globalThis.Number(object.maxOutputLength) : 0,
|
|
1287
|
+
supportedLanguages: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.supportedLanguages)
|
|
1288
|
+
? object.supportedLanguages.map((e) => globalThis.String(e))
|
|
1289
|
+
: [],
|
|
1290
|
+
supportsConversation: isSet(object.supportsConversation)
|
|
1291
|
+
? globalThis.Boolean(object.supportsConversation)
|
|
1292
|
+
: false,
|
|
1293
|
+
supportsContext: isSet(object.supportsContext) ? globalThis.Boolean(object.supportsContext) : false,
|
|
1294
|
+
};
|
|
1295
|
+
},
|
|
1296
|
+
toJSON(message) {
|
|
1297
|
+
var _a;
|
|
1298
|
+
const obj = {};
|
|
1299
|
+
if (message.direction !== 0) {
|
|
1300
|
+
obj.direction = modalityDirectionToJSON(message.direction);
|
|
1301
|
+
}
|
|
1302
|
+
if (message.maxInputLength !== 0) {
|
|
1303
|
+
obj.maxInputLength = Math.round(message.maxInputLength);
|
|
1304
|
+
}
|
|
1305
|
+
if (message.maxOutputLength !== 0) {
|
|
1306
|
+
obj.maxOutputLength = Math.round(message.maxOutputLength);
|
|
1307
|
+
}
|
|
1308
|
+
if ((_a = message.supportedLanguages) === null || _a === void 0 ? void 0 : _a.length) {
|
|
1309
|
+
obj.supportedLanguages = message.supportedLanguages;
|
|
1310
|
+
}
|
|
1311
|
+
if (message.supportsConversation !== false) {
|
|
1312
|
+
obj.supportsConversation = message.supportsConversation;
|
|
1313
|
+
}
|
|
1314
|
+
if (message.supportsContext !== false) {
|
|
1315
|
+
obj.supportsContext = message.supportsContext;
|
|
1316
|
+
}
|
|
1317
|
+
return obj;
|
|
1318
|
+
},
|
|
1319
|
+
create(base) {
|
|
1320
|
+
return exports.Text.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
1321
|
+
},
|
|
1322
|
+
fromPartial(object) {
|
|
1323
|
+
var _a, _b, _c, _d, _e, _f;
|
|
1324
|
+
const message = createBaseText();
|
|
1325
|
+
message.direction = (_a = object.direction) !== null && _a !== void 0 ? _a : 0;
|
|
1326
|
+
message.maxInputLength = (_b = object.maxInputLength) !== null && _b !== void 0 ? _b : 0;
|
|
1327
|
+
message.maxOutputLength = (_c = object.maxOutputLength) !== null && _c !== void 0 ? _c : 0;
|
|
1328
|
+
message.supportedLanguages = ((_d = object.supportedLanguages) === null || _d === void 0 ? void 0 : _d.map((e) => e)) || [];
|
|
1329
|
+
message.supportsConversation = (_e = object.supportsConversation) !== null && _e !== void 0 ? _e : false;
|
|
1330
|
+
message.supportsContext = (_f = object.supportsContext) !== null && _f !== void 0 ? _f : false;
|
|
1101
1331
|
return message;
|
|
1102
1332
|
},
|
|
1103
1333
|
};
|
|
@@ -1594,47 +1824,47 @@ exports.FunctionCalling = {
|
|
|
1594
1824
|
};
|
|
1595
1825
|
function createBaseVision() {
|
|
1596
1826
|
return {
|
|
1827
|
+
direction: 0,
|
|
1597
1828
|
supportedFormats: [],
|
|
1598
1829
|
maxImageSizeBytes: 0,
|
|
1599
1830
|
maxImagesPerRequest: 0,
|
|
1600
|
-
supportsImageGeneration: false,
|
|
1601
|
-
supportsVideoFrames: false,
|
|
1602
1831
|
maxResolutionWidth: 0,
|
|
1603
1832
|
maxResolutionHeight: 0,
|
|
1604
1833
|
supportsOcr: false,
|
|
1605
1834
|
supportsObjectDetection: false,
|
|
1835
|
+
supportsVideoFrames: false,
|
|
1606
1836
|
};
|
|
1607
1837
|
}
|
|
1608
1838
|
exports.Vision = {
|
|
1609
1839
|
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
1610
|
-
|
|
1840
|
+
if (message.direction !== 0) {
|
|
1841
|
+
writer.uint32(8).int32(message.direction);
|
|
1842
|
+
}
|
|
1843
|
+
writer.uint32(18).fork();
|
|
1611
1844
|
for (const v of message.supportedFormats) {
|
|
1612
1845
|
writer.int32(v);
|
|
1613
1846
|
}
|
|
1614
1847
|
writer.join();
|
|
1615
1848
|
if (message.maxImageSizeBytes !== 0) {
|
|
1616
|
-
writer.uint32(
|
|
1849
|
+
writer.uint32(24).int64(message.maxImageSizeBytes);
|
|
1617
1850
|
}
|
|
1618
1851
|
if (message.maxImagesPerRequest !== 0) {
|
|
1619
|
-
writer.uint32(
|
|
1620
|
-
}
|
|
1621
|
-
if (message.supportsImageGeneration !== false) {
|
|
1622
|
-
writer.uint32(32).bool(message.supportsImageGeneration);
|
|
1623
|
-
}
|
|
1624
|
-
if (message.supportsVideoFrames !== false) {
|
|
1625
|
-
writer.uint32(40).bool(message.supportsVideoFrames);
|
|
1852
|
+
writer.uint32(32).int32(message.maxImagesPerRequest);
|
|
1626
1853
|
}
|
|
1627
1854
|
if (message.maxResolutionWidth !== 0) {
|
|
1628
|
-
writer.uint32(
|
|
1855
|
+
writer.uint32(40).int32(message.maxResolutionWidth);
|
|
1629
1856
|
}
|
|
1630
1857
|
if (message.maxResolutionHeight !== 0) {
|
|
1631
|
-
writer.uint32(
|
|
1858
|
+
writer.uint32(48).int32(message.maxResolutionHeight);
|
|
1632
1859
|
}
|
|
1633
1860
|
if (message.supportsOcr !== false) {
|
|
1634
|
-
writer.uint32(
|
|
1861
|
+
writer.uint32(56).bool(message.supportsOcr);
|
|
1635
1862
|
}
|
|
1636
1863
|
if (message.supportsObjectDetection !== false) {
|
|
1637
|
-
writer.uint32(
|
|
1864
|
+
writer.uint32(64).bool(message.supportsObjectDetection);
|
|
1865
|
+
}
|
|
1866
|
+
if (message.supportsVideoFrames !== false) {
|
|
1867
|
+
writer.uint32(72).bool(message.supportsVideoFrames);
|
|
1638
1868
|
}
|
|
1639
1869
|
return writer;
|
|
1640
1870
|
},
|
|
@@ -1646,11 +1876,18 @@ exports.Vision = {
|
|
|
1646
1876
|
const tag = reader.uint32();
|
|
1647
1877
|
switch (tag >>> 3) {
|
|
1648
1878
|
case 1: {
|
|
1649
|
-
if (tag
|
|
1879
|
+
if (tag !== 8) {
|
|
1880
|
+
break;
|
|
1881
|
+
}
|
|
1882
|
+
message.direction = reader.int32();
|
|
1883
|
+
continue;
|
|
1884
|
+
}
|
|
1885
|
+
case 2: {
|
|
1886
|
+
if (tag === 16) {
|
|
1650
1887
|
message.supportedFormats.push(reader.int32());
|
|
1651
1888
|
continue;
|
|
1652
1889
|
}
|
|
1653
|
-
if (tag ===
|
|
1890
|
+
if (tag === 18) {
|
|
1654
1891
|
const end2 = reader.uint32() + reader.pos;
|
|
1655
1892
|
while (reader.pos < end2) {
|
|
1656
1893
|
message.supportedFormats.push(reader.int32());
|
|
@@ -1659,60 +1896,53 @@ exports.Vision = {
|
|
|
1659
1896
|
}
|
|
1660
1897
|
break;
|
|
1661
1898
|
}
|
|
1662
|
-
case 2: {
|
|
1663
|
-
if (tag !== 16) {
|
|
1664
|
-
break;
|
|
1665
|
-
}
|
|
1666
|
-
message.maxImageSizeBytes = longToNumber(reader.int64());
|
|
1667
|
-
continue;
|
|
1668
|
-
}
|
|
1669
1899
|
case 3: {
|
|
1670
1900
|
if (tag !== 24) {
|
|
1671
1901
|
break;
|
|
1672
1902
|
}
|
|
1673
|
-
message.
|
|
1903
|
+
message.maxImageSizeBytes = longToNumber(reader.int64());
|
|
1674
1904
|
continue;
|
|
1675
1905
|
}
|
|
1676
1906
|
case 4: {
|
|
1677
1907
|
if (tag !== 32) {
|
|
1678
1908
|
break;
|
|
1679
1909
|
}
|
|
1680
|
-
message.
|
|
1910
|
+
message.maxImagesPerRequest = reader.int32();
|
|
1681
1911
|
continue;
|
|
1682
1912
|
}
|
|
1683
1913
|
case 5: {
|
|
1684
1914
|
if (tag !== 40) {
|
|
1685
1915
|
break;
|
|
1686
1916
|
}
|
|
1687
|
-
message.
|
|
1917
|
+
message.maxResolutionWidth = reader.int32();
|
|
1688
1918
|
continue;
|
|
1689
1919
|
}
|
|
1690
1920
|
case 6: {
|
|
1691
1921
|
if (tag !== 48) {
|
|
1692
1922
|
break;
|
|
1693
1923
|
}
|
|
1694
|
-
message.
|
|
1924
|
+
message.maxResolutionHeight = reader.int32();
|
|
1695
1925
|
continue;
|
|
1696
1926
|
}
|
|
1697
1927
|
case 7: {
|
|
1698
1928
|
if (tag !== 56) {
|
|
1699
1929
|
break;
|
|
1700
1930
|
}
|
|
1701
|
-
message.
|
|
1931
|
+
message.supportsOcr = reader.bool();
|
|
1702
1932
|
continue;
|
|
1703
1933
|
}
|
|
1704
1934
|
case 8: {
|
|
1705
1935
|
if (tag !== 64) {
|
|
1706
1936
|
break;
|
|
1707
1937
|
}
|
|
1708
|
-
message.
|
|
1938
|
+
message.supportsObjectDetection = reader.bool();
|
|
1709
1939
|
continue;
|
|
1710
1940
|
}
|
|
1711
1941
|
case 9: {
|
|
1712
1942
|
if (tag !== 72) {
|
|
1713
1943
|
break;
|
|
1714
1944
|
}
|
|
1715
|
-
message.
|
|
1945
|
+
message.supportsVideoFrames = reader.bool();
|
|
1716
1946
|
continue;
|
|
1717
1947
|
}
|
|
1718
1948
|
}
|
|
@@ -1725,26 +1955,27 @@ exports.Vision = {
|
|
|
1725
1955
|
},
|
|
1726
1956
|
fromJSON(object) {
|
|
1727
1957
|
return {
|
|
1958
|
+
direction: isSet(object.direction) ? modalityDirectionFromJSON(object.direction) : 0,
|
|
1728
1959
|
supportedFormats: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.supportedFormats)
|
|
1729
1960
|
? object.supportedFormats.map((e) => imageFormatFromJSON(e))
|
|
1730
1961
|
: [],
|
|
1731
1962
|
maxImageSizeBytes: isSet(object.maxImageSizeBytes) ? globalThis.Number(object.maxImageSizeBytes) : 0,
|
|
1732
1963
|
maxImagesPerRequest: isSet(object.maxImagesPerRequest) ? globalThis.Number(object.maxImagesPerRequest) : 0,
|
|
1733
|
-
supportsImageGeneration: isSet(object.supportsImageGeneration)
|
|
1734
|
-
? globalThis.Boolean(object.supportsImageGeneration)
|
|
1735
|
-
: false,
|
|
1736
|
-
supportsVideoFrames: isSet(object.supportsVideoFrames) ? globalThis.Boolean(object.supportsVideoFrames) : false,
|
|
1737
1964
|
maxResolutionWidth: isSet(object.maxResolutionWidth) ? globalThis.Number(object.maxResolutionWidth) : 0,
|
|
1738
1965
|
maxResolutionHeight: isSet(object.maxResolutionHeight) ? globalThis.Number(object.maxResolutionHeight) : 0,
|
|
1739
1966
|
supportsOcr: isSet(object.supportsOcr) ? globalThis.Boolean(object.supportsOcr) : false,
|
|
1740
1967
|
supportsObjectDetection: isSet(object.supportsObjectDetection)
|
|
1741
1968
|
? globalThis.Boolean(object.supportsObjectDetection)
|
|
1742
1969
|
: false,
|
|
1970
|
+
supportsVideoFrames: isSet(object.supportsVideoFrames) ? globalThis.Boolean(object.supportsVideoFrames) : false,
|
|
1743
1971
|
};
|
|
1744
1972
|
},
|
|
1745
1973
|
toJSON(message) {
|
|
1746
1974
|
var _a;
|
|
1747
1975
|
const obj = {};
|
|
1976
|
+
if (message.direction !== 0) {
|
|
1977
|
+
obj.direction = modalityDirectionToJSON(message.direction);
|
|
1978
|
+
}
|
|
1748
1979
|
if ((_a = message.supportedFormats) === null || _a === void 0 ? void 0 : _a.length) {
|
|
1749
1980
|
obj.supportedFormats = message.supportedFormats.map((e) => imageFormatToJSON(e));
|
|
1750
1981
|
}
|
|
@@ -1754,12 +1985,6 @@ exports.Vision = {
|
|
|
1754
1985
|
if (message.maxImagesPerRequest !== 0) {
|
|
1755
1986
|
obj.maxImagesPerRequest = Math.round(message.maxImagesPerRequest);
|
|
1756
1987
|
}
|
|
1757
|
-
if (message.supportsImageGeneration !== false) {
|
|
1758
|
-
obj.supportsImageGeneration = message.supportsImageGeneration;
|
|
1759
|
-
}
|
|
1760
|
-
if (message.supportsVideoFrames !== false) {
|
|
1761
|
-
obj.supportsVideoFrames = message.supportsVideoFrames;
|
|
1762
|
-
}
|
|
1763
1988
|
if (message.maxResolutionWidth !== 0) {
|
|
1764
1989
|
obj.maxResolutionWidth = Math.round(message.maxResolutionWidth);
|
|
1765
1990
|
}
|
|
@@ -1772,6 +1997,9 @@ exports.Vision = {
|
|
|
1772
1997
|
if (message.supportsObjectDetection !== false) {
|
|
1773
1998
|
obj.supportsObjectDetection = message.supportsObjectDetection;
|
|
1774
1999
|
}
|
|
2000
|
+
if (message.supportsVideoFrames !== false) {
|
|
2001
|
+
obj.supportsVideoFrames = message.supportsVideoFrames;
|
|
2002
|
+
}
|
|
1775
2003
|
return obj;
|
|
1776
2004
|
},
|
|
1777
2005
|
create(base) {
|
|
@@ -1780,15 +2008,15 @@ exports.Vision = {
|
|
|
1780
2008
|
fromPartial(object) {
|
|
1781
2009
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
1782
2010
|
const message = createBaseVision();
|
|
1783
|
-
message.
|
|
1784
|
-
message.
|
|
1785
|
-
message.
|
|
1786
|
-
message.
|
|
1787
|
-
message.
|
|
1788
|
-
message.
|
|
1789
|
-
message.
|
|
1790
|
-
message.
|
|
1791
|
-
message.
|
|
2011
|
+
message.direction = (_a = object.direction) !== null && _a !== void 0 ? _a : 0;
|
|
2012
|
+
message.supportedFormats = ((_b = object.supportedFormats) === null || _b === void 0 ? void 0 : _b.map((e) => e)) || [];
|
|
2013
|
+
message.maxImageSizeBytes = (_c = object.maxImageSizeBytes) !== null && _c !== void 0 ? _c : 0;
|
|
2014
|
+
message.maxImagesPerRequest = (_d = object.maxImagesPerRequest) !== null && _d !== void 0 ? _d : 0;
|
|
2015
|
+
message.maxResolutionWidth = (_e = object.maxResolutionWidth) !== null && _e !== void 0 ? _e : 0;
|
|
2016
|
+
message.maxResolutionHeight = (_f = object.maxResolutionHeight) !== null && _f !== void 0 ? _f : 0;
|
|
2017
|
+
message.supportsOcr = (_g = object.supportsOcr) !== null && _g !== void 0 ? _g : false;
|
|
2018
|
+
message.supportsObjectDetection = (_h = object.supportsObjectDetection) !== null && _h !== void 0 ? _h : false;
|
|
2019
|
+
message.supportsVideoFrames = (_j = object.supportsVideoFrames) !== null && _j !== void 0 ? _j : false;
|
|
1792
2020
|
return message;
|
|
1793
2021
|
},
|
|
1794
2022
|
};
|
|
@@ -2297,35 +2525,39 @@ exports.Reasoning = {
|
|
|
2297
2525
|
};
|
|
2298
2526
|
function createBaseAudio() {
|
|
2299
2527
|
return {
|
|
2528
|
+
direction: 0,
|
|
2300
2529
|
supportedFormats: [],
|
|
2301
2530
|
maxDurationSeconds: 0,
|
|
2302
2531
|
maxFileSizeBytes: 0,
|
|
2303
|
-
supportsTranscription: false,
|
|
2304
|
-
supportsGeneration: false,
|
|
2305
2532
|
supportedLanguages: [],
|
|
2533
|
+
supportsStreaming: false,
|
|
2534
|
+
supportsVoiceSelection: false,
|
|
2306
2535
|
};
|
|
2307
2536
|
}
|
|
2308
2537
|
exports.Audio = {
|
|
2309
2538
|
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
2310
|
-
|
|
2539
|
+
if (message.direction !== 0) {
|
|
2540
|
+
writer.uint32(8).int32(message.direction);
|
|
2541
|
+
}
|
|
2542
|
+
writer.uint32(18).fork();
|
|
2311
2543
|
for (const v of message.supportedFormats) {
|
|
2312
2544
|
writer.int32(v);
|
|
2313
2545
|
}
|
|
2314
2546
|
writer.join();
|
|
2315
2547
|
if (message.maxDurationSeconds !== 0) {
|
|
2316
|
-
writer.uint32(
|
|
2548
|
+
writer.uint32(24).int32(message.maxDurationSeconds);
|
|
2317
2549
|
}
|
|
2318
2550
|
if (message.maxFileSizeBytes !== 0) {
|
|
2319
|
-
writer.uint32(
|
|
2551
|
+
writer.uint32(32).int64(message.maxFileSizeBytes);
|
|
2320
2552
|
}
|
|
2321
|
-
|
|
2322
|
-
writer.uint32(
|
|
2553
|
+
for (const v of message.supportedLanguages) {
|
|
2554
|
+
writer.uint32(42).string(v);
|
|
2323
2555
|
}
|
|
2324
|
-
if (message.
|
|
2325
|
-
writer.uint32(
|
|
2556
|
+
if (message.supportsStreaming !== false) {
|
|
2557
|
+
writer.uint32(48).bool(message.supportsStreaming);
|
|
2326
2558
|
}
|
|
2327
|
-
|
|
2328
|
-
writer.uint32(
|
|
2559
|
+
if (message.supportsVoiceSelection !== false) {
|
|
2560
|
+
writer.uint32(56).bool(message.supportsVoiceSelection);
|
|
2329
2561
|
}
|
|
2330
2562
|
return writer;
|
|
2331
2563
|
},
|
|
@@ -2337,11 +2569,18 @@ exports.Audio = {
|
|
|
2337
2569
|
const tag = reader.uint32();
|
|
2338
2570
|
switch (tag >>> 3) {
|
|
2339
2571
|
case 1: {
|
|
2340
|
-
if (tag
|
|
2572
|
+
if (tag !== 8) {
|
|
2573
|
+
break;
|
|
2574
|
+
}
|
|
2575
|
+
message.direction = reader.int32();
|
|
2576
|
+
continue;
|
|
2577
|
+
}
|
|
2578
|
+
case 2: {
|
|
2579
|
+
if (tag === 16) {
|
|
2341
2580
|
message.supportedFormats.push(reader.int32());
|
|
2342
2581
|
continue;
|
|
2343
2582
|
}
|
|
2344
|
-
if (tag ===
|
|
2583
|
+
if (tag === 18) {
|
|
2345
2584
|
const end2 = reader.uint32() + reader.pos;
|
|
2346
2585
|
while (reader.pos < end2) {
|
|
2347
2586
|
message.supportedFormats.push(reader.int32());
|
|
@@ -2350,39 +2589,39 @@ exports.Audio = {
|
|
|
2350
2589
|
}
|
|
2351
2590
|
break;
|
|
2352
2591
|
}
|
|
2353
|
-
case 2: {
|
|
2354
|
-
if (tag !== 16) {
|
|
2355
|
-
break;
|
|
2356
|
-
}
|
|
2357
|
-
message.maxDurationSeconds = reader.int32();
|
|
2358
|
-
continue;
|
|
2359
|
-
}
|
|
2360
2592
|
case 3: {
|
|
2361
2593
|
if (tag !== 24) {
|
|
2362
2594
|
break;
|
|
2363
2595
|
}
|
|
2364
|
-
message.
|
|
2596
|
+
message.maxDurationSeconds = reader.int32();
|
|
2365
2597
|
continue;
|
|
2366
2598
|
}
|
|
2367
2599
|
case 4: {
|
|
2368
2600
|
if (tag !== 32) {
|
|
2369
2601
|
break;
|
|
2370
2602
|
}
|
|
2371
|
-
message.
|
|
2603
|
+
message.maxFileSizeBytes = longToNumber(reader.int64());
|
|
2372
2604
|
continue;
|
|
2373
2605
|
}
|
|
2374
2606
|
case 5: {
|
|
2375
|
-
if (tag !==
|
|
2607
|
+
if (tag !== 42) {
|
|
2376
2608
|
break;
|
|
2377
2609
|
}
|
|
2378
|
-
message.
|
|
2610
|
+
message.supportedLanguages.push(reader.string());
|
|
2379
2611
|
continue;
|
|
2380
2612
|
}
|
|
2381
2613
|
case 6: {
|
|
2382
|
-
if (tag !==
|
|
2614
|
+
if (tag !== 48) {
|
|
2383
2615
|
break;
|
|
2384
2616
|
}
|
|
2385
|
-
message.
|
|
2617
|
+
message.supportsStreaming = reader.bool();
|
|
2618
|
+
continue;
|
|
2619
|
+
}
|
|
2620
|
+
case 7: {
|
|
2621
|
+
if (tag !== 56) {
|
|
2622
|
+
break;
|
|
2623
|
+
}
|
|
2624
|
+
message.supportsVoiceSelection = reader.bool();
|
|
2386
2625
|
continue;
|
|
2387
2626
|
}
|
|
2388
2627
|
}
|
|
@@ -2395,23 +2634,27 @@ exports.Audio = {
|
|
|
2395
2634
|
},
|
|
2396
2635
|
fromJSON(object) {
|
|
2397
2636
|
return {
|
|
2637
|
+
direction: isSet(object.direction) ? modalityDirectionFromJSON(object.direction) : 0,
|
|
2398
2638
|
supportedFormats: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.supportedFormats)
|
|
2399
2639
|
? object.supportedFormats.map((e) => audioFormatFromJSON(e))
|
|
2400
2640
|
: [],
|
|
2401
2641
|
maxDurationSeconds: isSet(object.maxDurationSeconds) ? globalThis.Number(object.maxDurationSeconds) : 0,
|
|
2402
2642
|
maxFileSizeBytes: isSet(object.maxFileSizeBytes) ? globalThis.Number(object.maxFileSizeBytes) : 0,
|
|
2403
|
-
supportsTranscription: isSet(object.supportsTranscription)
|
|
2404
|
-
? globalThis.Boolean(object.supportsTranscription)
|
|
2405
|
-
: false,
|
|
2406
|
-
supportsGeneration: isSet(object.supportsGeneration) ? globalThis.Boolean(object.supportsGeneration) : false,
|
|
2407
2643
|
supportedLanguages: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.supportedLanguages)
|
|
2408
2644
|
? object.supportedLanguages.map((e) => globalThis.String(e))
|
|
2409
2645
|
: [],
|
|
2646
|
+
supportsStreaming: isSet(object.supportsStreaming) ? globalThis.Boolean(object.supportsStreaming) : false,
|
|
2647
|
+
supportsVoiceSelection: isSet(object.supportsVoiceSelection)
|
|
2648
|
+
? globalThis.Boolean(object.supportsVoiceSelection)
|
|
2649
|
+
: false,
|
|
2410
2650
|
};
|
|
2411
2651
|
},
|
|
2412
2652
|
toJSON(message) {
|
|
2413
2653
|
var _a, _b;
|
|
2414
2654
|
const obj = {};
|
|
2655
|
+
if (message.direction !== 0) {
|
|
2656
|
+
obj.direction = modalityDirectionToJSON(message.direction);
|
|
2657
|
+
}
|
|
2415
2658
|
if ((_a = message.supportedFormats) === null || _a === void 0 ? void 0 : _a.length) {
|
|
2416
2659
|
obj.supportedFormats = message.supportedFormats.map((e) => audioFormatToJSON(e));
|
|
2417
2660
|
}
|
|
@@ -2421,59 +2664,68 @@ exports.Audio = {
|
|
|
2421
2664
|
if (message.maxFileSizeBytes !== 0) {
|
|
2422
2665
|
obj.maxFileSizeBytes = Math.round(message.maxFileSizeBytes);
|
|
2423
2666
|
}
|
|
2424
|
-
if (message.supportsTranscription !== false) {
|
|
2425
|
-
obj.supportsTranscription = message.supportsTranscription;
|
|
2426
|
-
}
|
|
2427
|
-
if (message.supportsGeneration !== false) {
|
|
2428
|
-
obj.supportsGeneration = message.supportsGeneration;
|
|
2429
|
-
}
|
|
2430
2667
|
if ((_b = message.supportedLanguages) === null || _b === void 0 ? void 0 : _b.length) {
|
|
2431
2668
|
obj.supportedLanguages = message.supportedLanguages;
|
|
2432
2669
|
}
|
|
2670
|
+
if (message.supportsStreaming !== false) {
|
|
2671
|
+
obj.supportsStreaming = message.supportsStreaming;
|
|
2672
|
+
}
|
|
2673
|
+
if (message.supportsVoiceSelection !== false) {
|
|
2674
|
+
obj.supportsVoiceSelection = message.supportsVoiceSelection;
|
|
2675
|
+
}
|
|
2433
2676
|
return obj;
|
|
2434
2677
|
},
|
|
2435
2678
|
create(base) {
|
|
2436
2679
|
return exports.Audio.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
2437
2680
|
},
|
|
2438
2681
|
fromPartial(object) {
|
|
2439
|
-
var _a, _b, _c, _d, _e, _f;
|
|
2682
|
+
var _a, _b, _c, _d, _e, _f, _g;
|
|
2440
2683
|
const message = createBaseAudio();
|
|
2441
|
-
message.
|
|
2442
|
-
message.
|
|
2443
|
-
message.
|
|
2444
|
-
message.
|
|
2445
|
-
message.
|
|
2446
|
-
message.
|
|
2684
|
+
message.direction = (_a = object.direction) !== null && _a !== void 0 ? _a : 0;
|
|
2685
|
+
message.supportedFormats = ((_b = object.supportedFormats) === null || _b === void 0 ? void 0 : _b.map((e) => e)) || [];
|
|
2686
|
+
message.maxDurationSeconds = (_c = object.maxDurationSeconds) !== null && _c !== void 0 ? _c : 0;
|
|
2687
|
+
message.maxFileSizeBytes = (_d = object.maxFileSizeBytes) !== null && _d !== void 0 ? _d : 0;
|
|
2688
|
+
message.supportedLanguages = ((_e = object.supportedLanguages) === null || _e === void 0 ? void 0 : _e.map((e) => e)) || [];
|
|
2689
|
+
message.supportsStreaming = (_f = object.supportsStreaming) !== null && _f !== void 0 ? _f : false;
|
|
2690
|
+
message.supportsVoiceSelection = (_g = object.supportsVoiceSelection) !== null && _g !== void 0 ? _g : false;
|
|
2447
2691
|
return message;
|
|
2448
2692
|
},
|
|
2449
2693
|
};
|
|
2450
2694
|
function createBaseVideo() {
|
|
2451
2695
|
return {
|
|
2696
|
+
direction: 0,
|
|
2452
2697
|
supportedFormats: [],
|
|
2453
2698
|
maxDurationSeconds: 0,
|
|
2454
2699
|
maxFileSizeBytes: 0,
|
|
2455
2700
|
maxFps: 0,
|
|
2456
2701
|
supportsFrameExtraction: false,
|
|
2702
|
+
maxFrames: 0,
|
|
2457
2703
|
};
|
|
2458
2704
|
}
|
|
2459
2705
|
exports.Video = {
|
|
2460
2706
|
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
2461
|
-
|
|
2707
|
+
if (message.direction !== 0) {
|
|
2708
|
+
writer.uint32(8).int32(message.direction);
|
|
2709
|
+
}
|
|
2710
|
+
writer.uint32(18).fork();
|
|
2462
2711
|
for (const v of message.supportedFormats) {
|
|
2463
2712
|
writer.int32(v);
|
|
2464
2713
|
}
|
|
2465
2714
|
writer.join();
|
|
2466
2715
|
if (message.maxDurationSeconds !== 0) {
|
|
2467
|
-
writer.uint32(
|
|
2716
|
+
writer.uint32(24).int32(message.maxDurationSeconds);
|
|
2468
2717
|
}
|
|
2469
2718
|
if (message.maxFileSizeBytes !== 0) {
|
|
2470
|
-
writer.uint32(
|
|
2719
|
+
writer.uint32(32).int64(message.maxFileSizeBytes);
|
|
2471
2720
|
}
|
|
2472
2721
|
if (message.maxFps !== 0) {
|
|
2473
|
-
writer.uint32(
|
|
2722
|
+
writer.uint32(40).int32(message.maxFps);
|
|
2474
2723
|
}
|
|
2475
2724
|
if (message.supportsFrameExtraction !== false) {
|
|
2476
|
-
writer.uint32(
|
|
2725
|
+
writer.uint32(48).bool(message.supportsFrameExtraction);
|
|
2726
|
+
}
|
|
2727
|
+
if (message.maxFrames !== 0) {
|
|
2728
|
+
writer.uint32(56).int32(message.maxFrames);
|
|
2477
2729
|
}
|
|
2478
2730
|
return writer;
|
|
2479
2731
|
},
|
|
@@ -2485,11 +2737,18 @@ exports.Video = {
|
|
|
2485
2737
|
const tag = reader.uint32();
|
|
2486
2738
|
switch (tag >>> 3) {
|
|
2487
2739
|
case 1: {
|
|
2488
|
-
if (tag
|
|
2740
|
+
if (tag !== 8) {
|
|
2741
|
+
break;
|
|
2742
|
+
}
|
|
2743
|
+
message.direction = reader.int32();
|
|
2744
|
+
continue;
|
|
2745
|
+
}
|
|
2746
|
+
case 2: {
|
|
2747
|
+
if (tag === 16) {
|
|
2489
2748
|
message.supportedFormats.push(reader.int32());
|
|
2490
2749
|
continue;
|
|
2491
2750
|
}
|
|
2492
|
-
if (tag ===
|
|
2751
|
+
if (tag === 18) {
|
|
2493
2752
|
const end2 = reader.uint32() + reader.pos;
|
|
2494
2753
|
while (reader.pos < end2) {
|
|
2495
2754
|
message.supportedFormats.push(reader.int32());
|
|
@@ -2498,34 +2757,41 @@ exports.Video = {
|
|
|
2498
2757
|
}
|
|
2499
2758
|
break;
|
|
2500
2759
|
}
|
|
2501
|
-
case
|
|
2502
|
-
if (tag !==
|
|
2760
|
+
case 3: {
|
|
2761
|
+
if (tag !== 24) {
|
|
2503
2762
|
break;
|
|
2504
2763
|
}
|
|
2505
2764
|
message.maxDurationSeconds = reader.int32();
|
|
2506
2765
|
continue;
|
|
2507
2766
|
}
|
|
2508
|
-
case
|
|
2509
|
-
if (tag !==
|
|
2767
|
+
case 4: {
|
|
2768
|
+
if (tag !== 32) {
|
|
2510
2769
|
break;
|
|
2511
2770
|
}
|
|
2512
2771
|
message.maxFileSizeBytes = longToNumber(reader.int64());
|
|
2513
2772
|
continue;
|
|
2514
2773
|
}
|
|
2515
|
-
case
|
|
2516
|
-
if (tag !==
|
|
2774
|
+
case 5: {
|
|
2775
|
+
if (tag !== 40) {
|
|
2517
2776
|
break;
|
|
2518
2777
|
}
|
|
2519
2778
|
message.maxFps = reader.int32();
|
|
2520
2779
|
continue;
|
|
2521
2780
|
}
|
|
2522
|
-
case
|
|
2523
|
-
if (tag !==
|
|
2781
|
+
case 6: {
|
|
2782
|
+
if (tag !== 48) {
|
|
2524
2783
|
break;
|
|
2525
2784
|
}
|
|
2526
2785
|
message.supportsFrameExtraction = reader.bool();
|
|
2527
2786
|
continue;
|
|
2528
2787
|
}
|
|
2788
|
+
case 7: {
|
|
2789
|
+
if (tag !== 56) {
|
|
2790
|
+
break;
|
|
2791
|
+
}
|
|
2792
|
+
message.maxFrames = reader.int32();
|
|
2793
|
+
continue;
|
|
2794
|
+
}
|
|
2529
2795
|
}
|
|
2530
2796
|
if ((tag & 7) === 4 || tag === 0) {
|
|
2531
2797
|
break;
|
|
@@ -2536,6 +2802,7 @@ exports.Video = {
|
|
|
2536
2802
|
},
|
|
2537
2803
|
fromJSON(object) {
|
|
2538
2804
|
return {
|
|
2805
|
+
direction: isSet(object.direction) ? modalityDirectionFromJSON(object.direction) : 0,
|
|
2539
2806
|
supportedFormats: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.supportedFormats)
|
|
2540
2807
|
? object.supportedFormats.map((e) => videoFormatFromJSON(e))
|
|
2541
2808
|
: [],
|
|
@@ -2545,11 +2812,15 @@ exports.Video = {
|
|
|
2545
2812
|
supportsFrameExtraction: isSet(object.supportsFrameExtraction)
|
|
2546
2813
|
? globalThis.Boolean(object.supportsFrameExtraction)
|
|
2547
2814
|
: false,
|
|
2815
|
+
maxFrames: isSet(object.maxFrames) ? globalThis.Number(object.maxFrames) : 0,
|
|
2548
2816
|
};
|
|
2549
2817
|
},
|
|
2550
2818
|
toJSON(message) {
|
|
2551
2819
|
var _a;
|
|
2552
2820
|
const obj = {};
|
|
2821
|
+
if (message.direction !== 0) {
|
|
2822
|
+
obj.direction = modalityDirectionToJSON(message.direction);
|
|
2823
|
+
}
|
|
2553
2824
|
if ((_a = message.supportedFormats) === null || _a === void 0 ? void 0 : _a.length) {
|
|
2554
2825
|
obj.supportedFormats = message.supportedFormats.map((e) => videoFormatToJSON(e));
|
|
2555
2826
|
}
|
|
@@ -2565,19 +2836,24 @@ exports.Video = {
|
|
|
2565
2836
|
if (message.supportsFrameExtraction !== false) {
|
|
2566
2837
|
obj.supportsFrameExtraction = message.supportsFrameExtraction;
|
|
2567
2838
|
}
|
|
2839
|
+
if (message.maxFrames !== 0) {
|
|
2840
|
+
obj.maxFrames = Math.round(message.maxFrames);
|
|
2841
|
+
}
|
|
2568
2842
|
return obj;
|
|
2569
2843
|
},
|
|
2570
2844
|
create(base) {
|
|
2571
2845
|
return exports.Video.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
2572
2846
|
},
|
|
2573
2847
|
fromPartial(object) {
|
|
2574
|
-
var _a, _b, _c, _d, _e;
|
|
2848
|
+
var _a, _b, _c, _d, _e, _f, _g;
|
|
2575
2849
|
const message = createBaseVideo();
|
|
2576
|
-
message.
|
|
2577
|
-
message.
|
|
2578
|
-
message.
|
|
2579
|
-
message.
|
|
2580
|
-
message.
|
|
2850
|
+
message.direction = (_a = object.direction) !== null && _a !== void 0 ? _a : 0;
|
|
2851
|
+
message.supportedFormats = ((_b = object.supportedFormats) === null || _b === void 0 ? void 0 : _b.map((e) => e)) || [];
|
|
2852
|
+
message.maxDurationSeconds = (_c = object.maxDurationSeconds) !== null && _c !== void 0 ? _c : 0;
|
|
2853
|
+
message.maxFileSizeBytes = (_d = object.maxFileSizeBytes) !== null && _d !== void 0 ? _d : 0;
|
|
2854
|
+
message.maxFps = (_e = object.maxFps) !== null && _e !== void 0 ? _e : 0;
|
|
2855
|
+
message.supportsFrameExtraction = (_f = object.supportsFrameExtraction) !== null && _f !== void 0 ? _f : false;
|
|
2856
|
+
message.maxFrames = (_g = object.maxFrames) !== null && _g !== void 0 ? _g : 0;
|
|
2581
2857
|
return message;
|
|
2582
2858
|
},
|
|
2583
2859
|
};
|