Update language-inference-engine.js

This commit is contained in:
Namhyeon Go 2025-02-07 23:41:11 +09:00
parent 2251494a48
commit eacd68ce88

View File

@ -13,6 +13,7 @@
// - Google Gemini: https://developers.google.com/idx/support/privacy
// - DeepSeek: https://chat.deepseek.com/downloads/DeepSeek%20Privacy%20Policy.html
// - Moonshot: https://kimi.moonshot.cn/user/agreement/userPrivacy
// - ClovaStudio: https://clova-x.naver.com/ai_policies
// - Catswords AI: https://policy.catswords.social/site_terms.html
//
var HTTP = require("lib/http");
@ -371,14 +372,10 @@ var ENGINE_PROFILES = {
};
},
"callback": function(response) {
if ("error" in response) {
return ["Error: " + response.error.message];
if (response.status.code != "20000") {
return ["Error: " + response.status.message];
} else {
return response.choices.reduce(function(a, x) {
a.push(x.message.content);
return a;
}, []);
return [response.result.message];
}
}
},
@ -494,7 +491,7 @@ exports.create = function() {
return new LanguageInferenceEngine();
};
exports.VERSIONINFO = "Language Inference Engine integration version 0.1.9";
exports.VERSIONINFO = "Language Inference Engine integration version 0.1.10";
exports.AUTHOR = "abuse@catswords.net";
exports.global = global;
exports.require = global.require;