@anyway-sh/node-server-sdk 0.22.10 → 0.22.11
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/index.js +596 -2
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +596 -2
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -66,7 +66,7 @@ class PromptNotFoundError extends TraceloopError {
|
|
|
66
66
|
}
|
|
67
67
|
}
|
|
68
68
|
|
|
69
|
-
var version = "0.22.
|
|
69
|
+
var version = "0.22.11";
|
|
70
70
|
|
|
71
71
|
/**
|
|
72
72
|
* Base class for handling annotation operations with the Traceloop API.
|
|
@@ -3910,13 +3910,607 @@ class PricingCalculator {
|
|
|
3910
3910
|
}
|
|
3911
3911
|
}
|
|
3912
3912
|
|
|
3913
|
+
var embeddings = {
|
|
3914
|
+
"text-embedding-ada-002": 0.0001,
|
|
3915
|
+
"text-embedding-3-small": 0.00002,
|
|
3916
|
+
"text-embedding-3-large": 0.00013,
|
|
3917
|
+
ada: 0.0001,
|
|
3918
|
+
"ada-v2": 0.0001,
|
|
3919
|
+
"text-ada-001": 0.0001,
|
|
3920
|
+
"azure_text-embedding-ada-002": 0.0001,
|
|
3921
|
+
"azure_text-embedding-3-small": 0.00002,
|
|
3922
|
+
"azure_text-embedding-3-large": 0.00013,
|
|
3923
|
+
azure_ada: 0.0001,
|
|
3924
|
+
"azure_ada-v2": 0.0001,
|
|
3925
|
+
"azure_text-ada-001": 0.0001,
|
|
3926
|
+
"embed-english-v3.0": 0.0001,
|
|
3927
|
+
"embed-multilingual-v3.0": 0.0001,
|
|
3928
|
+
"embed-english-light-v3.0": 0.0001,
|
|
3929
|
+
"embed-multilingual-light-v3.0": 0.0001,
|
|
3930
|
+
"embed-english-v2.0": 0.0001,
|
|
3931
|
+
"embed-english-light-v2.0": 0.0001,
|
|
3932
|
+
"embed-multilingual-v2.0": 0.0001,
|
|
3933
|
+
"mistral-embed": 0.0001,
|
|
3934
|
+
"amazon.titan-embed-text-v1": 0.0001,
|
|
3935
|
+
"amazon.titan-embed-text-v2": 0.00002,
|
|
3936
|
+
"textembedding-gecko": 0.0001,
|
|
3937
|
+
"textembedding-gecko@001": 0.0001,
|
|
3938
|
+
"textembedding-gecko@002": 0.0001,
|
|
3939
|
+
"textembedding-gecko@003": 0.0001
|
|
3940
|
+
};
|
|
3941
|
+
var images = {
|
|
3942
|
+
"dall-e-3": {
|
|
3943
|
+
standard: {
|
|
3944
|
+
"1024x1024": 0.04,
|
|
3945
|
+
"1024x1792": 0.02,
|
|
3946
|
+
"1792x1024": 0.08
|
|
3947
|
+
},
|
|
3948
|
+
hd: {
|
|
3949
|
+
"1024x1024": 0.08,
|
|
3950
|
+
"1024x1792": 0.12,
|
|
3951
|
+
"1792x1024": 0.12
|
|
3952
|
+
}
|
|
3953
|
+
},
|
|
3954
|
+
"azure_dall-e-3": {
|
|
3955
|
+
standard: {
|
|
3956
|
+
"1024x1024": 0.04,
|
|
3957
|
+
"1024x1792": 0.02,
|
|
3958
|
+
"1792x1024": 0.08
|
|
3959
|
+
},
|
|
3960
|
+
hd: {
|
|
3961
|
+
"1024x1024": 0.08,
|
|
3962
|
+
"1024x1792": 0.12,
|
|
3963
|
+
"1792x1024": 0.12
|
|
3964
|
+
}
|
|
3965
|
+
},
|
|
3966
|
+
"dall-e-2": {
|
|
3967
|
+
standard: {
|
|
3968
|
+
"1024x1024": 0.02,
|
|
3969
|
+
"512x512": 0.018,
|
|
3970
|
+
"256x256": 0.016
|
|
3971
|
+
}
|
|
3972
|
+
},
|
|
3973
|
+
"black-forest-labs/FLUX.1-dev": {
|
|
3974
|
+
standard: {
|
|
3975
|
+
"1000000": 0.025
|
|
3976
|
+
}
|
|
3977
|
+
},
|
|
3978
|
+
"black-forest-labs/FLUX.1-canny": {
|
|
3979
|
+
standard: {
|
|
3980
|
+
"1000000": 0.025
|
|
3981
|
+
}
|
|
3982
|
+
},
|
|
3983
|
+
"black-forest-labs/FLUX.1-depth": {
|
|
3984
|
+
standard: {
|
|
3985
|
+
"1000000": 0.025
|
|
3986
|
+
}
|
|
3987
|
+
},
|
|
3988
|
+
"black-forest-labs/FLUX.1-redux": {
|
|
3989
|
+
standard: {
|
|
3990
|
+
"1000000": 0.025
|
|
3991
|
+
}
|
|
3992
|
+
},
|
|
3993
|
+
"black-forest-labs/FLUX.1-schnell": {
|
|
3994
|
+
standard: {
|
|
3995
|
+
"1000000": 0.0027
|
|
3996
|
+
}
|
|
3997
|
+
},
|
|
3998
|
+
"black-forest-labs/FLUX.1-pro": {
|
|
3999
|
+
standard: {
|
|
4000
|
+
"1000000": 0.04
|
|
4001
|
+
}
|
|
4002
|
+
},
|
|
4003
|
+
"black-forest-labs/FLUX.1.1-pro": {
|
|
4004
|
+
standard: {
|
|
4005
|
+
"1000000": 0.05
|
|
4006
|
+
}
|
|
4007
|
+
},
|
|
4008
|
+
"stabilityai/stable-diffusion-xl-base-1.0": {
|
|
4009
|
+
standard: {
|
|
4010
|
+
"512X512": 0.001,
|
|
4011
|
+
"1024x1024": 0.01
|
|
4012
|
+
}
|
|
4013
|
+
},
|
|
4014
|
+
"amazon.titan-image-generator-v1": {
|
|
4015
|
+
standard: {
|
|
4016
|
+
"512x512": 0.008,
|
|
4017
|
+
"1024x1024": 0.01
|
|
4018
|
+
},
|
|
4019
|
+
premium: {
|
|
4020
|
+
"512x512": 0.01,
|
|
4021
|
+
"1024x1024": 0.012
|
|
4022
|
+
}
|
|
4023
|
+
}
|
|
4024
|
+
};
|
|
4025
|
+
var audio = {
|
|
4026
|
+
"tts-1": 0.015,
|
|
4027
|
+
"tts-1-hd": 0.03,
|
|
4028
|
+
eleven_multilingual_v2: 0.24,
|
|
4029
|
+
eleven_multilingual_v1: 0.24,
|
|
4030
|
+
eleven_monolingual_v1: 0.24,
|
|
4031
|
+
eleven_english_v1: 0.24,
|
|
4032
|
+
eleven_turbo_v2: 0.24,
|
|
4033
|
+
eleven_english_sts_v2: 0.24,
|
|
4034
|
+
eleven_multilingual_sts_v2: 0.24,
|
|
4035
|
+
best: 0.00010277777,
|
|
4036
|
+
nano: 0.00003333333
|
|
4037
|
+
};
|
|
4038
|
+
var chat = {
|
|
4039
|
+
"gpt-4.1-nano-2025-04-14": {
|
|
4040
|
+
promptPrice: 0.0001,
|
|
4041
|
+
completionPrice: 0.0004
|
|
4042
|
+
},
|
|
4043
|
+
"gpt-4.1-nano": {
|
|
4044
|
+
promptPrice: 0.0001,
|
|
4045
|
+
completionPrice: 0.0004
|
|
4046
|
+
},
|
|
4047
|
+
"gpt-4.1-mini-2025-04-14": {
|
|
4048
|
+
promptPrice: 0.0004,
|
|
4049
|
+
completionPrice: 0.0016
|
|
4050
|
+
},
|
|
4051
|
+
"gpt-4.1-mini": {
|
|
4052
|
+
promptPrice: 0.0004,
|
|
4053
|
+
completionPrice: 0.0016
|
|
4054
|
+
},
|
|
4055
|
+
"gpt-4.1-2025-04-14": {
|
|
4056
|
+
promptPrice: 0.002,
|
|
4057
|
+
completionPrice: 0.008
|
|
4058
|
+
},
|
|
4059
|
+
"gpt-4.1": {
|
|
4060
|
+
promptPrice: 0.002,
|
|
4061
|
+
completionPrice: 0.008
|
|
4062
|
+
},
|
|
4063
|
+
"gpt-4o": {
|
|
4064
|
+
promptPrice: 0.0005,
|
|
4065
|
+
completionPrice: 0.0015
|
|
4066
|
+
},
|
|
4067
|
+
"gpt-4o-2024-08-06": {
|
|
4068
|
+
promptPrice: 0.0025,
|
|
4069
|
+
completionPrice: 0.01
|
|
4070
|
+
},
|
|
4071
|
+
"gpt-4o-2024-05-13": {
|
|
4072
|
+
promptPrice: 0.005,
|
|
4073
|
+
completionPrice: 0.015
|
|
4074
|
+
},
|
|
4075
|
+
"gpt-4o-mini": {
|
|
4076
|
+
promptPrice: 0.00015,
|
|
4077
|
+
completionPrice: 0.0006
|
|
4078
|
+
},
|
|
4079
|
+
"gpt-4o-mini-2024-07-18": {
|
|
4080
|
+
promptPrice: 0.00015,
|
|
4081
|
+
completionPrice: 0.0006
|
|
4082
|
+
},
|
|
4083
|
+
"o1-mini": {
|
|
4084
|
+
promptPrice: 0.003,
|
|
4085
|
+
completionPrice: 0.012
|
|
4086
|
+
},
|
|
4087
|
+
"o1-mini-2024-09-12": {
|
|
4088
|
+
promptPrice: 0.003,
|
|
4089
|
+
completionPrice: 0.012
|
|
4090
|
+
},
|
|
4091
|
+
"o1-preview": {
|
|
4092
|
+
promptPrice: 0.015,
|
|
4093
|
+
completionPrice: 0.06
|
|
4094
|
+
},
|
|
4095
|
+
"o1-preview-2024-09-12": {
|
|
4096
|
+
promptPrice: 0.015,
|
|
4097
|
+
completionPrice: 0.06
|
|
4098
|
+
},
|
|
4099
|
+
"gpt-3.5-turbo": {
|
|
4100
|
+
promptPrice: 0.0005,
|
|
4101
|
+
completionPrice: 0.0015
|
|
4102
|
+
},
|
|
4103
|
+
"gpt-3.5-turbo-0125": {
|
|
4104
|
+
promptPrice: 0.0005,
|
|
4105
|
+
completionPrice: 0.0015
|
|
4106
|
+
},
|
|
4107
|
+
"azure_gpt-35-turbo": {
|
|
4108
|
+
promptPrice: 0.0005,
|
|
4109
|
+
completionPrice: 0.0015
|
|
4110
|
+
},
|
|
4111
|
+
"azure_gpt-35-turbo-16k": {
|
|
4112
|
+
promptPrice: 0.0005,
|
|
4113
|
+
completionPrice: 0.0015
|
|
4114
|
+
},
|
|
4115
|
+
"azure_gpt-35-turbo-instruct": {
|
|
4116
|
+
promptPrice: 0.0015,
|
|
4117
|
+
completionPrice: 0.002
|
|
4118
|
+
},
|
|
4119
|
+
"gpt-4": {
|
|
4120
|
+
promptPrice: 0.03,
|
|
4121
|
+
completionPrice: 0.06
|
|
4122
|
+
},
|
|
4123
|
+
"gpt-4-turbo": {
|
|
4124
|
+
promptPrice: 0.01,
|
|
4125
|
+
completionPrice: 0.03
|
|
4126
|
+
},
|
|
4127
|
+
"gpt-4-32k": {
|
|
4128
|
+
promptPrice: 0.06,
|
|
4129
|
+
completionPrice: 0.12
|
|
4130
|
+
},
|
|
4131
|
+
"gpt-4-1106-preview": {
|
|
4132
|
+
promptPrice: 0.01,
|
|
4133
|
+
completionPrice: 0.03
|
|
4134
|
+
},
|
|
4135
|
+
"gpt-4-0125-preview": {
|
|
4136
|
+
promptPrice: 0.01,
|
|
4137
|
+
completionPrice: 0.03
|
|
4138
|
+
},
|
|
4139
|
+
"gpt-4-preview": {
|
|
4140
|
+
promptPrice: 0.01,
|
|
4141
|
+
completionPrice: 0.03
|
|
4142
|
+
},
|
|
4143
|
+
"gpt-4-1106-vision-preview": {
|
|
4144
|
+
promptPrice: 0.01,
|
|
4145
|
+
completionPrice: 0.03
|
|
4146
|
+
},
|
|
4147
|
+
"gpt-4-vision-preview": {
|
|
4148
|
+
promptPrice: 0.01,
|
|
4149
|
+
completionPrice: 0.03
|
|
4150
|
+
},
|
|
4151
|
+
"azure_gpt-4": {
|
|
4152
|
+
promptPrice: 0.03,
|
|
4153
|
+
completionPrice: 0.06
|
|
4154
|
+
},
|
|
4155
|
+
"azure_gpt-4-32k": {
|
|
4156
|
+
promptPrice: 0.06,
|
|
4157
|
+
completionPrice: 0.12
|
|
4158
|
+
},
|
|
4159
|
+
"claude-3-opus-20240229": {
|
|
4160
|
+
promptPrice: 0.015,
|
|
4161
|
+
completionPrice: 0.075
|
|
4162
|
+
},
|
|
4163
|
+
"claude-3-sonnet-20240229": {
|
|
4164
|
+
promptPrice: 0.003,
|
|
4165
|
+
completionPrice: 0.015
|
|
4166
|
+
},
|
|
4167
|
+
"claude-3-haiku-20240307": {
|
|
4168
|
+
promptPrice: 0.00025,
|
|
4169
|
+
completionPrice: 0.00125
|
|
4170
|
+
},
|
|
4171
|
+
command: {
|
|
4172
|
+
promptPrice: 0.001,
|
|
4173
|
+
completionPrice: 0.002
|
|
4174
|
+
},
|
|
4175
|
+
"command-nightly": {
|
|
4176
|
+
promptPrice: 0.001,
|
|
4177
|
+
completionPrice: 0.002
|
|
4178
|
+
},
|
|
4179
|
+
"command-light": {
|
|
4180
|
+
promptPrice: 0.0003,
|
|
4181
|
+
completionPrice: 0.0006
|
|
4182
|
+
},
|
|
4183
|
+
"command-light-nightly": {
|
|
4184
|
+
promptPrice: 0.0003,
|
|
4185
|
+
completionPrice: 0.0006
|
|
4186
|
+
},
|
|
4187
|
+
"open-mistral-7b": {
|
|
4188
|
+
promptPrice: 0.00025,
|
|
4189
|
+
completionPrice: 0.00025
|
|
4190
|
+
},
|
|
4191
|
+
"open-mixtral-8x7b": {
|
|
4192
|
+
promptPrice: 0.0007,
|
|
4193
|
+
completionPrice: 0.0007
|
|
4194
|
+
},
|
|
4195
|
+
"mistral-small-latest": {
|
|
4196
|
+
promptPrice: 0.002,
|
|
4197
|
+
completionPrice: 0.006
|
|
4198
|
+
},
|
|
4199
|
+
"mistral-medium-latest": {
|
|
4200
|
+
promptPrice: 0.0027,
|
|
4201
|
+
completionPrice: 0.0081
|
|
4202
|
+
},
|
|
4203
|
+
"mistral-large-latest": {
|
|
4204
|
+
promptPrice: 0.008,
|
|
4205
|
+
completionPrice: 0.024
|
|
4206
|
+
},
|
|
4207
|
+
"amazon.titan-text-express-v1": {
|
|
4208
|
+
promptPrice: 0.0008,
|
|
4209
|
+
completionPrice: 0.0016
|
|
4210
|
+
},
|
|
4211
|
+
"amazon.titan-text-lite-v1": {
|
|
4212
|
+
promptPrice: 0.0003,
|
|
4213
|
+
completionPrice: 0.0004
|
|
4214
|
+
},
|
|
4215
|
+
"mistral.mistral-7b-instruct-v0:2": {
|
|
4216
|
+
promptPrice: 0.00015,
|
|
4217
|
+
completionPrice: 0.0002
|
|
4218
|
+
},
|
|
4219
|
+
"mistral.mixtral-8x7b-instruct-v0:1": {
|
|
4220
|
+
promptPrice: 0.00045,
|
|
4221
|
+
completionPrice: 0.0007
|
|
4222
|
+
},
|
|
4223
|
+
"mistral.mistral-large-2402-v1:0": {
|
|
4224
|
+
promptPrice: 0.008,
|
|
4225
|
+
completionPrice: 0.024
|
|
4226
|
+
},
|
|
4227
|
+
"anthropic.claude-3-haiku-20240307-v1:0": {
|
|
4228
|
+
promptPrice: 0.00025,
|
|
4229
|
+
completionPrice: 0.00125
|
|
4230
|
+
},
|
|
4231
|
+
"anthropic.claude-v2": {
|
|
4232
|
+
promptPrice: 0.008,
|
|
4233
|
+
completionPrice: 0.024
|
|
4234
|
+
},
|
|
4235
|
+
"anthropic.claude-3-sonnet-20240229-v1:0": {
|
|
4236
|
+
promptPrice: 0.003,
|
|
4237
|
+
completionPrice: 0.015
|
|
4238
|
+
},
|
|
4239
|
+
"anthropic.claude-3-opus-20240229-v1:0": {
|
|
4240
|
+
promptPrice: 0.015,
|
|
4241
|
+
completionPrice: 0.075
|
|
4242
|
+
},
|
|
4243
|
+
"meta.llama3-8b-instruct-v1:0": {
|
|
4244
|
+
promptPrice: 0.0004,
|
|
4245
|
+
completionPrice: 0.0006
|
|
4246
|
+
},
|
|
4247
|
+
"meta.llama3-70b-instruct-v1:0": {
|
|
4248
|
+
promptPrice: 0.00265,
|
|
4249
|
+
completionPrice: 0.0035
|
|
4250
|
+
},
|
|
4251
|
+
"meta.llama2-13b-chat-v1": {
|
|
4252
|
+
promptPrice: 0.00075,
|
|
4253
|
+
completionPrice: 0.001
|
|
4254
|
+
},
|
|
4255
|
+
"meta.llama2-70b-chat-v1": {
|
|
4256
|
+
promptPrice: 0.00195,
|
|
4257
|
+
completionPrice: 0.00256
|
|
4258
|
+
},
|
|
4259
|
+
"cohere.command-text-v14": {
|
|
4260
|
+
promptPrice: 0.0015,
|
|
4261
|
+
completionPrice: 0.002
|
|
4262
|
+
},
|
|
4263
|
+
"cohere.command-light-text-v14": {
|
|
4264
|
+
promptPrice: 0.0003,
|
|
4265
|
+
completionPrice: 0.0006
|
|
4266
|
+
},
|
|
4267
|
+
"ai21.j2-mid-v1": {
|
|
4268
|
+
promptPrice: 0.0125,
|
|
4269
|
+
completionPrice: 0.0125
|
|
4270
|
+
},
|
|
4271
|
+
"ai21.j2-ultra-v1": {
|
|
4272
|
+
promptPrice: 0.0188,
|
|
4273
|
+
completionPrice: 0.0188
|
|
4274
|
+
},
|
|
4275
|
+
"gemini-1.0-pro": {
|
|
4276
|
+
promptPrice: 0.0005,
|
|
4277
|
+
completionPrice: 0.0015
|
|
4278
|
+
},
|
|
4279
|
+
"gemini-1.5-flash": {
|
|
4280
|
+
promptPrice: 0.000075,
|
|
4281
|
+
completionPrice: 0.0003
|
|
4282
|
+
},
|
|
4283
|
+
"gemini-1.5-pro": {
|
|
4284
|
+
promptPrice: 0.00125,
|
|
4285
|
+
completionPrice: 0.005
|
|
4286
|
+
},
|
|
4287
|
+
"gemini-1.0-pro-002": {
|
|
4288
|
+
promptPrice: 0.0005,
|
|
4289
|
+
completionPrice: 0.0015
|
|
4290
|
+
},
|
|
4291
|
+
"gemini-1.0-pro-001": {
|
|
4292
|
+
promptPrice: 0.0005,
|
|
4293
|
+
completionPrice: 0.0015
|
|
4294
|
+
},
|
|
4295
|
+
"gemini-1.5-pro-preview-0409": {
|
|
4296
|
+
promptPrice: 0.005,
|
|
4297
|
+
completionPrice: 0.015
|
|
4298
|
+
},
|
|
4299
|
+
"gemini-1.5-pro-preview-0514": {
|
|
4300
|
+
promptPrice: 0.005,
|
|
4301
|
+
completionPrice: 0.015
|
|
4302
|
+
},
|
|
4303
|
+
"gemini-1.5-flash-preview-0514": {
|
|
4304
|
+
promptPrice: 0.0005,
|
|
4305
|
+
completionPrice: 0.0015
|
|
4306
|
+
},
|
|
4307
|
+
"gemini-2.0-flash": {
|
|
4308
|
+
promptPrice: 0.0001,
|
|
4309
|
+
completionPrice: 0.0004
|
|
4310
|
+
},
|
|
4311
|
+
"gemini-2.0-flash-lite": {
|
|
4312
|
+
promptPrice: 0.000075,
|
|
4313
|
+
completionPrice: 0.0003
|
|
4314
|
+
},
|
|
4315
|
+
"gemini-2.5-flash": {
|
|
4316
|
+
promptPrice: 0.0003,
|
|
4317
|
+
completionPrice: 0.0025
|
|
4318
|
+
},
|
|
4319
|
+
"gemini-2.5-flash-preview": {
|
|
4320
|
+
promptPrice: 0.0003,
|
|
4321
|
+
completionPrice: 0.0025
|
|
4322
|
+
},
|
|
4323
|
+
"gemini-2.5-flash-lite": {
|
|
4324
|
+
promptPrice: 0.0001,
|
|
4325
|
+
completionPrice: 0.0004
|
|
4326
|
+
},
|
|
4327
|
+
"gemini-2.5-flash-lite-preview": {
|
|
4328
|
+
promptPrice: 0.0001,
|
|
4329
|
+
completionPrice: 0.0004
|
|
4330
|
+
},
|
|
4331
|
+
"gemini-2.5-pro": {
|
|
4332
|
+
promptPrice: 0.00125,
|
|
4333
|
+
completionPrice: 0.01
|
|
4334
|
+
},
|
|
4335
|
+
"text-bison": {
|
|
4336
|
+
promptPrice: 0.001,
|
|
4337
|
+
completionPrice: 0.002
|
|
4338
|
+
},
|
|
4339
|
+
"text-bison@002": {
|
|
4340
|
+
promptPrice: 0.001,
|
|
4341
|
+
completionPrice: 0.002
|
|
4342
|
+
},
|
|
4343
|
+
"text-bison-32k": {
|
|
4344
|
+
promptPrice: 0.001,
|
|
4345
|
+
completionPrice: 0.002
|
|
4346
|
+
},
|
|
4347
|
+
"text-bison-32k@002": {
|
|
4348
|
+
promptPrice: 0.001,
|
|
4349
|
+
completionPrice: 0.002
|
|
4350
|
+
},
|
|
4351
|
+
"text-unicorn": {
|
|
4352
|
+
promptPrice: 0.01,
|
|
4353
|
+
completionPrice: 0.03
|
|
4354
|
+
},
|
|
4355
|
+
"text-unicorn@001": {
|
|
4356
|
+
promptPrice: 0.01,
|
|
4357
|
+
completionPrice: 0.03
|
|
4358
|
+
},
|
|
4359
|
+
"chat-bison": {
|
|
4360
|
+
promptPrice: 0.001,
|
|
4361
|
+
completionPrice: 0.002
|
|
4362
|
+
},
|
|
4363
|
+
"chat-bison@002": {
|
|
4364
|
+
promptPrice: 0.001,
|
|
4365
|
+
completionPrice: 0.002
|
|
4366
|
+
},
|
|
4367
|
+
"chat-bison-32k": {
|
|
4368
|
+
promptPrice: 0.001,
|
|
4369
|
+
completionPrice: 0.002
|
|
4370
|
+
},
|
|
4371
|
+
"chat-bison-32k@002": {
|
|
4372
|
+
promptPrice: 0.001,
|
|
4373
|
+
completionPrice: 0.002
|
|
4374
|
+
},
|
|
4375
|
+
"llama3-8b-8192": {
|
|
4376
|
+
promptPrice: 0.00005,
|
|
4377
|
+
completionPrice: 0.0001
|
|
4378
|
+
},
|
|
4379
|
+
"llama3-70b-8192": {
|
|
4380
|
+
promptPrice: 0.00059,
|
|
4381
|
+
completionPrice: 0.00079
|
|
4382
|
+
},
|
|
4383
|
+
"mixtral-8x7b-32768": {
|
|
4384
|
+
promptPrice: 0.00024,
|
|
4385
|
+
completionPrice: 0.00024
|
|
4386
|
+
},
|
|
4387
|
+
"gemma-7b-it": {
|
|
4388
|
+
promptPrice: 0.0001,
|
|
4389
|
+
completionPrice: 0.0001
|
|
4390
|
+
},
|
|
4391
|
+
"reka-core": {
|
|
4392
|
+
promptPrice: 0.002,
|
|
4393
|
+
completionPrice: 0.002
|
|
4394
|
+
},
|
|
4395
|
+
"reka-core-20240415": {
|
|
4396
|
+
promptPrice: 0.002,
|
|
4397
|
+
completionPrice: 0.002
|
|
4398
|
+
},
|
|
4399
|
+
"reka-core-20240501": {
|
|
4400
|
+
promptPrice: 0.002,
|
|
4401
|
+
completionPrice: 0.002
|
|
4402
|
+
},
|
|
4403
|
+
"reka-flash": {
|
|
4404
|
+
promptPrice: 0.0002,
|
|
4405
|
+
completionPrice: 0.0008
|
|
4406
|
+
},
|
|
4407
|
+
"reka-flash-20240226": {
|
|
4408
|
+
promptPrice: 0.0002,
|
|
4409
|
+
completionPrice: 0.0008
|
|
4410
|
+
},
|
|
4411
|
+
"reka-edge": {
|
|
4412
|
+
promptPrice: 0.0001,
|
|
4413
|
+
completionPrice: 0.0001
|
|
4414
|
+
},
|
|
4415
|
+
"reka-edge-20240208": {
|
|
4416
|
+
promptPrice: 0.0001,
|
|
4417
|
+
completionPrice: 0.0001
|
|
4418
|
+
},
|
|
4419
|
+
"reka-spark": {
|
|
4420
|
+
promptPrice: 0.00005,
|
|
4421
|
+
completionPrice: 0.00005
|
|
4422
|
+
},
|
|
4423
|
+
"grok-beta": {
|
|
4424
|
+
promptPrice: 0.0005,
|
|
4425
|
+
completionPrice: 0.0015
|
|
4426
|
+
},
|
|
4427
|
+
"grok-vision-beta": {
|
|
4428
|
+
promptPrice: 0.0005,
|
|
4429
|
+
completionPrice: 0.0015
|
|
4430
|
+
},
|
|
4431
|
+
"jamba-1.5-mini": {
|
|
4432
|
+
promptPrice: 0.0002,
|
|
4433
|
+
completionPrice: 0.0004
|
|
4434
|
+
},
|
|
4435
|
+
"jamba-1.5-large": {
|
|
4436
|
+
promptPrice: 0.002,
|
|
4437
|
+
completionPrice: 0.008
|
|
4438
|
+
},
|
|
4439
|
+
"meta-llama/Llama-3.3-70B-Instruct-Turbo": {
|
|
4440
|
+
promptPrice: 0.00088,
|
|
4441
|
+
completionPrice: 0.00088
|
|
4442
|
+
},
|
|
4443
|
+
"meta-llama/Meta-Llama-3.1-70B-Instruct-Turbo-vLLM-json": {
|
|
4444
|
+
promptPrice: 0.00088,
|
|
4445
|
+
completionPrice: 0.00088
|
|
4446
|
+
},
|
|
4447
|
+
"meta-llama/Meta-Llama-3.1-405B-Instruct-Lite-Pro-lora": {
|
|
4448
|
+
promptPrice: 0.00088,
|
|
4449
|
+
completionPrice: 0.00088
|
|
4450
|
+
},
|
|
4451
|
+
"meta-llama/Meta-Llama-3.1-405B-Instruct-Turbo": {
|
|
4452
|
+
promptPrice: 0.00088,
|
|
4453
|
+
completionPrice: 0.00088
|
|
4454
|
+
},
|
|
4455
|
+
"Qwen/QwQ-32B-Preview": {
|
|
4456
|
+
promptPrice: 0.0012,
|
|
4457
|
+
completionPrice: 0.0012
|
|
4458
|
+
},
|
|
4459
|
+
"codellama/CodeLlama-34b-Instruct-hf": {
|
|
4460
|
+
promptPrice: 0.0008,
|
|
4461
|
+
completionPrice: 0.0008
|
|
4462
|
+
},
|
|
4463
|
+
"databricks/dbrx-instruct": {
|
|
4464
|
+
promptPrice: 0.0012,
|
|
4465
|
+
completionPrice: 0.0012
|
|
4466
|
+
},
|
|
4467
|
+
"deepseek-ai/deepseek-llm-67b-chat": {
|
|
4468
|
+
promptPrice: 0.0009,
|
|
4469
|
+
completionPrice: 0.0009
|
|
4470
|
+
},
|
|
4471
|
+
"google/gemma-2b-it": {
|
|
4472
|
+
promptPrice: 0.0001,
|
|
4473
|
+
completionPrice: 0.0001
|
|
4474
|
+
},
|
|
4475
|
+
"google/gemma-2-27b-it": {
|
|
4476
|
+
promptPrice: 0.0008,
|
|
4477
|
+
completionPrice: 0.0008
|
|
4478
|
+
},
|
|
4479
|
+
"google/gemma-2-9b-it": {
|
|
4480
|
+
promptPrice: 0.0003,
|
|
4481
|
+
completionPrice: 0.0003
|
|
4482
|
+
},
|
|
4483
|
+
"Gryphe/MythoMax-L2-13b-Lite": {
|
|
4484
|
+
promptPrice: 0.0003,
|
|
4485
|
+
completionPrice: 0.0003
|
|
4486
|
+
},
|
|
4487
|
+
"nvidia/Llama-3.1-Nemotron-70B-Instruct-HF": {
|
|
4488
|
+
promptPrice: 0.0088,
|
|
4489
|
+
completionPrice: 0.0088
|
|
4490
|
+
},
|
|
4491
|
+
"deepseek-chat": {
|
|
4492
|
+
promptPrice: 0.00014,
|
|
4493
|
+
completionPrice: 0.00028
|
|
4494
|
+
},
|
|
4495
|
+
"deepseek-reasoner": {
|
|
4496
|
+
promptPrice: 0.00055,
|
|
4497
|
+
completionPrice: 0.00219
|
|
4498
|
+
}
|
|
4499
|
+
};
|
|
4500
|
+
var defaultPricing = {
|
|
4501
|
+
embeddings: embeddings,
|
|
4502
|
+
images: images,
|
|
4503
|
+
audio: audio,
|
|
4504
|
+
chat: chat
|
|
4505
|
+
};
|
|
4506
|
+
|
|
3913
4507
|
function loadPricing(pricingJsonPath) {
|
|
3914
4508
|
if (pricingJsonPath) {
|
|
3915
4509
|
// eslint-disable-next-line @typescript-eslint/no-var-requires
|
|
3916
4510
|
const fs = require("fs");
|
|
3917
4511
|
return JSON.parse(fs.readFileSync(pricingJsonPath, "utf-8"));
|
|
3918
4512
|
}
|
|
3919
|
-
return
|
|
4513
|
+
return defaultPricing;
|
|
3920
4514
|
}
|
|
3921
4515
|
|
|
3922
4516
|
let _configuration;
|