@nocobase/plugin-ai-gigachat 2.2.2 → 2.2.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.
@@ -7,4 +7,4 @@
7
7
  * For more information, please refer to: https://www.nocobase.com/agreement.
8
8
  */
9
9
 
10
- !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("@nocobase/plugin-ai/client-v2"),require("react"),require("antd"),require("@nocobase/client"),require("@nocobase/client-v2"),require("@nocobase/flow-engine")):"function"==typeof define&&define.amd?define("@nocobase/plugin-ai-gigachat",["@nocobase/plugin-ai/client-v2","react","antd","@nocobase/client","@nocobase/client-v2","@nocobase/flow-engine"],t):"object"==typeof exports?exports["@nocobase/plugin-ai-gigachat"]=t(require("@nocobase/plugin-ai/client-v2"),require("react"),require("antd"),require("@nocobase/client"),require("@nocobase/client-v2"),require("@nocobase/flow-engine")):e["@nocobase/plugin-ai-gigachat"]=t(e["@nocobase/plugin-ai/client-v2"],e.react,e.antd,e["@nocobase/client"],e["@nocobase/client-v2"],e["@nocobase/flow-engine"])}(self,function(e,t,n,r,o,i){return function(){"use strict";var a={342:function(e){e.exports=r},485:function(e){e.exports=o},694:function(e){e.exports=i},550:function(t){t.exports=e},59:function(e){e.exports=n},155:function(e){e.exports=t}},c={};function u(e){var t=c[e];if(void 0!==t)return t.exports;var n=c[e]={exports:{}};return a[e](n,n.exports,u),n.exports}u.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return u.d(t,{a:t}),t},u.d=function(e,t){for(var n in t)u.o(t,n)&&!u.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},u.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||Function("return this")()}catch(e){if("object"==typeof window)return window}}(),u.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},u.r=function(e){"u">typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},u.g.importScripts&&(l=u.g.location+"");var l,p=u.g.document;if(!l&&p&&(p.currentScript&&"SCRIPT"===p.currentScript.tagName.toUpperCase()&&(l=p.currentScript.src),!l)){var s=p.getElementsByTagName("script");if(s.length)for(var f=s.length-1;f>-1&&(!l||!/^http(s?):/.test(l));)l=s[f--].src}if(!l)throw Error("Automatic publicPath is not supported in this browser");u.p=l.replace(/^blob:/,"").replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/");var b={};return!function(){var e="",t="u">typeof document?document.currentScript:null;if(t&&t.src){var n=t.src.replace(/^blob:/,"").replace(/#.*$/,"").replace(/\?.*$/,"");n.indexOf("/static/plugins/@nocobase/plugin-ai-gigachat/dist/client/")>=0&&(e=n.replace(/\/[^\/]+$/,"/"))}if(!e){var r=window.__webpack_public_path__||"";r&&("/"!==r.charAt(r.length-1)&&(r+="/"),e=r+"static/plugins/@nocobase/plugin-ai-gigachat/dist/client/")}if(!e){var o=window.__nocobase_modern_client_prefix__||"v",i="/"+(o=String(o).replace(/^\/+|\/+$/g,"")||"v")+"/";if(!(e=window.__nocobase_public_path__||"")&&window.location&&window.location.pathname){var a=window.location.pathname||"/",c=a.indexOf(i);e=c>=0?a.slice(0,c+1):"/"}e&&(e=e.replace(RegExp("/"+o+"/?$"),"/")),e||(e="/"),"/"!==e.charAt(e.length-1)&&(e+="/"),e+="static/plugins/@nocobase/plugin-ai-gigachat/dist/client/"}u.p=e}(),!function(){u.r(b),u.d(b,{default:function(){return w},PluginAIGigaChatClient:function(){return h}});var e=u(342),t=u(155),n=u.n(t),r=u(59),o=u(485),i=u(694),a=[{label:"GIGACHAT_API_PERS",value:"GIGACHAT_API_PERS"},{label:"GIGACHAT_API_B2B",value:"GIGACHAT_API_B2B"},{label:"GIGACHAT_API_CORP",value:"GIGACHAT_API_CORP"}],c=function(e){return"".concat(e,":")},l={components:{ProviderSettingsForm:function(){var e,t=(e=(0,i.useFlowEngine)(),function(t,n){return e.context.t(t,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter(function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))),r.forEach(function(t){var r;r=n[t],t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r})}return e}({ns:["@nocobase/plugin-ai-gigachat","ai-gigachat","client"]},n))});return n().createElement(n().Fragment,null,n().createElement(r.Form.Item,{name:["options","apiKey"],label:c(t("Authorization key")),rules:[{required:!0}]},n().createElement(o.EnvVariableInput,{password:!0})),n().createElement(r.Form.Item,{name:["options","scope"],label:c(t("Scope")),rules:[{required:!0}]},n().createElement(r.Select,{options:a})),n().createElement(r.Form.Item,{name:["options","authURL"],label:c(t("Auth URL"))},n().createElement(o.EnvVariableInput,null)),n().createElement(r.Form.Item,{name:["options","enableSSL"],label:c(t("Verify certificates")),valuePropName:"checked",initialValue:!0},n().createElement(r.Checkbox,null)))},ModelSettingsForm:(0,u(550).createModelSettingsForm)([{name:"frequencyPenalty",title:"Frequency penalty",description:"Frequency penalty description",defaultValue:0,step:.1,min:-2,max:2},{name:"maxCompletionTokens",title:"Max completion tokens",description:"Max completion tokens description",defaultValue:-1},{name:"presencePenalty",title:"Presence penalty",description:"Presence penalty description",defaultValue:0,step:.1,min:-2,max:2},{name:"temperature",title:"Temperature",description:"Temperature description",defaultValue:.7,step:.1,min:0,max:1},{name:"topP",title:"Top P",description:"Top P description",defaultValue:1,step:.5,min:0,max:1},{name:"responseFormat",title:"Response format",description:"Response format description",defaultValue:"text",options:[{label:"Text",value:"text"},{label:"JSON",value:"json_object"}]},{name:"timeout",title:"Timeout (ms)",defaultValue:6e4},{name:"maxRetries",title:"Max retries",defaultValue:1}])}};function p(e,t,n,r,o,i,a){try{var c=e[i](a),u=c.value}catch(e){n(e);return}c.done?t(u):Promise.resolve(u).then(r,o)}function s(e){return function(){var t=this,n=arguments;return new Promise(function(r,o){var i=e.apply(t,n);function a(e){p(i,r,o,a,c,"next",e)}function c(e){p(i,r,o,a,c,"throw",e)}a(void 0)})}}function f(e,t,n){return(f=y()?Reflect.construct:function(e,t,n){var r=[null];r.push.apply(r,t);var o=new(Function.bind.apply(e,r));return n&&m(o,n.prototype),o}).apply(null,arguments)}function d(e){return(d=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function m(e,t){return(m=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function g(e){var t="function"==typeof Map?new Map:void 0;return(g=function(e){if(null===e||-1===Function.toString.call(e).indexOf("[native code]"))return e;if("function"!=typeof e)throw TypeError("Super expression must either be null or a function");if(void 0!==t){if(t.has(e))return t.get(e);t.set(e,n)}function n(){return f(e,arguments,d(this).constructor)}return n.prototype=Object.create(e.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}}),m(n,e)})(e)}function y(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(y=function(){return!!e})()}function v(e,t){var n,r,o,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),c=Object.defineProperty;return c(a,"next",{value:u(0)}),c(a,"throw",{value:u(1)}),c(a,"return",{value:u(2)}),"function"==typeof Symbol&&c(a,Symbol.iterator,{value:function(){return this}}),a;function u(c){return function(u){var l=[c,u];if(n)throw TypeError("Generator is already executing.");for(;a&&(a=0,l[0]&&(i=0)),i;)try{if(n=1,r&&(o=2&l[0]?r.return:l[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,l[1])).done)return o;switch(r=0,o&&(l=[2&l[0],o.value]),l[0]){case 0:case 1:o=l;break;case 4:return i.label++,{value:l[1],done:!1};case 5:i.label++,r=l[1],l=[0];continue;case 7:l=i.ops.pop(),i.trys.pop();continue;default:if(!(o=(o=i.trys).length>0&&o[o.length-1])&&(6===l[0]||2===l[0])){i=0;continue}if(3===l[0]&&(!o||l[1]>o[0]&&l[1]<o[3])){i.label=l[1];break}if(6===l[0]&&i.label<o[1]){i.label=o[1],o=l;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(l);break}o[2]&&i.ops.pop(),i.trys.pop();continue}l=t.call(e,i)}catch(e){l=[6,e],r=0}finally{n=o=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}}}var h=function(e){var t;if("function"!=typeof e&&null!==e)throw TypeError("Super expression must either be null or a function");function n(){var e,t;if(!(this instanceof n))throw TypeError("Cannot call a class as a function");return e=n,t=arguments,e=d(e),function(e,t){var n;if(t&&("object"==((n=t)&&"u">typeof Symbol&&n.constructor===Symbol?"symbol":typeof n)||"function"==typeof t))return t;if(void 0===e)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(this,y()?Reflect.construct(e,t||[],d(this).constructor):e.apply(this,t))}return n.prototype=Object.create(e&&e.prototype,{constructor:{value:n,writable:!0,configurable:!0}}),e&&m(n,e),t=[{key:"afterAdd",value:function(){return s(function(){return v(this,function(e){return[2]})})()}},{key:"beforeLoad",value:function(){return s(function(){return v(this,function(e){return[2]})})()}},{key:"load",value:function(){return s(function(){return v(this,function(e){return this.aiPlugin.aiManager.registerLLMProvider("gigachat",l),[2]})}).call(this)}},{key:"aiPlugin",get:function(){var e=this.app.pm.get("ai");if(!e)throw Error("plugin-ai is required before registering the GigaChat LLM provider");return e}}],function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}(n.prototype,t),n}(g(e.Plugin)),w=h}(),b}()});
10
+ !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("@nocobase/plugin-ai/client-v2"),require("react"),require("antd"),require("@nocobase/client"),require("@nocobase/client-v2"),require("@nocobase/flow-engine")):"function"==typeof define&&define.amd?define("@nocobase/plugin-ai-gigachat",["@nocobase/plugin-ai/client-v2","react","antd","@nocobase/client","@nocobase/client-v2","@nocobase/flow-engine"],t):"object"==typeof exports?exports["@nocobase/plugin-ai-gigachat"]=t(require("@nocobase/plugin-ai/client-v2"),require("react"),require("antd"),require("@nocobase/client"),require("@nocobase/client-v2"),require("@nocobase/flow-engine")):e["@nocobase/plugin-ai-gigachat"]=t(e["@nocobase/plugin-ai/client-v2"],e.react,e.antd,e["@nocobase/client"],e["@nocobase/client-v2"],e["@nocobase/flow-engine"])}(self,function(e,t,n,r,o,i){return function(){"use strict";var a={342:function(e){e.exports=r},485:function(e){e.exports=o},694:function(e){e.exports=i},550:function(t){t.exports=e},59:function(e){e.exports=n},155:function(e){e.exports=t}},c={};function u(e){var t=c[e];if(void 0!==t)return t.exports;var n=c[e]={exports:{}};return a[e](n,n.exports,u),n.exports}u.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return u.d(t,{a:t}),t},u.d=function(e,t){for(var n in t)u.o(t,n)&&!u.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},u.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||Function("return this")()}catch(e){if("object"==typeof window)return window}}(),u.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},u.r=function(e){"u">typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},u.g.importScripts&&(l=u.g.location+"");var l,p=u.g.document;if(!l&&p&&(p.currentScript&&"SCRIPT"===p.currentScript.tagName.toUpperCase()&&(l=p.currentScript.src),!l)){var s=p.getElementsByTagName("script");if(s.length)for(var f=s.length-1;f>-1&&(!l||!/^http(s?):/.test(l));)l=s[f--].src}if(!l)throw Error("Automatic publicPath is not supported in this browser");u.p=l.replace(/^blob:/,"").replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/");var b={};return!function(){var e="",t="u">typeof document?document.currentScript:null;if(t&&t.src){var n=t.src.replace(/^blob:/,"").replace(/#.*$/,"").replace(/\?.*$/,"");n.indexOf("/static/plugins/@nocobase/plugin-ai-gigachat/dist/client/")>=0&&(e=n.replace(/\/[^\/]+$/,"/"))}if(!e){var r=window.__webpack_public_path__||"";r&&("/"!==r.charAt(r.length-1)&&(r+="/"),e=r+"static/plugins/@nocobase/plugin-ai-gigachat/dist/client/")}if(!e){var o=window.__nocobase_modern_client_prefix__||"v",i="/"+(o=String(o).replace(/^\/+|\/+$/g,"")||"v")+"/";if(!(e=window.__nocobase_public_path__||"")&&window.location&&window.location.pathname){var a=window.location.pathname||"/",c=a.indexOf(i);e=c>=0?a.slice(0,c+1):"/"}e&&(e=e.replace(RegExp("/"+o+"/?$"),"/")),e||(e="/"),"/"!==e.charAt(e.length-1)&&(e+="/"),e+="static/plugins/@nocobase/plugin-ai-gigachat/dist/client/"}u.p=e}(),!function(){u.r(b),u.d(b,{default:function(){return P},PluginAIGigaChatClient:function(){return _}});var e=u(342),t=u(155),n=u.n(t),r=u(59),o=u(485),i=u(694),a=[{label:"GIGACHAT_API_PERS",value:"GIGACHAT_API_PERS"},{label:"GIGACHAT_API_B2B",value:"GIGACHAT_API_B2B"},{label:"GIGACHAT_API_CORP",value:"GIGACHAT_API_CORP"}],c=function(e){return"".concat(e,":")},l=u(550),p=[{name:"frequencyPenalty",title:"Frequency penalty",description:"Frequency penalty description",defaultValue:0,step:.1,min:-2,max:2},{name:"maxCompletionTokens",title:"Max completion tokens",description:"Max completion tokens description",defaultValue:-1},{name:"presencePenalty",title:"Presence penalty",description:"Presence penalty description",defaultValue:0,step:.1,min:-2,max:2},{name:"temperature",title:"Temperature",description:"Temperature description",defaultValue:.7,step:.1,min:0,max:1},{name:"topP",title:"Top P",description:"Top P description",defaultValue:1,step:.5,min:0,max:1},{name:"responseFormat",title:"Response format",description:"Response format description",defaultValue:"text",options:[{label:"Text",value:"text"},{label:"JSON",value:"json_object"}]},{name:"timeout",title:"Timeout (ms)",defaultValue:6e4},{name:"maxRetries",title:"Max retries",defaultValue:1}],s={components:{ProviderSettingsForm:function(){var e,t=(e=(0,i.useFlowEngine)(),function(t,n){return e.context.t(t,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter(function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))),r.forEach(function(t){var r;r=n[t],t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r})}return e}({ns:["@nocobase/plugin-ai-gigachat","ai-gigachat","client"]},n))});return n().createElement(n().Fragment,null,n().createElement(r.Form.Item,{name:["options","apiKey"],label:c(t("Authorization key")),rules:[{required:!0}]},n().createElement(o.EnvVariableInput,{password:!0})),n().createElement(r.Form.Item,{name:["options","scope"],label:c(t("Scope")),rules:[{required:!0}]},n().createElement(r.Select,{options:a})),n().createElement(r.Form.Item,{name:["options","authURL"],label:c(t("Auth URL"))},n().createElement(o.EnvVariableInput,null)),n().createElement(r.Form.Item,{name:["options","enableSSL"],label:c(t("Verify certificates")),valuePropName:"checked",initialValue:!0},n().createElement(r.Checkbox,null)))},ModelSettingsForm:function(){var e=(0,t.useMemo)(function(){return(0,l.createModelSettingsForm)(p)},[]);return n().createElement(e,null)}}};function f(e,t,n,r,o,i,a){try{var c=e[i](a),u=c.value}catch(e){n(e);return}c.done?t(u):Promise.resolve(u).then(r,o)}function m(e){return function(){var t=this,n=arguments;return new Promise(function(r,o){var i=e.apply(t,n);function a(e){f(i,r,o,a,c,"next",e)}function c(e){f(i,r,o,a,c,"throw",e)}a(void 0)})}}function d(e,t,n){return(d=h()?Reflect.construct:function(e,t,n){var r=[null];r.push.apply(r,t);var o=new(Function.bind.apply(e,r));return n&&y(o,n.prototype),o}).apply(null,arguments)}function g(e){return(g=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function y(e,t){return(y=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function v(e){var t="function"==typeof Map?new Map:void 0;return(v=function(e){if(null===e||-1===Function.toString.call(e).indexOf("[native code]"))return e;if("function"!=typeof e)throw TypeError("Super expression must either be null or a function");if(void 0!==t){if(t.has(e))return t.get(e);t.set(e,n)}function n(){return d(e,arguments,g(this).constructor)}return n.prototype=Object.create(e.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}}),y(n,e)})(e)}function h(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(h=function(){return!!e})()}function w(e,t){var n,r,o,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),c=Object.defineProperty;return c(a,"next",{value:u(0)}),c(a,"throw",{value:u(1)}),c(a,"return",{value:u(2)}),"function"==typeof Symbol&&c(a,Symbol.iterator,{value:function(){return this}}),a;function u(c){return function(u){var l=[c,u];if(n)throw TypeError("Generator is already executing.");for(;a&&(a=0,l[0]&&(i=0)),i;)try{if(n=1,r&&(o=2&l[0]?r.return:l[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,l[1])).done)return o;switch(r=0,o&&(l=[2&l[0],o.value]),l[0]){case 0:case 1:o=l;break;case 4:return i.label++,{value:l[1],done:!1};case 5:i.label++,r=l[1],l=[0];continue;case 7:l=i.ops.pop(),i.trys.pop();continue;default:if(!(o=(o=i.trys).length>0&&o[o.length-1])&&(6===l[0]||2===l[0])){i=0;continue}if(3===l[0]&&(!o||l[1]>o[0]&&l[1]<o[3])){i.label=l[1];break}if(6===l[0]&&i.label<o[1]){i.label=o[1],o=l;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(l);break}o[2]&&i.ops.pop(),i.trys.pop();continue}l=t.call(e,i)}catch(e){l=[6,e],r=0}finally{n=o=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}}}var _=function(e){var t;if("function"!=typeof e&&null!==e)throw TypeError("Super expression must either be null or a function");function n(){var e,t;if(!(this instanceof n))throw TypeError("Cannot call a class as a function");return e=n,t=arguments,e=g(e),function(e,t){var n;if(t&&("object"==((n=t)&&"u">typeof Symbol&&n.constructor===Symbol?"symbol":typeof n)||"function"==typeof t))return t;if(void 0===e)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(this,h()?Reflect.construct(e,t||[],g(this).constructor):e.apply(this,t))}return n.prototype=Object.create(e&&e.prototype,{constructor:{value:n,writable:!0,configurable:!0}}),e&&y(n,e),t=[{key:"afterAdd",value:function(){return m(function(){return w(this,function(e){return[2]})})()}},{key:"beforeLoad",value:function(){return m(function(){return w(this,function(e){return[2]})})()}},{key:"load",value:function(){return m(function(){return w(this,function(e){return this.aiPlugin.aiManager.registerLLMProvider("gigachat",s),[2]})}).call(this)}},{key:"aiPlugin",get:function(){var e=this.app.pm.get("ai");if(!e)throw Error("plugin-ai is required before registering the GigaChat LLM provider");return e}}],function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}(n.prototype,t),n}(v(e.Plugin)),P=_}(),b}()});
@@ -7,4 +7,4 @@
7
7
  * For more information, please refer to: https://www.nocobase.com/agreement.
