@kwirthmagnify/kwirth-common-ai 0.5.63 → 0.5.64

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 ADDED
@@ -0,0 +1,18 @@
1
+ # @kwirthmagnify/kwirth-common-ai
2
+
3
+ Shared AI/LLM types and utilities for [Kwirth](https://kwirthmagnify.dev) AI plugins.
4
+
5
+ ## What is this?
6
+
7
+ This package contains the TypeScript interfaces and utilities for working with LLM providers and models in Kwirth: `ILlm`, `IProvider`, `IModel`, `buildModel`, `loadModels`, and related types.
8
+
9
+ ## Installation
10
+
11
+ ```bash
12
+ npm install @kwirthmagnify/kwirth-common-ai
13
+ ```
14
+
15
+ ## Links
16
+
17
+ - **Kwirth**: https://kwirthmagnify.dev
18
+ - **Repository**: https://github.com/kwirthmagnify/kwirth
package/dist/front.js CHANGED
@@ -198,11 +198,11 @@ const AiConfigLlm = (props) => {
198
198
  reader.readAsText(f);
199
199
  e.target.value = '';
200
200
  } }),
201
- react_1.default.createElement(material_1.Button, { startIcon: react_1.default.createElement(Upload_1.default, { fontSize: 'small' }), onClick: () => { var _a; return (_a = importLlmRef.current) === null || _a === void 0 ? void 0 : _a.click(); } }, "Import"),
202
- react_1.default.createElement(material_1.Button, { startIcon: react_1.default.createElement(Download_1.default, { fontSize: 'small' }), onClick: () => downloadJson(llms, 'kwirth-llms.json') }, "Export"),
201
+ react_1.default.createElement(material_1.Button, { variant: 'outlined', startIcon: react_1.default.createElement(Upload_1.default, { fontSize: 'small' }), onClick: () => { var _a; return (_a = importLlmRef.current) === null || _a === void 0 ? void 0 : _a.click(); } }, "Import"),
202
+ react_1.default.createElement(material_1.Button, { variant: 'outlined', startIcon: react_1.default.createElement(Download_1.default, { fontSize: 'small' }), onClick: () => downloadJson(llms, 'kwirth-llms.json') }, "Export"),
203
203
  react_1.default.createElement(material_1.Box, { flex: 1 }),
204
204
  react_1.default.createElement(material_1.Button, { onClick: () => props.onClose(llms), variant: 'contained' }, "OK"),
205
- react_1.default.createElement(material_1.Button, { onClick: () => props.onClose(undefined), color: 'inherit' }, "Cancel"))));
205
+ react_1.default.createElement(material_1.Button, { onClick: () => props.onClose(undefined), variant: 'outlined' }, "Cancel"))));
206
206
  };
207
207
  exports.AiConfigLlm = AiConfigLlm;
208
208
  const AiConfigProvider = (props) => {
@@ -327,11 +327,11 @@ const AiConfigProvider = (props) => {
327
327
  reader.readAsText(f);
328
328
  e.target.value = '';
329
329
  } }),
330
- react_1.default.createElement(material_1.Button, { startIcon: react_1.default.createElement(Upload_1.default, { fontSize: 'small' }), onClick: () => { var _a; return (_a = importProvRef.current) === null || _a === void 0 ? void 0 : _a.click(); } }, "Import"),
331
- react_1.default.createElement(material_1.Button, { startIcon: react_1.default.createElement(Download_1.default, { fontSize: 'small' }), onClick: () => downloadJson(providers.map(p => { var _a; return (Object.assign({ name: p.name, type: (_a = p.type) !== null && _a !== void 0 ? _a : p.name, key: p.key }, (p.endpoint ? { endpoint: p.endpoint } : {}))); }), 'kwirth-providers.json') }, "Export"),
330
+ react_1.default.createElement(material_1.Button, { variant: 'outlined', startIcon: react_1.default.createElement(Upload_1.default, { fontSize: 'small' }), onClick: () => { var _a; return (_a = importProvRef.current) === null || _a === void 0 ? void 0 : _a.click(); } }, "Import"),
331
+ react_1.default.createElement(material_1.Button, { variant: 'outlined', startIcon: react_1.default.createElement(Download_1.default, { fontSize: 'small' }), onClick: () => downloadJson(providers.map(p => { var _a; return (Object.assign({ name: p.name, type: (_a = p.type) !== null && _a !== void 0 ? _a : p.name, key: p.key }, (p.endpoint ? { endpoint: p.endpoint } : {}))); }), 'kwirth-providers.json') }, "Export"),
332
332
  react_1.default.createElement(material_1.Box, { flex: 1 }),
333
- react_1.default.createElement(material_1.Button, { onClick: () => props.onClose(providers), color: 'primary', variant: 'contained' }, "Save"),
334
- react_1.default.createElement(material_1.Button, { onClick: () => props.onClose(undefined), color: 'inherit' }, "Cancel"))));
333
+ react_1.default.createElement(material_1.Button, { onClick: () => props.onClose(providers), variant: 'contained' }, "Save"),
334
+ react_1.default.createElement(material_1.Button, { onClick: () => props.onClose(undefined), variant: 'outlined' }, "Cancel"))));
335
335
  };
336
336
  exports.AiConfigProvider = AiConfigProvider;
337
337
  const ToolSelector = ({ tools, selected, autoTools, disabled, onChange }) => (react_1.default.createElement(material_1.Stack, { direction: 'row', alignItems: 'flex-end', spacing: 1, sx: { width: '100%' } },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kwirthmagnify/kwirth-common-ai",
3
- "version": "0.5.63",
3
+ "version": "0.5.64",
4
4
  "description": "Shared AI/LLM types and utilities for Kwirth AI plugins",
5
5
  "scripts": {
6
6
  "build": "del .\\dist\\* /s /q 2>nul & tsc",