utilitas 1999.1.8 → 1999.1.9
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/README.md +1 -1
- package/dist/utilitas.lite.mjs +1 -1
- package/dist/utilitas.lite.mjs.map +1 -1
- package/lib/alan.mjs +3 -1
- package/lib/bot.mjs +1 -1
- package/lib/manifest.mjs +1 -1
- package/package.json +1 -1
package/lib/alan.mjs
CHANGED
|
@@ -204,7 +204,8 @@ for (const n in MODELS) {
|
|
|
204
204
|
MODELS[GEMMA327B] = MODELS[GEMMA_3_27B]; // Ollama Alias
|
|
205
205
|
MODELS[GEMINI_20_FLASH].image = GEMINI_20_FLASH_EXP;
|
|
206
206
|
MODELS[GEMINI_20_FLASH_EXP] = {
|
|
207
|
-
...MODELS[GEMINI_20_FLASH],
|
|
207
|
+
...MODELS[GEMINI_20_FLASH],
|
|
208
|
+
name: GEMINI_20_FLASH_EXP, image: true, tools: false,
|
|
208
209
|
};
|
|
209
210
|
|
|
210
211
|
// Default models for each provider
|
|
@@ -1067,6 +1068,7 @@ const promptGemini = async (aiId, content, options = {}) => {
|
|
|
1067
1068
|
let [result, references, functionCalls, responded, images]
|
|
1068
1069
|
= [options.result ?? '', null, null, false, []];
|
|
1069
1070
|
options.model = options.model || model.name;
|
|
1071
|
+
model.image && (options.imageMode = true);
|
|
1070
1072
|
assert(!(options.imageMode && !model.image), 'Image mode is not supported.');
|
|
1071
1073
|
if (String.isString(model.image)) {
|
|
1072
1074
|
options.model = model.image;
|
package/lib/bot.mjs
CHANGED
|
@@ -426,7 +426,7 @@ const subconscious = [{
|
|
|
426
426
|
ctx.list = async (list, options) => await ctx.ok(uList(list), options);
|
|
427
427
|
ctx.map = async (obj, options) => await ctx.ok(map(obj), options);
|
|
428
428
|
ctx.media = async (fnc, src, options) => ctx.done.push(await ctx[fnc]({
|
|
429
|
-
[src
|
|
429
|
+
[src?.toLowerCase?.()?.startsWith?.('http') ? 'url' : 'source']: src
|
|
430
430
|
}, getExtra(ctx, options)));
|
|
431
431
|
ctx.audio = async (sr, op) => await ctx.media('replyWithAudio', sr, op);
|
|
432
432
|
ctx.image = async (sr, op) => await ctx.media('replyWithPhoto', sr, op);
|
package/lib/manifest.mjs
CHANGED