utilitas 1999.1.2 → 1999.1.3
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/utilitas.lite.mjs +1 -1
- package/dist/utilitas.lite.mjs.map +1 -1
- package/lib/alan.mjs +3 -1
- package/lib/manifest.mjs +1 -1
- package/package.json +1 -1
package/lib/alan.mjs
CHANGED
|
@@ -593,7 +593,9 @@ const getAi = async (id, options = {}) => {
|
|
|
593
593
|
log(`Best match AI not found, fallbacked: ${JSON.stringify(options.select)}.`);
|
|
594
594
|
return options.all ? res : res[0];
|
|
595
595
|
}
|
|
596
|
-
|
|
596
|
+
const result = options.all ? ais : ais[0];
|
|
597
|
+
assert(result?.length || result?.id, 'AI not found.');
|
|
598
|
+
return result;
|
|
597
599
|
};
|
|
598
600
|
|
|
599
601
|
const countTokens = async (input, options) => {
|
package/lib/manifest.mjs
CHANGED