8
8
  */
9
9
 
10
- !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("react"),require("antd"),require("@nocobase/client-v2"),require("@nocobase/flow-engine"),require("@nocobase/plugin-ai/client-v2")):"function"==typeof define&&define.amd?define("@nocobase/plugin-ai-gigachat/client-v2",["react","antd","@nocobase/client-v2","@nocobase/flow-engine","@nocobase/plugin-ai/client-v2"],t):"object"==typeof exports?exports["@nocobase/plugin-ai-gigachat/client-v2"]=t(require("react"),require("antd"),require("@nocobase/client-v2"),require("@nocobase/flow-engine"),require("@nocobase/plugin-ai/client-v2")):e["@nocobase/plugin-ai-gigachat/client-v2"]=t(e.react,e.antd,e["@nocobase/client-v2"],e["@nocobase/flow-engine"],e["@nocobase/plugin-ai/client-v2"])}(self,function(e,t,n,r,o){return function(){"use strict";var i={485:function(e){e.exports=n},694:function(e){e.exports=r},550:function(e){e.exports=o},59:function(e){e.exports=t},155:function(t){t.exports=e}},a={};function c(e){var t=a[e];if(void 0!==t)return t.exports;var n=a[e]={exports:{}};return i[e](n,n.exports,c),n.exports}c.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return c.d(t,{a:t}),t},c.d=function(e,t){for(var n in t)c.o(t,n)&&!c.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},c.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||Function("return this")()}catch(e){if("object"==typeof window)return window}}(),c.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},c.r=function(e){"u">typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},c.g.importScripts&&(u=c.g.location+"");var u,l=c.g.document;if(!u&&l&&(l.currentScript&&"SCRIPT"===l.currentScript.tagName.toUpperCase()&&(u=l.currentScript.src),!u)){var p=l.getElementsByTagName("script");if(p.length)for(var s=p.length-1;s>-1&&(!u||!/^http(s?):/.test(u));)u=p[s--].src}if(!u)throw Error("Automatic publicPath is not supported in this browser");c.p=u.replace(/^blob:/,"").replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/");var f={};return!function(){var e="",t="u">typeof document?document.currentScript:null;if(t&&t.src){var n=t.src.replace(/^blob:/,"").replace(/#.*$/,"").replace(/\?.*$/,"");n.indexOf("/static/plugins/@nocobase/plugin-ai-gigachat/dist/client-v2/")>=0&&(e=n.replace(/\/[^\/]+$/,"/"))}if(!e){var r=window.__webpack_public_path__||"";r&&("/"!==r.charAt(r.length-1)&&(r+="/"),e=r+"static/plugins/@nocobase/plugin-ai-gigachat/dist/client-v2/")}if(!e){var o=window.__nocobase_modern_client_prefix__||"v",i="/"+(o=String(o).replace(/^\/+|\/+$/g,"")||"v")+"/";if(!(e=window.__nocobase_public_path__||"")&&window.location&&window.location.pathname){var a=window.location.pathname||"/",u=a.indexOf(i);e=u>=0?a.slice(0,u+1):"/"}e&&(e=e.replace(RegExp("/"+o+"/?$"),"/")),e||(e="/"),"/"!==e.charAt(e.length-1)&&(e+="/"),e+="static/plugins/@nocobase/plugin-ai-gigachat/dist/client-v2/"}c.p=e}(),!function(){c.r(f),c.d(f,{gigachatProviderOptions:function(){return p},PluginAIGigaChatClientV2:function(){return y},default:function(){return h}});var e=c(485),t=c(550),n=c.n(t),r=c(155),o=c.n(r),i=c(59),a=c(694),u=[{label:"GIGACHAT_API_PERS",value:"GIGACHAT_API_PERS"},{label:"GIGACHAT_API_B2B",value:"GIGACHAT_API_B2B"},{label:"GIGACHAT_API_CORP",value:"GIGACHAT_API_CORP"}],l=function(e){return"".concat(e,":")},p={components:{ProviderSettingsForm:function(){var t,n=(t=(0,a.useFlowEngine)(),function(e,n){return t.context.t(e,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter(function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))),r.forEach(function(t){var r;r=n[t],t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r})}return e}({ns:["@nocobase/plugin-ai-gigachat","ai-gigachat","client"]},n))});return o().createElement(o().Fragment,null,o().createElement(i.Form.Item,{name:["options","apiKey"],label:l(n("Authorization key")),rules:[{required:!0}]},o().createElement(e.EnvVariableInput,{password:!0})),o().createElement(i.Form.Item,{name:["options","scope"],label:l(n("Scope")),rules:[{required:!0}]},o().createElement(i.Select,{options:u})),o().createElement(i.Form.Item,{name:["options","authURL"],label:l(n("Auth URL"))},o().createElement(e.EnvVariableInput,null)),o().createElement(i.Form.Item,{name:["options","enableSSL"],label:l(n("Verify certificates")),valuePropName:"checked",initialValue:!0},o().createElement(i.Checkbox,null)))},ModelSettingsForm:(0,t.createModelSettingsForm)([{name:"frequencyPenalty",title:"Frequency penalty",description:"Frequency penalty description",defaultValue:0,step:.1,min:-2,max:2},{name:"maxCompletionTokens",title:"Max completion tokens",description:"Max completion tokens description",defaultValue:-1},{name:"presencePenalty",title:"Presence penalty",description:"Presence penalty description",defaultValue:0,step:.1,min:-2,max:2},{name:"temperature",title:"Temperature",description:"Temperature description",defaultValue:.7,step:.1,min:0,max:1},{name:"topP",title:"Top P",description:"Top P description",defaultValue:1,step:.5,min:0,max:1},{name:"responseFormat",title:"Response format",description:"Response format description",defaultValue:"text",options:[{label:"Text",value:"text"},{label:"JSON",value:"json_object"}]},{name:"timeout",title:"Timeout (ms)",defaultValue:6e4},{name:"maxRetries",title:"Max retries",defaultValue:1}])}};function s(e,t,n,r,o,i,a){try{var c=e[i](a),u=c.value}catch(e){n(e);return}c.done?t(u):Promise.resolve(u).then(r,o)}function b(e,t,n){return(b=v()?Reflect.construct:function(e,t,n){var r=[null];r.push.apply(r,t);var o=new(Function.bind.apply(e,r));return n&&m(o,n.prototype),o}).apply(null,arguments)}function g(e){return(g=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function m(e,t){return(m=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function d(e){var t="function"==typeof Map?new Map:void 0;return(d=function(e){if(null===e||-1===Function.toString.call(e).indexOf("[native code]"))return e;if("function"!=typeof e)throw TypeError("Super expression must either be null or a function");if(void 0!==t){if(t.has(e))return t.get(e);t.set(e,n)}function n(){return b(e,arguments,g(this).constructor)}return n.prototype=Object.create(e.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}}),m(n,e)})(e)}function v(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(v=function(){return!!e})()}var y=function(e){var t;if("function"!=typeof e&&null!==e)throw TypeError("Super expression must either be null or a function");function r(){var e,t;if(!(this instanceof r))throw TypeError("Cannot call a class as a function");return e=r,t=arguments,e=g(e),function(e,t){var n;if(t&&("object"==((n=t)&&"u">typeof Symbol&&n.constructor===Symbol?"symbol":typeof n)||"function"==typeof t))return t;if(void 0===e)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(this,v()?Reflect.construct(e,t||[],g(this).constructor):e.apply(this,t))}return r.prototype=Object.create(e&&e.prototype,{constructor:{value:r,writable:!0,configurable:!0}}),e&&m(r,e),t=[{key:"load",value:function(){var e;return(e=function(){return function(e,t){var n,r,o,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),c=Object.defineProperty;return c(a,"next",{value:u(0)}),c(a,"throw",{value:u(1)}),c(a,"return",{value:u(2)}),"function"==typeof Symbol&&c(a,Symbol.iterator,{value:function(){return this}}),a;function u(c){return function(u){var l=[c,u];if(n)throw TypeError("Generator is already executing.");for(;a&&(a=0,l[0]&&(i=0)),i;)try{if(n=1,r&&(o=2&l[0]?r.return:l[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,l[1])).done)return o;switch(r=0,o&&(l=[2&l[0],o.value]),l[0]){case 0:case 1:o=l;break;case 4:return i.label++,{value:l[1],done:!1};case 5:i.label++,r=l[1],l=[0];continue;case 7:l=i.ops.pop(),i.trys.pop();continue;default:if(!(o=(o=i.trys).length>0&&o[o.length-1])&&(6===l[0]||2===l[0])){i=0;continue}if(3===l[0]&&(!o||l[1]>o[0]&&l[1]<o[3])){i.label=l[1];break}if(6===l[0]&&i.label<o[1]){i.label=o[1],o=l;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(l);break}o[2]&&i.ops.pop(),i.trys.pop();continue}l=t.call(e,i)}catch(e){l=[6,e],r=0}finally{n=o=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}}}(this,function(e){return this.aiPlugin.aiManager.registerLLMProvider("gigachat",p),[2]})},function(){var t=this,n=arguments;return new Promise(function(r,o){var i=e.apply(t,n);function a(e){s(i,r,o,a,c,"next",e)}function c(e){s(i,r,o,a,c,"throw",e)}a(void 0)})}).call(this)}},{key:"aiPlugin",get:function(){var e,t=null!=(e=this.app.pm.get("ai"))?e:this.app.pm.get(n());if(!t)throw Error("plugin-ai is required before registering the GigaChat LLM provider");return t}}],function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}(r.prototype,t),r}(d(e.Plugin)),h=y}(),f}()});
10
+ !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("react"),require("antd"),require("@nocobase/client-v2"),require("@nocobase/flow-engine"),require("@nocobase/plugin-ai/client-v2")):"function"==typeof define&&define.amd?define("@nocobase/plugin-ai-gigachat/client-v2",["react","antd","@nocobase/client-v2","@nocobase/flow-engine","@nocobase/plugin-ai/client-v2"],t):"object"==typeof exports?exports["@nocobase/plugin-ai-gigachat/client-v2"]=t(require("react"),require("antd"),require("@nocobase/client-v2"),require("@nocobase/flow-engine"),require("@nocobase/plugin-ai/client-v2")):e["@nocobase/plugin-ai-gigachat/client-v2"]=t(e.react,e.antd,e["@nocobase/client-v2"],e["@nocobase/flow-engine"],e["@nocobase/plugin-ai/client-v2"])}(self,function(e,t,n,r,o){return function(){"use strict";var i={485:function(e){e.exports=n},694:function(e){e.exports=r},550:function(e){e.exports=o},59:function(e){e.exports=t},155:function(t){t.exports=e}},a={};function c(e){var t=a[e];if(void 0!==t)return t.exports;var n=a[e]={exports:{}};return i[e](n,n.exports,c),n.exports}c.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return c.d(t,{a:t}),t},c.d=function(e,t){for(var n in t)c.o(t,n)&&!c.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},c.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||Function("return this")()}catch(e){if("object"==typeof window)return window}}(),c.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},c.r=function(e){"u">typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},c.g.importScripts&&(u=c.g.location+"");var u,l=c.g.document;if(!u&&l&&(l.currentScript&&"SCRIPT"===l.currentScript.tagName.toUpperCase()&&(u=l.currentScript.src),!u)){var p=l.getElementsByTagName("script");if(p.length)for(var s=p.length-1;s>-1&&(!u||!/^http(s?):/.test(u));)u=p[s--].src}if(!u)throw Error("Automatic publicPath is not supported in this browser");c.p=u.replace(/^blob:/,"").replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/");var f={};return!function(){var e="",t="u">typeof document?document.currentScript:null;if(t&&t.src){var n=t.src.replace(/^blob:/,"").replace(/#.*$/,"").replace(/\?.*$/,"");n.indexOf("/static/plugins/@nocobase/plugin-ai-gigachat/dist/client-v2/")>=0&&(e=n.replace(/\/[^\/]+$/,"/"))}if(!e){var r=window.__webpack_public_path__||"";r&&("/"!==r.charAt(r.length-1)&&(r+="/"),e=r+"static/plugins/@nocobase/plugin-ai-gigachat/dist/client-v2/")}if(!e){var o=window.__nocobase_modern_client_prefix__||"v",i="/"+(o=String(o).replace(/^\/+|\/+$/g,"")||"v")+"/";if(!(e=window.__nocobase_public_path__||"")&&window.location&&window.location.pathname){var a=window.location.pathname||"/",u=a.indexOf(i);e=u>=0?a.slice(0,u+1):"/"}e&&(e=e.replace(RegExp("/"+o+"/?$"),"/")),e||(e="/"),"/"!==e.charAt(e.length-1)&&(e+="/"),e+="static/plugins/@nocobase/plugin-ai-gigachat/dist/client-v2/"}c.p=e}(),!function(){c.r(f),c.d(f,{gigachatProviderOptions:function(){return s},PluginAIGigaChatClientV2:function(){return h},default:function(){return w}});var e=c(485),t=c(550),n=c.n(t),r=c(155),o=c.n(r),i=c(59),a=c(694),u=[{label:"GIGACHAT_API_PERS",value:"GIGACHAT_API_PERS"},{label:"GIGACHAT_API_B2B",value:"GIGACHAT_API_B2B"},{label:"GIGACHAT_API_CORP",value:"GIGACHAT_API_CORP"}],l=function(e){return"".concat(e,":")},p=[{name:"frequencyPenalty",title:"Frequency penalty",description:"Frequency penalty description",defaultValue:0,step:.1,min:-2,max:2},{name:"maxCompletionTokens",title:"Max completion tokens",description:"Max completion tokens description",defaultValue:-1},{name:"presencePenalty",title:"Presence penalty",description:"Presence penalty description",defaultValue:0,step:.1,min:-2,max:2},{name:"temperature",title:"Temperature",description:"Temperature description",defaultValue:.7,step:.1,min:0,max:1},{name:"topP",title:"Top P",description:"Top P description",defaultValue:1,step:.5,min:0,max:1},{name:"responseFormat",title:"Response format",description:"Response format description",defaultValue:"text",options:[{label:"Text",value:"text"},{label:"JSON",value:"json_object"}]},{name:"timeout",title:"Timeout (ms)",defaultValue:6e4},{name:"maxRetries",title:"Max retries",defaultValue:1}],s={components:{ProviderSettingsForm:function(){var t,n=(t=(0,a.useFlowEngine)(),function(e,n){return t.context.t(e,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter(function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))),r.forEach(function(t){var r;r=n[t],t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r})}return e}({ns:["@nocobase/plugin-ai-gigachat","ai-gigachat","client"]},n))});return o().createElement(o().Fragment,null,o().createElement(i.Form.Item,{name:["options","apiKey"],label:l(n("Authorization key")),rules:[{required:!0}]},o().createElement(e.EnvVariableInput,{password:!0})),o().createElement(i.Form.Item,{name:["options","scope"],label:l(n("Scope")),rules:[{required:!0}]},o().createElement(i.Select,{options:u})),o().createElement(i.Form.Item,{name:["options","authURL"],label:l(n("Auth URL"))},o().createElement(e.EnvVariableInput,null)),o().createElement(i.Form.Item,{name:["options","enableSSL"],label:l(n("Verify certificates")),valuePropName:"checked",initialValue:!0},o().createElement(i.Checkbox,null)))},ModelSettingsForm:function(){var e=(0,r.useMemo)(function(){return(0,t.createModelSettingsForm)(p)},[]);return o().createElement(e,null)}}};function b(e,t,n,r,o,i,a){try{var c=e[i](a),u=c.value}catch(e){n(e);return}c.done?t(u):Promise.resolve(u).then(r,o)}function m(e,t,n){return(m=y()?Reflect.construct:function(e,t,n){var r=[null];r.push.apply(r,t);var o=new(Function.bind.apply(e,r));return n&&d(o,n.prototype),o}).apply(null,arguments)}function g(e){return(g=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function d(e,t){return(d=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function v(e){var t="function"==typeof Map?new Map:void 0;return(v=function(e){if(null===e||-1===Function.toString.call(e).indexOf("[native code]"))return e;if("function"!=typeof e)throw TypeError("Super expression must either be null or a function");if(void 0!==t){if(t.has(e))return t.get(e);t.set(e,n)}function n(){return m(e,arguments,g(this).constructor)}return n.prototype=Object.create(e.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}}),d(n,e)})(e)}function y(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(y=function(){return!!e})()}var h=function(e){var t;if("function"!=typeof e&&null!==e)throw TypeError("Super expression must either be null or a function");function r(){var e,t;if(!(this instanceof r))throw TypeError("Cannot call a class as a function");return e=r,t=arguments,e=g(e),function(e,t){var n;if(t&&("object"==((n=t)&&"u">typeof Symbol&&n.constructor===Symbol?"symbol":typeof n)||"function"==typeof t))return t;if(void 0===e)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(this,y()?Reflect.construct(e,t||[],g(this).constructor):e.apply(this,t))}return r.prototype=Object.create(e&&e.prototype,{constructor:{value:r,writable:!0,configurable:!0}}),e&&d(r,e),t=[{key:"load",value:function(){var e;return(e=function(){return function(e,t){var n,r,o,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),c=Object.defineProperty;return c(a,"next",{value:u(0)}),c(a,"throw",{value:u(1)}),c(a,"return",{value:u(2)}),"function"==typeof Symbol&&c(a,Symbol.iterator,{value:function(){return this}}),a;function u(c){return function(u){var l=[c,u];if(n)throw TypeError("Generator is already executing.");for(;a&&(a=0,l[0]&&(i=0)),i;)try{if(n=1,r&&(o=2&l[0]?r.return:l[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,l[1])).done)return o;switch(r=0,o&&(l=[2&l[0],o.value]),l[0]){case 0:case 1:o=l;break;case 4:return i.label++,{value:l[1],done:!1};case 5:i.label++,r=l[1],l=[0];continue;case 7:l=i.ops.pop(),i.trys.pop();continue;default:if(!(o=(o=i.trys).length>0&&o[o.length-1])&&(6===l[0]||2===l[0])){i=0;continue}if(3===l[0]&&(!o||l[1]>o[0]&&l[1]<o[3])){i.label=l[1];break}if(6===l[0]&&i.label<o[1]){i.label=o[1],o=l;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(l);break}o[2]&&i.ops.pop(),i.trys.pop();continue}l=t.call(e,i)}catch(e){l=[6,e],r=0}finally{n=o=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}}}(this,function(e){return this.aiPlugin.aiManager.registerLLMProvider("gigachat",s),[2]})},function(){var t=this,n=arguments;return new Promise(function(r,o){var i=e.apply(t,n);function a(e){b(i,r,o,a,c,"next",e)}function c(e){b(i,r,o,a,c,"throw",e)}a(void 0)})}).call(this)}},{key:"aiPlugin",get:function(){var e,t=null!=(e=this.app.pm.get("ai"))?e:this.app.pm.get(n());if(!t)throw Error("plugin-ai is required before registering the GigaChat LLM provider");return t}}],function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}(r.prototype,t),r}(v(e.Plugin)),w=h}(),f}()});
@@ -6,5 +6,5 @@
6
6
  * This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
