@aigne/doc-smith 0.1.1 → 0.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/CHANGELOG.md CHANGED
@@ -1,5 +1,19 @@
1
1
  # Changelog
2
2
 
3
+ ## [0.1.3](https://github.com/AIGNE-io/aigne-doc-smith/compare/v0.1.2...v0.1.3) (2025-08-04)
4
+
5
+
6
+ ### Bug Fixes
7
+
8
+ * access agents from options.context instead of load a new aigne instance ([#6](https://github.com/AIGNE-io/aigne-doc-smith/issues/6)) ([0e7ce1d](https://github.com/AIGNE-io/aigne-doc-smith/commit/0e7ce1d3889aab435b029a511cb7ebdbb213ab8a))
9
+
10
+ ## [0.1.2](https://github.com/AIGNE-io/aigne-doc-smith/compare/v0.1.1...v0.1.2) (2025-08-01)
11
+
12
+
13
+ ### Bug Fixes
14
+
15
+ * use gemini pro model ([755e1fb](https://github.com/AIGNE-io/aigne-doc-smith/commit/755e1fba377f999106a7d39c734a6f72f047379e))
16
+
3
17
  ## [0.1.1](https://github.com/AIGNE-io/aigne-doc-smith/compare/v0.1.0...v0.1.1) (2025-07-31)
4
18
 
5
19
 
@@ -1,10 +1,7 @@
1
1
  import { access, readFile } from "node:fs/promises";
2
2
  import { dirname, join } from "node:path";
3
3
  import { fileURLToPath } from "node:url";
4
- import { AnthropicChatModel } from "@aigne/anthropic";
5
- import { AIGNE, TeamAgent } from "@aigne/core";
6
- import { GeminiChatModel } from "@aigne/gemini";
7
- import { OpenAIChatModel } from "@aigne/openai";
4
+ import { TeamAgent } from "@aigne/core";
8
5
  import checkDetailResult from "./check-detail-result.mjs";
9
6
 
10
7
  // Get current script directory
@@ -87,27 +84,9 @@ export default async function checkDetailGenerated(
87
84
  };
88
85
  }
89
86
 
90
- // If sourceIds have changed, regenerate even if file exists
91
- const aigne = await AIGNE.load(join(__dirname, "../"), {
92
- models: [
93
- {
94
- name: OpenAIChatModel.name,
95
- create: (params) => new OpenAIChatModel({ ...params }),
96
- },
97
- {
98
- name: AnthropicChatModel.name,
99
- create: (params) => new AnthropicChatModel({ ...params }),
100
- },
101
- {
102
- name: GeminiChatModel.name,
103
- create: (params) => new GeminiChatModel({ ...params }),
104
- },
105
- ],
106
- });
107
-
108
87
  const teamAgent = TeamAgent.from({
109
88
  name: "generate-detail",
110
- skills: [aigne.agents["detail-generator-and-translate"]],
89
+ skills: [options.context.agents["detail-generator-and-translate"]],
111
90
  });
112
91
 
113
92
  const result = await options.context.invoke(teamAgent, {
@@ -1,9 +1,5 @@
1
- import { dirname, join } from "node:path";
1
+ import { dirname } from "node:path";
2
2
  import { fileURLToPath } from "node:url";
3
- import { AnthropicChatModel } from "@aigne/anthropic";
4
- import { AIGNE } from "@aigne/core";
5
- import { GeminiChatModel } from "@aigne/gemini";
6
- import { OpenAIChatModel } from "@aigne/openai";
7
3
 
8
4
  // Get current script directory
9
5
  const __dirname = dirname(fileURLToPath(import.meta.url));
@@ -19,24 +15,7 @@ export default async function checkStructurePlanning(
19
15
  };
20
16
  }
21
17
 
22
- const aigne = await AIGNE.load(join(__dirname, "../"), {
23
- models: [
24
- {
25
- name: OpenAIChatModel.name,
26
- create: (params) => new OpenAIChatModel({ ...params }),
27
- },
28
- {
29
- name: AnthropicChatModel.name,
30
- create: (params) => new AnthropicChatModel({ ...params }),
31
- },
32
- {
33
- name: GeminiChatModel.name,
34
- create: (params) => new GeminiChatModel({ ...params }),
35
- },
36
- ],
37
- });
38
-
39
- const panningAgent = aigne.agents["reflective-structure-planner"];
18
+ const panningAgent = options.context.agents["reflective-structure-planner"];
40
19
 
41
20
  const result = await options.context.invoke(panningAgent, {
42
21
  feedback: feedback || "",
@@ -154,7 +154,6 @@ async function saveBoardIdToInput(boardId, newBoardId) {
154
154
  }
155
155
 
156
156
  await writeFile(inputFilePath, fileContent);
157
- console.log(`Board ID saved to: ${inputFilePath}`);
158
157
  } catch (error) {
159
158
  console.warn("Failed to save board ID to config.yaml:", error.message);
160
159
  }
package/aigne.yaml CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  chat_model:
4
4
  provider: gemini
5
- name: gemini-2.5-pro-preview-05-06
5
+ name: gemini-2.5-pro
6
6
  # name: gemini-2.5-flash-preview-05-20
7
7
  temperature: 0.8
8
8
  agents:
@@ -45,4 +45,4 @@ mcp_server:
45
45
  agents:
46
46
  - ./docs-mcp/get-docs-structure.mjs
47
47
  - ./docs-mcp/get-docs-detail.mjs
48
- - ./docs-mcp/docs-search.yaml
48
+ # - ./docs-mcp/docs-search.yaml
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@aigne/doc-smith",
3
- "version": "0.1.1",
3
+ "version": "0.1.3",
4
4
  "description": "",
5
5
  "publishConfig": {
6
6
  "access": "public"