@loopstack/meeting-notes-example-workflow 0.20.1 → 0.20.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.
package/README.md
CHANGED
|
@@ -22,47 +22,7 @@ This example is essential for developers building workflows that require human o
|
|
|
22
22
|
|
|
23
23
|
## Installation
|
|
24
24
|
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
### a) Add Sources via `loopstack add` (recommended)
|
|
28
|
-
|
|
29
|
-
```bash
|
|
30
|
-
loopstack add @loopstack/meeting-notes-example-workflow
|
|
31
|
-
```
|
|
32
|
-
|
|
33
|
-
This command copies the source files into your `src` directory.
|
|
34
|
-
|
|
35
|
-
- It is a great way to explore the code to learn new concepts or add own customizations
|
|
36
|
-
- It will set up the module for you, so you do not need to manually update your application
|
|
37
|
-
|
|
38
|
-
### b) Install via `npm install`
|
|
39
|
-
|
|
40
|
-
```bash
|
|
41
|
-
npm install --save @loopstack/meeting-notes-example-workflow
|
|
42
|
-
```
|
|
43
|
-
|
|
44
|
-
Use npm install if you want to use and maintain the module as node dependency.
|
|
45
|
-
|
|
46
|
-
- Use this, if you do not need to make changes to the code or want to review the source code.
|
|
47
|
-
|
|
48
|
-
## Setup
|
|
49
|
-
|
|
50
|
-
### 1. Configure API Key
|
|
51
|
-
|
|
52
|
-
Set your OpenAI API key as an environment variable:
|
|
53
|
-
|
|
54
|
-
```bash
|
|
55
|
-
OPENAI_API_KEY=sk-...
|
|
56
|
-
```
|
|
57
|
-
|
|
58
|
-
### 2. Manual setup (optional)
|
|
59
|
-
|
|
60
|
-
> This step is automatically done for you when using the `loopstack add` command.
|
|
61
|
-
|
|
62
|
-
- Add `MeetingNotesExampleModule` to the imports of `default.module.ts` or any other custom module.
|
|
63
|
-
- Inject the `MeetingNotesWorkflow` workflow to your workspace class using the `@InjectWorkflow()` decorator.
|
|
64
|
-
|
|
65
|
-
See here for more information about working with [Modules](https://loopstack.ai/docs/building-with-loopstack/creating-a-module) and [Workspaces](https://loopstack.ai/docs/building-with-loopstack/creating-workspaces)
|
|
25
|
+
See [SETUP.md](./SETUP.md) for installation and setup instructions.
|
|
66
26
|
|
|
67
27
|
## How It Works
|
|
68
28
|
|
package/package.json
CHANGED
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
"summary",
|
|
10
10
|
"workflow"
|
|
11
11
|
],
|
|
12
|
-
"version": "0.20.
|
|
12
|
+
"version": "0.20.2",
|
|
13
13
|
"license": "Apache-2.0",
|
|
14
14
|
"author": {
|
|
15
15
|
"name": "Jakob Klippel",
|
|
@@ -30,9 +30,9 @@
|
|
|
30
30
|
"watch": "nest build --watch"
|
|
31
31
|
},
|
|
32
32
|
"dependencies": {
|
|
33
|
-
"@loopstack/ai-module": "^0.20.
|
|
34
|
-
"@loopstack/common": "^0.20.
|
|
35
|
-
"@loopstack/core-ui-module": "^0.20.
|
|
33
|
+
"@loopstack/ai-module": "^0.20.2",
|
|
34
|
+
"@loopstack/common": "^0.20.3",
|
|
35
|
+
"@loopstack/core-ui-module": "^0.20.2",
|
|
36
36
|
"@nestjs/common": "^11.1.12",
|
|
37
37
|
"zod": "^4.3.5"
|
|
38
38
|
},
|
|
@@ -55,6 +55,10 @@
|
|
|
55
55
|
"module": "src/meeting-notes-example.module.ts",
|
|
56
56
|
"workflows": [
|
|
57
57
|
"src/meeting-notes.workflow.ts"
|
|
58
|
+
],
|
|
59
|
+
"installModes": [
|
|
60
|
+
"add",
|
|
61
|
+
"install"
|
|
58
62
|
]
|
|
59
63
|
}
|
|
60
64
|
}
|
|
@@ -62,7 +62,7 @@ describe('MeetingNotesWorkflow', () => {
|
|
|
62
62
|
const result = await processor.process(workflow, {}, context);
|
|
63
63
|
|
|
64
64
|
// Should execute without errors and stop at waiting_for_response (manual step)
|
|
65
|
-
expect(result.
|
|
65
|
+
expect(result.hasError).toBe(false);
|
|
66
66
|
expect(result.stop).toBe(true);
|
|
67
67
|
|
|
68
68
|
// Should call CreateDocument once for the initial form
|
|
@@ -151,7 +151,7 @@ describe('MeetingNotesWorkflow', () => {
|
|
|
151
151
|
const result = await processorWithState.process(workflowWithState, args, contextWithPayload);
|
|
152
152
|
|
|
153
153
|
// Should execute and stop at notes_optimized (next manual step)
|
|
154
|
-
expect(result.
|
|
154
|
+
expect(result.hasError).toBe(false);
|
|
155
155
|
expect(result.stop).toBe(true);
|
|
156
156
|
|
|
157
157
|
// Should call CreateDocument once for user response
|
|
@@ -241,7 +241,7 @@ describe('MeetingNotesWorkflow', () => {
|
|
|
241
241
|
const result = await processorWithState.process(workflowWithState, args, contextWithPayload);
|
|
242
242
|
|
|
243
243
|
// Should complete and reach end state
|
|
244
|
-
expect(result.
|
|
244
|
+
expect(result.hasError).toBe(false);
|
|
245
245
|
expect(result.stop).toBe(false);
|
|
246
246
|
|
|
247
247
|
// Should call CreateDocument once for final confirmation
|