@do-kit/agents 0.2.2 → 0.2.4

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.
@@ -1,5 +1,10 @@
1
- import * as _ai_sdk_deepseek from '@ai-sdk/deepseek';
2
1
  import { streamText } from 'ai';
2
+ import { createDeepSeek } from '@ai-sdk/deepseek';
3
+
4
+ /**
5
+ * @desc augmentAgent to ai
6
+ * @auth mee-student
7
+ */
3
8
 
4
9
  type AugmentOptions = {
5
10
  model: any;
@@ -8,7 +13,7 @@ type AugmentOptions = {
8
13
  };
9
14
  type CreateAugmentAgentResult = ReturnType<typeof streamText>;
10
15
  declare const augmentAgent: ({ model, messages, toolDefinitions, }: AugmentOptions) => CreateAugmentAgentResult;
11
- declare const providerAdapter: (provider: "deepseek") => _ai_sdk_deepseek.DeepSeekProvider;
16
+ declare const providerAdapter: (provider: "deepseek") => typeof createDeepSeek;
12
17
 
13
- export { augmentAgent as default, providerAdapter };
18
+ export { augmentAgent, augmentAgent as default, providerAdapter };
14
19
  export type { AugmentOptions, CreateAugmentAgentResult };
@@ -97,10 +97,11 @@ const augmentAgent = ({
97
97
  };
98
98
  const providerAdapter = (provider) => {
99
99
  const adapter = {
100
- deepseek: deepseek.createDeepSeek()
100
+ deepseek: deepseek.createDeepSeek
101
101
  };
102
102
  return adapter[provider];
103
103
  };
104
104
 
105
+ exports.augmentAgent = augmentAgent;
105
106
  exports.default = augmentAgent;
106
107
  exports.providerAdapter = providerAdapter;
@@ -93,9 +93,9 @@ const augmentAgent = ({
93
93
  };
94
94
  const providerAdapter = (provider) => {
95
95
  const adapter = {
96
- deepseek: createDeepSeek()
96
+ deepseek: createDeepSeek
97
97
  };
98
98
  return adapter[provider];
99
99
  };
100
100
 
101
- export { augmentAgent as default, providerAdapter };
101
+ export { augmentAgent, augmentAgent as default, providerAdapter };
package/dist/index.d.ts CHANGED
@@ -1,6 +1,6 @@
1
- export { AugmentOptions, CreateAugmentAgentResult, providerAdapter } from './augment/index.js';
2
- import '@ai-sdk/deepseek';
1
+ export { AugmentOptions, CreateAugmentAgentResult, default as augmentAgent, providerAdapter } from './augment/index.js';
3
2
  import 'ai';
3
+ import '@ai-sdk/deepseek';
4
4
 
5
5
  declare const version: string;
6
6
 
package/dist/index.js CHANGED
@@ -4,9 +4,10 @@ var augment = require('./augment/index.js');
4
4
  require('ai');
5
5
  require('@ai-sdk/deepseek');
6
6
 
7
- const version$1 = "0.2.2";
7
+ const version$1 = "0.2.3";
8
8
 
9
9
  const version = version$1;
10
10
 
11
+ exports.augmentAgent = augment.augmentAgent;
11
12
  exports.providerAdapter = augment.providerAdapter;
12
13
  exports.version = version;
package/dist/index.mjs CHANGED
@@ -1,8 +1,8 @@
1
- export { providerAdapter } from './augment/index.mjs';
1
+ export { augmentAgent, providerAdapter } from './augment/index.mjs';
2
2
  import 'ai';
3
3
  import '@ai-sdk/deepseek';
4
4
 
5
- const version$1 = "0.2.2";
5
+ const version$1 = "0.2.3";
6
6
 
7
7
  const version = version$1;
8
8
 
package/package.json CHANGED
@@ -1,8 +1,7 @@
1
1
  {
2
2
  "name": "@do-kit/agents",
3
3
  "description": "@do-kit agents library",
4
- "version": "0.2.2",
5
- "type": "module",
4
+ "version": "0.2.4",
6
5
  "main": "dist/index.js",
7
6
  "module": "dist/index.mjs",
8
7
  "types": "dist/index.d.ts",
@@ -10,15 +9,29 @@
10
9
  ".": {
11
10
  "types": "./dist/index.d.ts",
12
11
  "import": "./dist/index.mjs",
13
- "require": "./dist/index.js"
12
+ "require": "./dist/index.js",
13
+ "default": "./dist/index.js"
14
14
  },
15
15
  "./augment": {
16
16
  "types": "./dist/augment/index.d.ts",
17
17
  "import": "./dist/augment/index.mjs",
18
- "require": "./dist/augment/index.js"
18
+ "require": "./dist/augment/index.js",
19
+ "default": "./dist/augment/index.js"
19
20
  },
21
+ "./dist/augment": "./dist/augment/index.js",
22
+ "./dist/augment/index.js": "./dist/augment/index.js",
20
23
  "./package.json": "./package.json"
21
24
  },
25
+ "typesVersions": {
26
+ "*": {
27
+ "augment": [
28
+ "./dist/augment/index.d.ts"
29
+ ],
30
+ "*": [
31
+ "./dist/index.d.ts"
32
+ ]
33
+ }
34
+ },
22
35
  "files": [
23
36
  "dist"
24
37
  ],
@@ -26,19 +39,20 @@
26
39
  "access": "public",
27
40
  "registry": "https://registry.npmjs.org/"
28
41
  },
29
- "devDependencies": {
30
- "@rollup/plugin-json": "^6.1.0",
31
- "rollup": "^4.34.7",
32
- "rollup-plugin-dts": "^6.1.1",
33
- "rollup-plugin-esbuild": "6.2.1",
34
- "vitest": "^4.0.7",
35
- "@do-kit/typescript-config": "0.2.0"
36
- },
37
42
  "scripts": {
38
43
  "dev": "rollup -c rollup.config.mjs -w",
39
44
  "build": "rimraf dist && rollup -c rollup.config.mjs",
40
45
  "clean": "rimraf .turbo node_modules dist",
46
+ "publish": "npm publish",
41
47
  "test": "vitest run --color",
42
48
  "test:cov": "vitest run --color --coverage"
49
+ },
50
+ "devDependencies": {
51
+ "@do-kit/typescript-config": "workspace:*",
52
+ "@rollup/plugin-json": "catalog:",
53
+ "rollup": "catalog:",
54
+ "rollup-plugin-dts": "catalog:",
55
+ "rollup-plugin-esbuild": "catalog:",
56
+ "vitest": "catalog:"
43
57
  }
44
- }
58
+ }
package/LICENSE DELETED
@@ -1,21 +0,0 @@
1
- MIT License
2
-
3
- Copyright (c) 2024 友人A
4
-
5
- Permission is hereby granted, free of charge, to any person obtaining a copy
6
- of this software and associated documentation files (the "Software"), to deal
7
- in the Software without restriction, including without limitation the rights
8
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
- copies of the Software, and to permit persons to whom the Software is
10
- furnished to do so, subject to the following conditions:
11
-
12
- The above copyright notice and this permission notice shall be included in all
13
- copies or substantial portions of the Software.
14
-
15
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
- SOFTWARE.