@yrpri/api 9.0.182 → 9.0.183
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.
|
@@ -798,6 +798,39 @@ export class NewAiModelSetup {
|
|
|
798
798
|
await gemini25FlashPreview.save();
|
|
799
799
|
log.debug("Google model already exists: Gemini 2.5 Flash Preview");
|
|
800
800
|
}
|
|
801
|
+
const gemini25Flash = await PsAiModel.findOne({
|
|
802
|
+
where: { name: "Gemini 2.5 Flash" },
|
|
803
|
+
});
|
|
804
|
+
const gemini25FlashConfig = {
|
|
805
|
+
type: PsAiModelType.Text,
|
|
806
|
+
modelSize: PsAiModelSize.Medium,
|
|
807
|
+
provider: "google",
|
|
808
|
+
prices: {
|
|
809
|
+
costInTokensPerMillion: 0.30,
|
|
810
|
+
costOutTokensPerMillion: 2.5,
|
|
811
|
+
costInCachedContextTokensPerMillion: 0.15,
|
|
812
|
+
currency: "USD",
|
|
813
|
+
},
|
|
814
|
+
model: "gemini-2.5-flash",
|
|
815
|
+
active: true,
|
|
816
|
+
maxTokensOut: 32000,
|
|
817
|
+
maxContextTokens: 1000000,
|
|
818
|
+
defaultTemperature: 0.0,
|
|
819
|
+
};
|
|
820
|
+
if (!gemini25Flash) {
|
|
821
|
+
await PsAiModel.create({
|
|
822
|
+
name: "Gemini 2.5 Flash",
|
|
823
|
+
organization_id: 1,
|
|
824
|
+
user_id: userId,
|
|
825
|
+
configuration: gemini25FlashConfig,
|
|
826
|
+
});
|
|
827
|
+
}
|
|
828
|
+
else {
|
|
829
|
+
gemini25Flash.set("configuration", gemini25FlashConfig);
|
|
830
|
+
gemini25Flash.changed("configuration", true);
|
|
831
|
+
await gemini25Flash.save();
|
|
832
|
+
log.debug("Google model already exists: Gemini 2.5 Flash");
|
|
833
|
+
}
|
|
801
834
|
}
|
|
802
835
|
/**
|
|
803
836
|
* Master seeding function which calls the provider-specific functions
|