7
7
  * For more information, please refer to: https://www.nocobase.com/agreement.
8
8
  */
9
- /// <reference types="react" />
10
- export declare const ModelSettingsForm: import("react").FC<{}>;
9
+ import React from 'react';
10
+ export declare const ModelSettingsForm: React.FC;
@@ -8,11 +8,11 @@
8
8
  */
9
9
 
10
10
  module.exports = {
11
- "@nocobase/client": "2.2.2",
12
- "@nocobase/flow-engine": "2.2.2",
13
- "@nocobase/client-v2": "2.2.2",
14
- "@nocobase/plugin-ai": "2.2.2",
15
- "@nocobase/server": "2.2.2",
11
+ "@nocobase/client": "2.2.3",
12
+ "@nocobase/flow-engine": "2.2.3",
13
+ "@nocobase/client-v2": "2.2.3",
14
+ "@nocobase/plugin-ai": "2.2.3",
15
+ "@nocobase/server": "2.2.3",
16
16
  "react": "18.2.0",
17
17
  "antd": "5.24.2"
18
18
  };
@@ -1 +1 @@
1
- {"name":"gigachat","version":"0.0.15","description":"The official TypeScript library for the GigaChat API","types":"./index.d.ts","main":"./index.js","type":"commonjs","repository":"github:ai-forever/gigachat-js","scripts":{"format":"prettier --write --cache --cache-strategy metadata . !dist","lint":"./scripts/lint","fix":"./scripts/format","build":"./scripts/build"},"private":false,"keywords":[],"author":"","license":"ISC","dependencies":{"axios":"^1.8.2","uuid":"^11.0.3"},"imports":{"gigachat":".","gigachat/*":"./src/*"},"exports":{".":{"require":{"types":"./index.d.ts","default":"./index.js"},"types":"./index.d.mts","default":"./index.mjs"},"./*.mjs":{"types":"./*.d.ts","default":"./*.mjs"},"./*.js":{"types":"./*.d.ts","default":"./*.js"},"./interfaces/*":{"types":"./interfaces/*.d.ts","require":"./interfaces/*.js","default":"./interfaces/*.mjs"},"./interfaces":{"types":"./interfaces/index.d.ts","require":"./interfaces/index.js","default":"./interfaces/index.mjs"},"./*":{"types":"./*.d.ts","require":"./*.js","default":"./*.mjs"}},"_lastModified":"2026-08-25T15:15:54.301Z"}
1
+ {"name":"gigachat","version":"0.0.15","description":"The official TypeScript library for the GigaChat API","types":"./index.d.ts","main":"./index.js","type":"commonjs","repository":"github:ai-forever/gigachat-js","scripts":{"format":"prettier --write --cache --cache-strategy metadata . !dist","lint":"./scripts/lint","fix":"./scripts/format","build":"./scripts/build"},"private":false,"keywords":[],"author":"","license":"ISC","dependencies":{"axios":"^1.8.2","uuid":"^11.0.3"},"imports":{"gigachat":".","gigachat/*":"./src/*"},"exports":{".":{"require":{"types":"./index.d.ts","default":"./index.js"},"types":"./index.d.mts","default":"./index.mjs"},"./*.mjs":{"types":"./*.d.ts","default":"./*.mjs"},"./*.js":{"types":"./*.d.ts","default":"./*.js"},"./interfaces/*":{"types":"./interfaces/*.d.ts","require":"./interfaces/*.js","default":"./interfaces/*.mjs"},"./interfaces":{"types":"./interfaces/index.d.ts","require":"./interfaces/index.js","default":"./interfaces/index.mjs"},"./*":{"types":"./*.d.ts","require":"./*.js","default":"./*.mjs"}},"_lastModified":"2026-08-26T14:31:47.009Z"}
@@ -1 +1 @@
1
- {"name":"langchain-gigachat","version":"0.0.14","description":"GigaChat integration for LangChain.js","type":"module","engines":{"node":">=18"},"main":"./index.js","types":"./index.d.ts","repository":{"type":"git","url":"https://github.com/ai-forever/langchainjs/tree/main/libs/langchain-gigachat"},"packageManager":"yarn@3.4.1","homepage":"https://github.com/ai-forever/langchainjs/tree/main/libs/langchain-gigachat","scripts":{"build":"yarn turbo:command build:internal --filter=langchain-gigachat","build:internal":"yarn lc_build --create-entrypoints --pre --tree-shaking","lint:eslint":"NODE_OPTIONS=--max-old-space-size=4096 eslint --cache --ext .ts,.js src/","lint:dpdm":"dpdm --exit-code circular:1 --no-warning --no-tree src/*.ts src/**/*.ts","lint":"yarn lint:eslint && yarn lint:dpdm","lint:fix":"yarn lint:eslint --fix && yarn lint:dpdm","clean":"rm -rf .turbo dist/","prepack":"yarn build","test":"NODE_OPTIONS=--experimental-vm-modules jest --testPathIgnorePatterns=\\.int\\.test.ts --testTimeout 30000 --maxWorkers=50%","test:watch":"NODE_OPTIONS=--experimental-vm-modules jest --watch --testPathIgnorePatterns=\\.int\\.test.ts","test:single":"NODE_OPTIONS=--experimental-vm-modules yarn run jest --config jest.config.cjs --testTimeout 100000","test:int":"NODE_OPTIONS=--experimental-vm-modules jest --testPathPattern=\\.int\\.test.ts --testTimeout 100000 --maxWorkers=50%","format":"prettier --config .prettierrc --write \"src\"","format:check":"prettier --config .prettierrc --check \"src\""},"author":"Mikelarg","license":"MIT","keywords":["llm","ai","gpt3","chain","prompt","prompt engineering","gigachat","machine learning","ml","embeddings","vectorstores"],"dependencies":{"gigachat":"^0.0.15","uuid":"^11.0.5","zod":"^3.23.8","zod-to-json-schema":"^3.23.5"},"peerDependencies":{"@langchain/core":">=0.2.21 <0.4.0"},"devDependencies":{"@jest/globals":"^29.5.0","@langchain/core":"workspace:*","@langchain/scripts":">=0.1.0 <0.2.0","@swc/core":"^1.3.90","@swc/jest":"^0.2.29","@tsconfig/recommended":"^1.0.3","@typescript-eslint/eslint-plugin":"^6.12.0","@typescript-eslint/parser":"^6.12.0","dotenv":"^16.3.1","dpdm":"^3.12.0","eslint":"^8.33.0","eslint-config-airbnb-base":"^15.0.0","eslint-config-prettier":"^8.6.0","eslint-plugin-import":"^2.27.5","eslint-plugin-no-instanceof":"^1.0.1","eslint-plugin-prettier":"^4.2.1","jest":"^29.5.0","jest-environment-node":"^29.6.4","prettier":"^2.8.3","release-it":"^15.10.1","rollup":"4.22.4","ts-jest":"^29.1.0","turbo":"^2.3.2","typescript":"<5.2.0"},"publishConfig":{"access":"public"},"exports":{"./chat_models":{"types":{"import":"./chat_models.d.ts","require":"./chat_models.d.cts","default":"./chat_models.d.ts"},"import":"./chat_models.js","require":"./chat_models.cjs"},"./embeddings":{"types":{"import":"./embeddings.d.ts","require":"./embeddings.d.cts","default":"./embeddings.d.ts"},"import":"./embeddings.js","require":"./embeddings.cjs"},".":{"types":{"import":"./index.d.ts","require":"./index.d.cts","default":"./index.d.ts"},"import":"./index.js","require":"./index.cjs"},"./package.json":"./package.json"},"files":["dist/","chat_models.cjs","chat_models.js","chat_models.d.ts","chat_models.d.cts","embeddings.cjs","embeddings.js","embeddings.d.ts","embeddings.d.cts","index.cjs","index.js","index.d.ts","index.d.cts"],"_lastModified":"2026-08-25T15:15:58.804Z"}
1
+ {"name":"langchain-gigachat","version":"0.0.14","description":"GigaChat integration for LangChain.js","type":"module","engines":{"node":">=18"},"main":"./index.js","types":"./index.d.ts","repository":{"type":"git","url":"https://github.com/ai-forever/langchainjs/tree/main/libs/langchain-gigachat"},"packageManager":"yarn@3.4.1","homepage":"https://github.com/ai-forever/langchainjs/tree/main/libs/langchain-gigachat","scripts":{"build":"yarn turbo:command build:internal --filter=langchain-gigachat","build:internal":"yarn lc_build --create-entrypoints --pre --tree-shaking","lint:eslint":"NODE_OPTIONS=--max-old-space-size=4096 eslint --cache --ext .ts,.js src/","lint:dpdm":"dpdm --exit-code circular:1 --no-warning --no-tree src/*.ts src/**/*.ts","lint":"yarn lint:eslint && yarn lint:dpdm","lint:fix":"yarn lint:eslint --fix && yarn lint:dpdm","clean":"rm -rf .turbo dist/","prepack":"yarn build","test":"NODE_OPTIONS=--experimental-vm-modules jest --testPathIgnorePatterns=\\.int\\.test.ts --testTimeout 30000 --maxWorkers=50%","test:watch":"NODE_OPTIONS=--experimental-vm-modules jest --watch --testPathIgnorePatterns=\\.int\\.test.ts","test:single":"NODE_OPTIONS=--experimental-vm-modules yarn run jest --config jest.config.cjs --testTimeout 100000","test:int":"NODE_OPTIONS=--experimental-vm-modules jest --testPathPattern=\\.int\\.test.ts --testTimeout 100000 --maxWorkers=50%","format":"prettier --config .prettierrc --write \"src\"","format:check":"prettier --config .prettierrc --check \"src\""},"author":"Mikelarg","license":"MIT","keywords":["llm","ai","gpt3","chain","prompt","prompt engineering","gigachat","machine learning","ml","embeddings","vectorstores"],"dependencies":{"gigachat":"^0.0.15","uuid":"^11.0.5","zod":"^3.23.8","zod-to-json-schema":"^3.23.5"},"peerDependencies":{"@langchain/core":">=0.2.21 <0.4.0"},"devDependencies":{"@jest/globals":"^29.5.0","@langchain/core":"workspace:*","@langchain/scripts":">=0.1.0 <0.2.0","@swc/core":"^1.3.90","@swc/jest":"^0.2.29","@tsconfig/recommended":"^1.0.3","@typescript-eslint/eslint-plugin":"^6.12.0","@typescript-eslint/parser":"^6.12.0","dotenv":"^16.3.1","dpdm":"^3.12.0","eslint":"^8.33.0","eslint-config-airbnb-base":"^15.0.0","eslint-config-prettier":"^8.6.0","eslint-plugin-import":"^2.27.5","eslint-plugin-no-instanceof":"^1.0.1","eslint-plugin-prettier":"^4.2.1","jest":"^29.5.0","jest-environment-node":"^29.6.4","prettier":"^2.8.3","release-it":"^15.10.1","rollup":"4.22.4","ts-jest":"^29.1.0","turbo":"^2.3.2","typescript":"<5.2.0"},"publishConfig":{"access":"public"},"exports":{"./chat_models":{"types":{"import":"./chat_models.d.ts","require":"./chat_models.d.cts","default":"./chat_models.d.ts"},"import":"./chat_models.js","require":"./chat_models.cjs"},"./embeddings":{"types":{"import":"./embeddings.d.ts","require":"./embeddings.d.cts","default":"./embeddings.d.ts"},"import":"./embeddings.js","require":"./embeddings.cjs"},".":{"types":{"import":"./index.d.ts","require":"./index.d.cts","default":"./index.d.ts"},"import":"./index.js","require":"./index.cjs"},"./package.json":"./package.json"},"files":["dist/","chat_models.cjs","chat_models.js","chat_models.d.ts","chat_models.d.cts","embeddings.cjs","embeddings.js","embeddings.d.ts","embeddings.d.cts","index.cjs","index.js","index.d.ts","index.d.cts"],"_lastModified":"2026-08-26T14:31:50.675Z"}
package/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "displayName.zh-CN": "AI LLM:GigaChat",
5
5
  "description": "Support integration with GigaChat LLM service.",
6
6
  "description.zh-CN": "支持接入 GigaChat LLM 服务。",
7
- "version": "2.2.2",
7
+ "version": "2.2.3",
8
8
  "main": "dist/server/index.js",
9
9
  "nocobase": {
10
10
  "supportedVersions": [
@@ -26,5 +26,5 @@
26
26
  "AI"
27
27
  ],
28
28
  "license": "Apache-2.0",
29
- "gitHead": "336230738dda76255e363a0a68fcbec775c81564"
29
+ "gitHead": "b33d7d64ce7d601ade9f4957a4d058acd56a3454"
30
30
  }