@aigne/example-workflow-group-chat 1.15.7 → 1.16.2

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.
Files changed (2) hide show
  1. package/index.ts +5 -3
  2. package/package.json +7 -6
package/index.ts CHANGED
@@ -2,7 +2,6 @@
2
2
 
3
3
  import assert from "node:assert";
4
4
  import { randomUUID } from "node:crypto";
5
- import { DefaultMemory } from "@aigne/agent-library/default-memory/index.js";
6
5
  import {
7
6
  AIAgent,
8
7
  AIAgentToolChoice,
@@ -11,6 +10,7 @@ import {
11
10
  PromptTemplate,
12
11
  UserAgent,
13
12
  } from "@aigne/core";
13
+ import { DefaultMemory } from "@aigne/default-memory";
14
14
  import { OpenAIChatModel } from "@aigne/openai";
15
15
  import inquirer from "inquirer";
16
16
  import { z } from "zod";
@@ -122,7 +122,8 @@ const manager = AIAgent.from({
122
122
  subscribeTopic: DEFAULT_TOPIC,
123
123
  publishTopic: (output) => output.role,
124
124
  memory: new DefaultMemory({ subscribeTopic: DEFAULT_TOPIC }),
125
- instructions: await PromptTemplate.from(`\
125
+ instructions: await PromptTemplate.from(
126
+ `\
126
127
  You are participating in a role-playing game. The available roles are:
127
128
 
128
129
  <roles>
@@ -135,7 +136,8 @@ const manager = AIAgent.from({
135
136
  3. If the last role is **not** "user," respond as "user" to approve and continue.
136
137
  4. Otherwise, select the next role **logically** based on the context of the conversation (do not repeat the same role unless necessary).
137
138
  5. Make sure responses align with the role’s personality and purpose in the game.
138
- `).format({
139
+ `,
140
+ ).format({
139
141
  roles: roles.map((i) => `${i.topic}: ${i.description}`).join("\n"),
140
142
  }),
141
143
  outputSchema: z.object({
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@aigne/example-workflow-group-chat",
3
- "version": "1.15.7",
3
+ "version": "1.16.2",
4
4
  "description": "A demonstration of using AIGNE Framework to build a group chat workflow",
5
5
  "author": "Arcblock <blocklet@arcblock.io> https://github.com/blocklet",
6
6
  "homepage": "https://github.com/AIGNE-io/aigne-framework/tree/main/examples/workflow-group-chat",
@@ -17,14 +17,15 @@
17
17
  ],
18
18
  "dependencies": {
19
19
  "zod": "^3.25.67",
20
- "@aigne/cli": "^1.22.8",
21
- "@aigne/agent-library": "^1.20.5",
22
- "@aigne/core": "^1.33.2",
23
- "@aigne/openai": "^0.9.2"
20
+ "@aigne/agent-library": "^1.21.2",
21
+ "@aigne/core": "^1.36.0",
22
+ "@aigne/cli": "^1.24.0",
23
+ "@aigne/openai": "^0.10.2",
24
+ "@aigne/default-memory": "^1.0.2"
24
25
  },
25
26
  "devDependencies": {
26
27
  "@types/bun": "^1.2.18",
27
- "@aigne/test-utils": "^0.5.7"
28
+ "@aigne/test-utils": "^0.5.10"
28
29
  },
29
30
  "scripts": {
30
31
  "start": "bun run index.ts",