@nocobase/plugin-ai 2.1.11 → 2.2.0-alpha.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 (30) hide show
  1. package/dist/ai/docs/nocobase/api/cli/config/delete.md +1 -0
  2. package/dist/ai/docs/nocobase/api/cli/config/index.md +4 -1
  3. package/dist/ai/docs/nocobase/api/cli/config/set.md +1 -0
  4. package/dist/ai/docs/nocobase/api/cli/self/check.md +19 -2
  5. package/dist/ai/docs/nocobase/api/cli/self/index.md +1 -1
  6. package/dist/ai/docs/nocobase/api/cli/self/update.md +17 -3
  7. package/dist/ai/docs/nocobase/interface-builder/blocks/data-blocks/gantt.md +204 -0
  8. package/dist/ai/docs/nocobase/nocobase-cli/installation/cli.md +2 -0
  9. package/dist/ai/docs/nocobase/plugins/@nocobase/plugin-multi-portal/index.md +16 -0
  10. package/dist/ai/docs/nocobase/plugins/@nocobase/plugin-ui-layout/index.md +14 -0
  11. package/dist/ai/docs/nocobase/plugins/@nocobase/plugin-workflow-transaction/index.md +16 -0
  12. package/dist/ai/docs/nocobase/workflow/nodes/index.md +2 -1
  13. package/dist/ai/docs/nocobase/workflow/nodes/transaction.md +81 -0
  14. package/dist/externalVersion.js +16 -16
  15. package/dist/node_modules/@langchain/xai/package.json +1 -1
  16. package/dist/node_modules/fs-extra/package.json +1 -1
  17. package/dist/node_modules/jsonrepair/package.json +1 -1
  18. package/dist/node_modules/just-bash/package.json +1 -1
  19. package/dist/node_modules/nodejs-snowflake/package.json +1 -1
  20. package/dist/node_modules/openai/package.json +1 -1
  21. package/dist/node_modules/zod/package.json +1 -1
  22. package/dist/server/ai-employees/ai-employee.js +13 -2
  23. package/dist/server/ai-employees/middleware/index.d.ts +1 -0
  24. package/dist/server/ai-employees/middleware/index.js +2 -0
  25. package/dist/server/ai-employees/middleware/tool-call-sanitizer.d.ts +16 -0
  26. package/dist/server/ai-employees/middleware/tool-call-sanitizer.js +90 -0
  27. package/dist/server/ai-employees/tool-call-sanitizer.d.ts +26 -0
  28. package/dist/server/ai-employees/tool-call-sanitizer.js +84 -0
  29. package/dist/server/ai-employees/utils.js +14 -2
  30. package/package.json +2 -2
@@ -33,6 +33,7 @@ nb config delete proxy.nginx-driver
33
33
  nb config delete proxy.caddy-driver
34
34
  nb config delete bin.nginx
35
35
  nb config delete bin.git
36
+ nb config delete bin.pnpm
36
37
  ```
37
38
 
38
39
  ## Related commands
@@ -10,7 +10,7 @@ Manage default CLI configuration values. The currently supported keys are mainly
10
10
 
11
11
  - CLI itself: `locale`, `update.policy`, `license.pkg-url`
12
12
  - Docker runtime: `docker.network`, `docker.container-prefix`
13
- - External executables: `bin.docker`, `bin.caddy`, `bin.git`, `bin.nginx`, `bin.yarn`
13
+ - External executables: `bin.docker`, `bin.caddy`, `bin.git`, `bin.nginx`, `bin.pnpm`, `bin.yarn`
14
14
  - Proxy generation: `proxy.nb-cli-root`, `proxy.upstream-host`, `proxy.nginx-driver`, `proxy.caddy-driver`
15
15
 
16
16
  Most projects only need a few of these keys. In practice, the most common ones are:
@@ -34,6 +34,7 @@ Most projects only need a few of these keys. In practice, the most common ones a
34
34
  | `bin.caddy` | `caddy` | Override the Caddy executable path |
35
35
  | `bin.git` | `git` | Override the Git executable path |
36
36
  | `bin.nginx` | `nginx` | Override the Nginx executable path |
37
+ | `bin.pnpm` | `pnpm` | Override the pnpm executable path |
37
38
  | `bin.yarn` | `yarn` | Override the Yarn executable path |
38
39
  | `proxy.nb-cli-root` | CLI root, usually the current user's home directory | Override the root path visible to the generated proxy config when the proxy process and CLI do not see the same filesystem root |
39
40
  | `proxy.upstream-host` | `127.0.0.1` | Override the host used when the proxy forwards traffic back to the NocoBase app |
@@ -70,12 +71,14 @@ nb config get docker.network
70
71
  nb config set docker.network nocobase
71
72
  nb config set bin.nginx /usr/sbin/nginx
72
73
  nb config set bin.git /usr/bin/git
74
+ nb config set bin.pnpm /usr/local/bin/pnpm
73
75
  nb config delete docker.container-prefix
74
76
  ```
75
77
 
76
78
  ## Notes
77
79
 
78
80
  - `bin.nginx` and `bin.caddy` only affect the `local` driver for `nb proxy nginx` and `nb proxy caddy`
81
+ - `bin.pnpm` is used when commands need to run pnpm directly, such as updating a pnpm-managed global CLI install with `nb self update`
79
82
  - `proxy.nginx-driver` and `proxy.caddy-driver` store the default driver used by each provider
80
83
  - `proxy.nb-cli-root` and `proxy.upstream-host` are advanced proxy overrides. Most CLI-managed `local` or `docker` envs can use the defaults directly
81
84
  - If you only want to switch the active proxy driver, using `nb proxy nginx use` or `nb proxy caddy use` is usually clearer than setting the config key manually
@@ -33,6 +33,7 @@ nb config set bin.docker /usr/local/bin/docker
33
33
  nb config set bin.caddy /opt/homebrew/bin/caddy
34
34
  nb config set bin.git /usr/bin/git
35
35
  nb config set bin.nginx /usr/sbin/nginx
36
+ nb config set bin.pnpm /usr/local/bin/pnpm
36
37
  nb config set proxy.nb-cli-root /workspace
37
38
  nb config set proxy.upstream-host host.docker.internal
38
39
  nb config set proxy.nginx-driver docker
@@ -6,7 +6,7 @@ keywords: "nb self check,NocoBase CLI,version check"
6
6
 
7
7
  # nb self check
8
8
 
9
- Check the current NocoBase CLI installation, resolve the latest version for the selected channel, and report whether automatic self-update is supported.
9
+ Check the current NocoBase CLI installation, resolve the latest version for the selected channel, and report whether self-update is supported.
10
10
 
11
11
  ## Usage
12
12
 
@@ -18,9 +18,26 @@ nb self check [flags]
18
18
 
19
19
  | Parameter | Type | Description |
20
20
  | --- | --- | --- |
21
- | `--channel` | string | Release channel to compare with, default `auto`; options: `auto`, `latest`, `beta`, `alpha` |
21
+ | `--channel` | string | Release channel to compare with, default `auto`; options: `auto`, `latest`, `test`, `beta`, `alpha` |
22
22
  | `--json` | boolean | Output JSON |
23
23
 
24
+ ## Install Method
25
+
26
+ `nb self check` detects the current install method at runtime. It does not use the historical `self-install-methods.json` cache.
27
+
28
+ The command can report these install methods:
29
+
30
+ | Install method | Meaning |
31
+ | --- | --- |
32
+ | `npm-global` | The CLI is installed under the current `npm prefix -g`. |
33
+ | `pnpm-global` | The CLI is installed under a pnpm global `node_modules` tree. |
34
+ | `yarn-global` | The CLI is launched from `yarn global bin` or installed under `yarn global dir`. |
35
+ | `package-local` | The CLI is installed in a local project dependency tree. |
36
+ | `source` | The CLI is running from a repository checkout. |
37
+ | `unknown` | The CLI install could not be matched to a supported install method. |
38
+
39
+ Self-update is supported for `npm-global`, `pnpm-global`, and `yarn-global`. For `package-local` or `source`, update the parent project or repository checkout instead.
40
+
24
41
  ## Examples
25
42
 
26
43
  ```bash
@@ -19,7 +19,7 @@ nb self <command>
19
19
  | Command | Description |
20
20
  | --- | --- |
21
21
  | [`nb self check`](./check.md) | Check current CLI version and self-update support |
22
- | [`nb self update`](./update.md) | Update the globally npm-installed NocoBase CLI |
22
+ | [`nb self update`](./update.md) | Update the globally npm-, pnpm-, or yarn-installed NocoBase CLI |
23
23
 
24
24
  ## Examples
25
25
 
@@ -1,12 +1,12 @@
1
1
  ---
2
2
  title: "nb self update"
3
- description: "nb self update command reference: update the globally npm-installed NocoBase CLI."
3
+ description: "nb self update command reference: update the globally npm-, pnpm-, or yarn-installed NocoBase CLI."
4
4
  keywords: "nb self update,NocoBase CLI,update,self update"
5
5
  ---
6
6
 
7
7
  # nb self update
8
8
 
9
- Update the installed NocoBase CLI when the current CLI is managed by a standard global npm installation.
9
+ Update the installed NocoBase CLI when the current CLI is managed by a standard global npm, pnpm, or yarn installation.
10
10
 
11
11
  ## Usage
12
12
 
@@ -18,12 +18,26 @@ nb self update [flags]
18
18
 
19
19
  | Parameter | Type | Description |
20
20
  | --- | --- | --- |
21
- | `--channel` | string | Release channel to update to, default `auto`; options: `auto`, `latest`, `beta`, `alpha` |
21
+ | `--channel` | string | Release channel to update to, default `auto`; options: `auto`, `latest`, `test`, `beta`, `alpha` |
22
22
  | `--yes`, `-y` | boolean | Skip update confirmation |
23
23
  | `--json` | boolean | Output JSON |
24
24
  | `--skills` | boolean | Also refresh the globally installed NocoBase AI coding skills |
25
25
  | `--verbose` | boolean | Show detailed update output |
26
26
 
27
+ ## Update Behavior
28
+
29
+ `nb self update` first detects the current install method at runtime. It does not use the historical `self-install-methods.json` cache.
30
+
31
+ When an update is available, the command uses the same package manager that manages the current global CLI install:
32
+
33
+ | Install method | Update command |
34
+ | --- | --- |
35
+ | `npm-global` | `npm install -g @nocobase/cli@<channel>` |
36
+ | `pnpm-global` | `pnpm add -g @nocobase/cli@<channel>` |
37
+ | `yarn-global` | `yarn global add @nocobase/cli@<channel>` |
38
+
39
+ Interactive confirmation defaults to yes. Use `--yes` to skip the prompt in scripts.
40
+
27
41
  ## Examples
28
42
 
29
43
  ```bash
@@ -0,0 +1,204 @@
1
+ ---
2
+ pkg: '@nocobase/plugin-gantt'
3
+ title: 'Gantt Block'
4
+ description: 'The Gantt block displays record start and end dates and progress on a timeline. It is suitable for project planning, task scheduling, and milestone tracking, and supports title fields, date fields, progress fields, color fields, time scale, the left table, and event popup settings.'
5
+ keywords: 'Gantt block,Gantt,project planning,task scheduling,timeline,progress management,UI building,NocoBase'
6
+ ---
7
+
8
+ # Gantt Block
9
+
10
+ ## Introduction
11
+
12
+ The Gantt block displays record start and end dates and progress on a timeline. It is suitable for project planning, task scheduling, milestone tracking, and other scenarios where you need to view task duration by time.
13
+
14
+ ![](https://static-docs.nocobase.com/Project-tasks-06-11-2026_11_30_AM.png)
15
+
16
+ ## Installation
17
+
18
+ This block is a built-in plugin and does not require additional installation.
19
+
20
+ ## Add Block
21
+
22
+ After selecting the Gantt block and choosing a data table, configure the fields required by the Gantt block in the popup:
23
+
24
+ 1. Select the title field, which is used to display the task name
25
+ 2. Select the start date field, which is used to determine the task start time
26
+ 3. Select the end date field, which is used to determine the task end time
27
+ 4. Optionally select the progress field, which is used to display and drag to update task progress
28
+ 5. Optionally select the color field, which is used to distinguish different tasks
29
+ 6. Select the time scale, which controls the granularity of the timeline
30
+
31
+ After completing the configuration, you can create the Gantt block.
32
+
33
+ ![](<https://static-docs.nocobase.com/Project-tasks-06-11-2026_11_27_AM%20(1).png>)
34
+
35
+ ![](https://static-docs.nocobase.com/Project-tasks-06-11-2026_11_27_AM.png)
36
+
37
+ ## Block Settings
38
+
39
+ ![](https://static-docs.nocobase.com/Project-tasks-06-11-2026_11_28_AM.png)
40
+
41
+ ### Gantt Fields
42
+
43
+ Gantt fields determine how records are mapped to timeline tasks.
44
+
45
+ They include:
46
+
47
+ - The title field determines the name displayed on the task bar
48
+ - The start date field determines where the task bar starts
49
+ - The end date field determines where the task bar ends
50
+ - The progress field determines the progress displayed inside the task bar
51
+ - The color field determines the task bar color
52
+ - The time scale determines whether the timeline is displayed by hour, day, week, month, and so on
53
+
54
+ ### Title Field
55
+
56
+ Used to display the task name. Usually, you can select a string field such as task name, project name, or title.
57
+
58
+ ### Start Date Field
59
+
60
+ Used to specify the task start time. The Gantt block uses this field to place the task on the timeline.
61
+
62
+ ### End Date Field
63
+
64
+ Used to specify the task end time. When the start date and end date are the same, the task is displayed as a shorter time range.
65
+
66
+ ### Progress Field
67
+
68
+ Used to display task completion progress, and supports updating it by dragging the progress handle on the task bar.
69
+
70
+ The progress field uses a float field. Data is stored from `0` to `1`, and displayed as a percentage in the Gantt block. For example, `0.6` is displayed as `60%`.
71
+
72
+ ### Color Field
73
+
74
+ Used to set the task bar color, making it easier to distinguish different task types, statuses, or priorities.
75
+
76
+ The color field supports:
77
+
78
+ - Single select field
79
+ - Color field
80
+
81
+ If a single select field is used, the Gantt block will prioritize the color configured for the selected option.
82
+
83
+ ### Time Scale
84
+
85
+ Used to control the timeline display granularity.
86
+
87
+ Currently supported:
88
+
89
+ - Hour
90
+ - Quarter of day
91
+ - Half of day
92
+ - Day
93
+ - Week
94
+ - Month
95
+ - Year
96
+ - Quarter
97
+
98
+ For short task spans, use hour, half-day, or day. For longer task spans, use week, month, quarter, or year.
99
+
100
+ ### Show Table
101
+
102
+ When enabled, the Gantt block displays a table area on the left. You can configure table columns to show key task attributes.
103
+
104
+ When disabled, the block only displays the timeline on the right. This is suitable when page space is limited or you only need to view scheduling.
105
+
106
+ ### Table Width
107
+
108
+ Used to set the width of the left table area. This setting only appears when Show table is enabled.
109
+
110
+ If there are many table fields, increase the table width. If only a few fields are kept, reduce the width and leave more space for the timeline.
111
+
112
+ ### Enable Drag to Reschedule
113
+
114
+ When enabled, you can drag task bars on the timeline to adjust start and end dates.
115
+
116
+ Details:
117
+
118
+ - Drag the whole task bar to adjust both the start date and end date
119
+ - Drag the handles on both sides of the task bar to adjust the start date or end date
120
+ - Drag the progress handle to update the progress field
121
+
122
+ If you do not want users to modify schedules directly in the Gantt block, disable this option.
123
+
124
+ ### Scroll to Today on First Display
125
+
126
+ When enabled, the Gantt block automatically scrolls to today when it is first displayed.
127
+
128
+ This option is suitable for projects with long task spans. When the page opens, users can first see tasks near the current date.
129
+
130
+ ### Event Popup Settings
131
+
132
+ Used to configure how a task bar opens after being clicked.
133
+
134
+ You can configure:
135
+
136
+ - Open mode, such as drawer, dialog, or page
137
+ - Popup size
138
+ - Popup template
139
+
140
+ After clicking a task bar, NocoBase opens the current record according to this configuration, making it convenient to view or edit task details.
141
+
142
+ ### Data Scope
143
+
144
+ Used to limit the data displayed in the Gantt block.
145
+
146
+ For example: only show tasks under the current project, or only show unfinished tasks.
147
+
148
+ For more details, refer to [Data Scope](../block-settings/data-scope).
149
+
150
+ ### Page Size
151
+
152
+ Used to control the number of records loaded per page. When there are many records, users can switch pages to view more tasks.
153
+
154
+ ### Show Row Numbers
155
+
156
+ When enabled, the left table displays row numbers, making it easier to locate records when there are many tasks.
157
+
158
+ ### Tree Table
159
+
160
+ If the current data table is a tree table, the Gantt block can enable tree table mode. After enabling it, the left table displays records by parent-child hierarchy, and the timeline on the right displays tasks in the same hierarchy.
161
+
162
+ In tree table mode, you can also configure Expand all rows by default.
163
+
164
+ ## Configure Fields
165
+
166
+ The left table area uses table columns to display record fields.
167
+
168
+ ![](https://static-docs.nocobase.com/Project-tasks-06-11-2026_11_29_AM.png)
169
+
170
+ ### Add Fields
171
+
172
+ After Show table is enabled, you can add field columns to the left table. Field settings can refer to [Table Column](../../fields/generic/table-column).
173
+
174
+ ### Actions Column
175
+
176
+ The Gantt block includes an actions column by default. You can add record actions such as view, edit, and delete to the actions column.
177
+
178
+ If Event popup settings have already been configured, you can also click the task bar on the right to open record details.
179
+
180
+ ## Configure Actions
181
+
182
+ The Gantt block supports configuring global actions at the top. Available action types depend on the enabled capabilities in the current environment.
183
+
184
+ ![](<https://static-docs.nocobase.com/Project-tasks-06-11-2026_11_29_AM%20(1).png>)
185
+
186
+ ### Built-in Actions
187
+
188
+ - Today: quickly scroll to today
189
+ - Expand/Collapse: expand or collapse all rows in tree table mode
190
+
191
+ ### Global Actions
192
+
193
+ - [Add New](../../actions/types/add-new)
194
+ - [Popup](../../actions/types/pop-up)
195
+ - [Link](../../actions/types/link)
196
+ - [Refresh](../../actions/types/refresh)
197
+ - [Filter](../../actions/types/filter)
198
+ - [Bulk Edit](../../actions/types/bulk-edit)
199
+ - [Bulk Update](../../actions/types/bulk-update)
200
+ - [Trigger Workflow](../../actions/types/trigger-workflow)
201
+ - [Custom Request](../../actions/types/custom-request)
202
+ - [JS Item](../../actions/types/js-item)
203
+ - [JS Action](../../actions/types/js-action)
204
+ - [AI Employee](../../actions/types/ai-employee)
@@ -35,6 +35,8 @@ nb config set update.policy auto
35
35
  nb config set update.policy off
36
36
  ```
37
37
 
38
+ Self-update is only supported when the CLI is managed by a standard global npm, pnpm, or yarn install. If you are running from source or from a local project dependency tree, use [`nb self check`](../../api/cli/self/check.md) to see the detected install method and update that parent project instead.
39
+
38
40
  If you are going to deploy NocoBase to the server and want to open the `nb init --ui` wizard from a remote browser, it is recommended to first change the CLI's default host to the current server IP:
39
41
 
40
42
  ```bash
@@ -0,0 +1,16 @@
1
+ ---
2
+ title: "Multi-portal"
3
+ keywords: "Multi-portal,Plugin,NocoBase"
4
+ displayName: "Multi-portal"
5
+ packageName: '@nocobase/plugin-multi-portal'
6
+ supportedVersions:
7
+ - 2.x
8
+ description: |
9
+ Provides multi-portal management with separate layouts and menus for different entry points.
10
+ isFree: false
11
+ builtIn: false
12
+ defaultEnabled: false
13
+ editionLevel: 2
14
+ ---
15
+
16
+ # Multi-portal
@@ -0,0 +1,14 @@
1
+ ---
2
+ title: "UI layout"
3
+ keywords: "UI layout,Plugin,NocoBase"
4
+ displayName: "UI layout"
5
+ packageName: '@nocobase/plugin-ui-layout'
6
+ description: |
7
+ Provides desktop layout, mobile layout, and route management pages.
8
+ isFree: true
9
+ builtIn: true
10
+ defaultEnabled: false
11
+ editionLevel: 0
12
+ ---
13
+
14
+ # UI layout
@@ -0,0 +1,16 @@
1
+ ---
2
+ title: "Workflow: Database transaction node"
3
+ keywords: "Workflow: Database transaction node,plugin,NocoBase"
4
+ displayName: "Workflow: Database transaction node"
5
+ packageName: '@nocobase/plugin-workflow-transaction'
6
+ supportedVersions:
7
+ - 2.x
8
+ description: |
9
+ Run data operation nodes from the same database data source in a transaction, committing on success and rolling back on failure.
10
+ isFree: false
11
+ builtIn: false
12
+ defaultEnabled: false
13
+ editionLevel: 3
14
+ ---
15
+
16
+ # Workflow: Database transaction node
@@ -6,7 +6,7 @@ A workflow is typically composed of several connected operational steps. Each no
6
6
  A workflow's trigger is not a node. It is only displayed as an entry point in the flowchart, but it is a different concept from a node. For details, please refer to the [Triggers](../triggers/index.md) content.
7
7
  :::
8
8
 
9
- From a functional perspective, the currently implemented nodes can be divided into several major categories (28 types of nodes in total):
9
+ From a functional perspective, the currently implemented nodes can be divided into several major categories (30 types of nodes in total):
10
10
 
11
11
  - Artificial Intelligence
12
12
  - [Large Language Model](../../ai-employees/workflow/nodes/llm/chat.md) (provided by @nocobase/plugin-workflow-llm plugin)
@@ -32,6 +32,7 @@ From a functional perspective, the currently implemented nodes can be divided in
32
32
  - [Query Data](./query.md)
33
33
  - [Aggregate Query](./aggregate.md) (provided by @nocobase/plugin-workflow-aggregate plugin)
34
34
  - [SQL Action](./sql.md) (provided by @nocobase/plugin-workflow-sql plugin)
35
+ - [Database Transaction](./transaction.md) (provided by @nocobase/plugin-workflow-transaction plugin)
35
36
  - Manual Handling
36
37
  - [Manual Handling](./manual.md) (provided by @nocobase/plugin-workflow-manual plugin)
37
38
  - [Approval](./approval.md) (provided by @nocobase/plugin-workflow-approval plugin)
@@ -0,0 +1,81 @@
1
+ ---
2
+ pkg: '@nocobase/plugin-workflow-transaction'
3
+ title: "Workflow node - Database transaction"
4
+ description: "Database transaction node: run data operations from the same data source in one transaction, commit on success, and roll back on failure."
5
+ keywords: "workflow,database transaction,Transaction,rollback,commit,data operation,NocoBase"
6
+ ---
7
+
8
+ # Database Transaction
9
+
10
+ ## Introduction
11
+
12
+ The database transaction node runs a group of database operations in the same transaction. It is suitable for scenarios where multiple data steps must either all succeed or all roll back, such as creating an order, deducting inventory, writing order details, and updating status.
13
+
14
+ The transaction node currently supports database data sources only. Data operations from the same data source inside the node are automatically included in the transaction; other data sources do not use this transaction.
15
+
16
+ This node has been supported since 2.2.0.
17
+
18
+ ## Create Node
19
+
20
+ In the workflow configuration interface, click the plus ("+") button in the flow to add a "Database transaction" node.
21
+
22
+ ![20260610205146](https://static-docs.nocobase.com/20260610205146.png)
23
+
24
+ After creation, two branches are generated:
25
+
26
+ - **Run**: The main branch executed inside the transaction. If all nodes in this branch succeed, the transaction is committed automatically. If any node fails or throws an error, the transaction is rolled back automatically.
27
+ - **After rollback**: The branch executed after rollback. This branch runs outside the transaction and can be used to record logs, send notifications, or perform compensation handling.
28
+
29
+ ![20260610205303](https://static-docs.nocobase.com/20260610205303.png)
30
+
31
+ ## Node Configuration
32
+
33
+ ![20260610205505](https://static-docs.nocobase.com/20260610205505.png)
34
+
35
+ ### Data Source
36
+
37
+ Select the database data source controlled by this transaction. Only data operation nodes from the same data source are automatically included in the transaction.
38
+
39
+ ### Isolation Level
40
+
41
+ Set the transaction isolation level. The default value is `READ UNCOMMITTED`. If your business requires stricter data consistency, choose another isolation level based on database capabilities and concurrency requirements.
42
+
43
+ ### Continue Workflow After Rollback
44
+
45
+ When enabled, the workflow continues to the nodes after the transaction node after the `After rollback` branch finishes.
46
+
47
+ When disabled, the workflow stops at the transaction node after the `After rollback` branch finishes, and subsequent nodes are not executed.
48
+
49
+ ## Usage
50
+
51
+ ### Constraints
52
+
53
+ The `Run` branch does not support asynchronous nodes that suspend the workflow, such as manual handling and delay nodes. The transaction must be committed or rolled back during the current execution. If the `Run` branch enters a waiting state, the system rolls back the transaction and marks the workflow as failed.
54
+
55
+ The `After rollback` branch runs outside the transaction, so it is not subject to the above restriction. You can use asynchronous nodes in this branch as needed, such as sending requests, waiting for manual confirmation, or delaying processing.
56
+
57
+ :::warning Note
58
+ Transactions occupy database connections until they are committed or rolled back. Avoid long-running operations in the `Run` branch and keep only the necessary data reads, writes, and checks there.
59
+ :::
60
+
61
+ ### Nested Transactions
62
+
63
+ Transaction nodes can be nested, but you need to pay attention to the data source scope:
64
+
65
+ - If the inner and outer transactions use the same data source, the inner transaction is created within the outer transaction scope and is handled according to the database and Sequelize capabilities.
66
+ - If the inner transaction uses a different data source, it does not reuse the outer transaction and creates an independent transaction for that data source.
67
+ - If the workflow is triggered by a synchronous collection event, the trigger itself may already provide a top-level transaction for the same data source. The transaction node preferentially reuses the outer transaction of the same data source and does not reuse transactions from different data sources.
68
+
69
+ Nested transactions increase the cost of understanding and troubleshooting. In general, use nested transactions only when you really need a local rollback boundary. Otherwise, prefer wrapping the complete data processing flow in a single transaction node.
70
+
71
+ ### Common Scenario
72
+
73
+ A typical flow is as follows:
74
+
75
+ 1. Query or create related data in the `Run` branch.
76
+ 2. Continue updating inventory, status, details, and other data from the same data source in the `Run` branch.
77
+ 3. If all steps succeed, the transaction is committed automatically.
78
+ 4. If any node fails or throws an error, the transaction is rolled back automatically and the workflow enters the `After rollback` branch.
79
+ 5. Record the failure reason, send notifications, or perform compensation logic in the `After rollback` branch.
80
+
81
+ If the workflow needs to continue after rollback, enable "Continue workflow after rollback".
@@ -8,22 +8,22 @@
8
8
  */
9
9
 
10
10
  module.exports = {
11
- "@nocobase/plugin-acl": "2.1.11",
12
- "@nocobase/plugin-workflow": "2.1.11",
13
- "@nocobase/client": "2.1.11",
14
- "@nocobase/utils": "2.1.11",
15
- "@nocobase/client-v2": "2.1.11",
16
- "@nocobase/database": "2.1.11",
17
- "@nocobase/server": "2.1.11",
18
- "@nocobase/plugin-file-manager": "2.1.11",
19
- "@nocobase/actions": "2.1.11",
20
- "@nocobase/ai": "2.1.11",
11
+ "@nocobase/plugin-acl": "2.2.0-alpha.2",
12
+ "@nocobase/plugin-workflow": "2.2.0-alpha.2",
13
+ "@nocobase/client": "2.2.0-alpha.2",
14
+ "@nocobase/utils": "2.2.0-alpha.2",
15
+ "@nocobase/client-v2": "2.2.0-alpha.2",
16
+ "@nocobase/database": "2.2.0-alpha.2",
17
+ "@nocobase/server": "2.2.0-alpha.2",
18
+ "@nocobase/plugin-file-manager": "2.2.0-alpha.2",
19
+ "@nocobase/actions": "2.2.0-alpha.2",
20
+ "@nocobase/ai": "2.2.0-alpha.2",
21
21
  "langchain": "1.2.39",
22
22
  "react": "18.2.0",
23
23
  "antd": "5.24.2",
24
24
  "@formily/core": "2.3.7",
25
25
  "@formily/react": "2.3.7",
26
- "@nocobase/flow-engine": "2.1.11",
26
+ "@nocobase/flow-engine": "2.2.0-alpha.2",
27
27
  "@ant-design/icons": "5.6.1",
28
28
  "@formily/antd-v5": "1.2.3",
29
29
  "@formily/shared": "2.3.7",
@@ -33,20 +33,20 @@ module.exports = {
33
33
  "lodash": "4.18.1",
34
34
  "@langchain/core": "1.1.49",
35
35
  "@langchain/langgraph": "1.4.4",
36
- "@nocobase/cache": "2.1.11",
36
+ "@nocobase/cache": "2.2.0-alpha.2",
37
37
  "@langchain/anthropic": "1.3.17",
38
38
  "@langchain/openai": "1.4.7",
39
39
  "@langchain/deepseek": "1.0.27",
40
40
  "@langchain/google-genai": "2.1.18",
41
41
  "@langchain/ollama": "1.2.7",
42
- "@nocobase/acl": "2.1.11",
43
- "@nocobase/resourcer": "2.1.11",
42
+ "@nocobase/acl": "2.2.0-alpha.2",
43
+ "@nocobase/resourcer": "2.2.0-alpha.2",
44
44
  "@emotion/css": "11.13.0",
45
45
  "dayjs": "1.11.13",
46
46
  "react-i18next": "11.18.6",
47
- "@nocobase/plugin-data-source-manager": "2.1.11",
47
+ "@nocobase/plugin-data-source-manager": "2.2.0-alpha.2",
48
48
  "@langchain/langgraph-checkpoint": "1.1.2",
49
- "@nocobase/data-source-manager": "2.1.11",
49
+ "@nocobase/data-source-manager": "2.2.0-alpha.2",
50
50
  "react-dom": "18.2.0",
51
51
  "axios": "1.7.7"
52
52
  };
@@ -1 +1 @@
1
- {"name":"@langchain/xai","version":"1.3.19","description":"xAI integration for LangChain.js","author":"LangChain","license":"MIT","type":"module","engines":{"node":">=20"},"repository":{"type":"git","url":"git@github.com:langchain-ai/langchainjs.git"},"homepage":"https://github.com/langchain-ai/langchainjs/tree/main/libs/providers/langchain-xai/","dependencies":{"@langchain/openai":"1.4.7"},"peerDependencies":{"@langchain/core":"^1.0.0"},"devDependencies":{"@tsconfig/recommended":"^1.0.3","@vitest/coverage-v8":"^3.2.4","dotenv":"^17.4.0","dpdm":"^3.14.0","typescript":"~5.8.3","vitest":"^4.1.2","zod":"^3.25.76","@langchain/openai":"^1.4.7","@langchain/core":"^1.1.48","@langchain/standard-tests":"0.0.23","@langchain/tsconfig":"0.0.1"},"publishConfig":{"access":"public"},"main":"./dist/index.cjs","types":"./dist/index.d.cts","exports":{".":{"input":"./src/index.ts","require":{"types":"./dist/index.d.cts","default":"./dist/index.cjs"},"import":{"types":"./dist/index.d.ts","default":"./dist/index.js"}},"./package.json":"./package.json"},"files":["dist/","CHANGELOG.md","README.md","LICENSE"],"module":"./dist/index.js","scripts":{"build":"turbo build:compile --filter @langchain/xai --output-logs new-only","build:compile":"tsdown","clean":"rm -rf .turbo dist/","test":"vitest run","test:watch":"vitest --watch","test:int":"vitest --mode int","test:standard:unit":"vitest --mode standard-unit","test:standard:int":"vitest --mode standard-int","test:standard":"pnpm test:standard:unit && pnpm test:standard:int","typegen":"pnpm run typegen:profiles","typegen:profiles":"pnpm --filter @langchain/model-profiles make --config profiles.toml"},"_lastModified":"2026-06-24T23:39:02.619Z"}
1
+ {"name":"@langchain/xai","version":"1.3.19","description":"xAI integration for LangChain.js","author":"LangChain","license":"MIT","type":"module","engines":{"node":">=20"},"repository":{"type":"git","url":"git@github.com:langchain-ai/langchainjs.git"},"homepage":"https://github.com/langchain-ai/langchainjs/tree/main/libs/providers/langchain-xai/","dependencies":{"@langchain/openai":"1.4.7"},"peerDependencies":{"@langchain/core":"^1.0.0"},"devDependencies":{"@tsconfig/recommended":"^1.0.3","@vitest/coverage-v8":"^3.2.4","dotenv":"^17.4.0","dpdm":"^3.14.0","typescript":"~5.8.3","vitest":"^4.1.2","zod":"^3.25.76","@langchain/openai":"^1.4.7","@langchain/core":"^1.1.48","@langchain/standard-tests":"0.0.23","@langchain/tsconfig":"0.0.1"},"publishConfig":{"access":"public"},"main":"./dist/index.cjs","types":"./dist/index.d.cts","exports":{".":{"input":"./src/index.ts","require":{"types":"./dist/index.d.cts","default":"./dist/index.cjs"},"import":{"types":"./dist/index.d.ts","default":"./dist/index.js"}},"./package.json":"./package.json"},"files":["dist/","CHANGELOG.md","README.md","LICENSE"],"module":"./dist/index.js","scripts":{"build":"turbo build:compile --filter @langchain/xai --output-logs new-only","build:compile":"tsdown","clean":"rm -rf .turbo dist/","test":"vitest run","test:watch":"vitest --watch","test:int":"vitest --mode int","test:standard:unit":"vitest --mode standard-unit","test:standard:int":"vitest --mode standard-int","test:standard":"pnpm test:standard:unit && pnpm test:standard:int","typegen":"pnpm run typegen:profiles","typegen:profiles":"pnpm --filter @langchain/model-profiles make --config profiles.toml"},"_lastModified":"2026-06-26T03:51:31.345Z"}
@@ -1 +1 @@
1
- {"name":"fs-extra","version":"9.1.0","description":"fs-extra contains methods that aren't included in the vanilla Node.js fs package. Such as recursive mkdir, copy, and remove.","engines":{"node":">=10"},"homepage":"https://github.com/jprichardson/node-fs-extra","repository":{"type":"git","url":"https://github.com/jprichardson/node-fs-extra"},"keywords":["fs","file","file system","copy","directory","extra","mkdirp","mkdir","mkdirs","recursive","json","read","write","extra","delete","remove","touch","create","text","output","move","promise"],"author":"JP Richardson <jprichardson@gmail.com>","license":"MIT","dependencies":{"at-least-node":"^1.0.0","graceful-fs":"^4.2.0","jsonfile":"^6.0.1","universalify":"^2.0.0"},"devDependencies":{"coveralls":"^3.0.0","klaw":"^2.1.1","klaw-sync":"^3.0.2","minimist":"^1.1.1","mocha":"^5.0.5","nyc":"^15.0.0","proxyquire":"^2.0.1","read-dir-files":"^0.1.1","standard":"^14.1.0"},"main":"./lib/index.js","files":["lib/","!lib/**/__tests__/"],"scripts":{"full-ci":"npm run lint && npm run coverage","coverage":"nyc -r lcovonly npm run unit","coveralls":"coveralls < coverage/lcov.info","lint":"standard","test-find":"find ./lib/**/__tests__ -name *.test.js | xargs mocha","test":"npm run lint && npm run unit","unit":"node test.js"},"_lastModified":"2026-06-24T23:39:02.779Z"}
1
+ {"name":"fs-extra","version":"9.1.0","description":"fs-extra contains methods that aren't included in the vanilla Node.js fs package. Such as recursive mkdir, copy, and remove.","engines":{"node":">=10"},"homepage":"https://github.com/jprichardson/node-fs-extra","repository":{"type":"git","url":"https://github.com/jprichardson/node-fs-extra"},"keywords":["fs","file","file system","copy","directory","extra","mkdirp","mkdir","mkdirs","recursive","json","read","write","extra","delete","remove","touch","create","text","output","move","promise"],"author":"JP Richardson <jprichardson@gmail.com>","license":"MIT","dependencies":{"at-least-node":"^1.0.0","graceful-fs":"^4.2.0","jsonfile":"^6.0.1","universalify":"^2.0.0"},"devDependencies":{"coveralls":"^3.0.0","klaw":"^2.1.1","klaw-sync":"^3.0.2","minimist":"^1.1.1","mocha":"^5.0.5","nyc":"^15.0.0","proxyquire":"^2.0.1","read-dir-files":"^0.1.1","standard":"^14.1.0"},"main":"./lib/index.js","files":["lib/","!lib/**/__tests__/"],"scripts":{"full-ci":"npm run lint && npm run coverage","coverage":"nyc -r lcovonly npm run unit","coveralls":"coveralls < coverage/lcov.info","lint":"standard","test-find":"find ./lib/**/__tests__ -name *.test.js | xargs mocha","test":"npm run lint && npm run unit","unit":"node test.js"},"_lastModified":"2026-06-26T03:51:31.516Z"}
@@ -1 +1 @@
1
- {"name":"jsonrepair","version":"3.13.1","description":"Repair broken JSON documents","repository":{"type":"git","url":"https://github.com/josdejong/jsonrepair.git"},"type":"module","main":"lib/cjs/index.js","module":"lib/esm/index.js","browser":"lib/umd/jsonrepair.min.js","types":"lib/types/index.d.ts","sideEffects":false,"exports":{".":{"import":"./lib/esm/index.js","require":"./lib/cjs/index.js","types":"./lib/types/index.d.ts"},"./stream":{"import":"./lib/esm/stream.js","require":"./lib/cjs/stream.js","types":"./lib/types/stream.d.ts"}},"keywords":["simple","json","repair","fix","invalid","stream","streaming"],"bin":{"jsonrepair":"./bin/cli.js"},"scripts":{"test":"vitest watch src","test:it":"vitest run src","build":"npm-run-all build:**","build:clean":"del-cli lib","build:esm":"babel src --out-dir lib/esm --extensions \".ts\" --source-maps --config-file ./babel.config.json","build:cjs":"babel src --out-dir lib/cjs --extensions \".ts\" --source-maps --config-file ./babel-cjs.config.json && cpy tools/cjs lib/cjs --flat","build:umd":"rollup lib/esm/index.js --format umd --name JSONRepair --sourcemap --output.file lib/umd/jsonrepair.js && cpy tools/cjs/package.json lib/umd --flat","build:umd:min":"uglifyjs --compress --mangle --source-map --comments --output lib/umd/jsonrepair.min.js -- lib/umd/jsonrepair.js","build:types":"tsc --project tsconfig-types.json","build:validate":"vitest run test-lib","lint":"biome check","format":"biome check --write","benchmark":"npm run build:esm && node tools/benchmark/run.mjs","build-and-test":"npm run lint && npm run test:it && npm run build","release":"npm-run-all release:**","release:build-and-test":"npm run build-and-test","release:version":"standard-version","release:push":"git push && git push --tag","release:publish":"npm publish","release-dry-run":"npm run build-and-test && standard-version --dry-run","prepare":"husky"},"files":["README.md","LICENSE.md","lib"],"author":"Jos de Jong","license":"ISC","devDependencies":{"@babel/cli":"7.28.3","@babel/core":"7.28.4","@babel/plugin-transform-typescript":"7.28.0","@babel/preset-env":"7.28.3","@babel/preset-typescript":"7.27.1","@biomejs/biome":"2.2.4","@commitlint/cli":"19.8.1","@commitlint/config-conventional":"19.8.1","@types/node":"24.5.2","cpy-cli":"6.0.0","del-cli":"7.0.0","husky":"9.1.7","npm-run-all":"4.1.5","rollup":"4.51.0","standard-version":"9.5.0","tinybench":"5.0.1","ts-node":"10.9.2","typescript":"5.9.2","uglify-js":"3.19.3","vitest":"3.2.4"},"_lastModified":"2026-06-24T23:39:08.765Z"}
1
+ {"name":"jsonrepair","version":"3.13.1","description":"Repair broken JSON documents","repository":{"type":"git","url":"https://github.com/josdejong/jsonrepair.git"},"type":"module","main":"lib/cjs/index.js","module":"lib/esm/index.js","browser":"lib/umd/jsonrepair.min.js","types":"lib/types/index.d.ts","sideEffects":false,"exports":{".":{"import":"./lib/esm/index.js","require":"./lib/cjs/index.js","types":"./lib/types/index.d.ts"},"./stream":{"import":"./lib/esm/stream.js","require":"./lib/cjs/stream.js","types":"./lib/types/stream.d.ts"}},"keywords":["simple","json","repair","fix","invalid","stream","streaming"],"bin":{"jsonrepair":"./bin/cli.js"},"scripts":{"test":"vitest watch src","test:it":"vitest run src","build":"npm-run-all build:**","build:clean":"del-cli lib","build:esm":"babel src --out-dir lib/esm --extensions \".ts\" --source-maps --config-file ./babel.config.json","build:cjs":"babel src --out-dir lib/cjs --extensions \".ts\" --source-maps --config-file ./babel-cjs.config.json && cpy tools/cjs lib/cjs --flat","build:umd":"rollup lib/esm/index.js --format umd --name JSONRepair --sourcemap --output.file lib/umd/jsonrepair.js && cpy tools/cjs/package.json lib/umd --flat","build:umd:min":"uglifyjs --compress --mangle --source-map --comments --output lib/umd/jsonrepair.min.js -- lib/umd/jsonrepair.js","build:types":"tsc --project tsconfig-types.json","build:validate":"vitest run test-lib","lint":"biome check","format":"biome check --write","benchmark":"npm run build:esm && node tools/benchmark/run.mjs","build-and-test":"npm run lint && npm run test:it && npm run build","release":"npm-run-all release:**","release:build-and-test":"npm run build-and-test","release:version":"standard-version","release:push":"git push && git push --tag","release:publish":"npm publish","release-dry-run":"npm run build-and-test && standard-version --dry-run","prepare":"husky"},"files":["README.md","LICENSE.md","lib"],"author":"Jos de Jong","license":"ISC","devDependencies":{"@babel/cli":"7.28.3","@babel/core":"7.28.4","@babel/plugin-transform-typescript":"7.28.0","@babel/preset-env":"7.28.3","@babel/preset-typescript":"7.27.1","@biomejs/biome":"2.2.4","@commitlint/cli":"19.8.1","@commitlint/config-conventional":"19.8.1","@types/node":"24.5.2","cpy-cli":"6.0.0","del-cli":"7.0.0","husky":"9.1.7","npm-run-all":"4.1.5","rollup":"4.51.0","standard-version":"9.5.0","tinybench":"5.0.1","ts-node":"10.9.2","typescript":"5.9.2","uglify-js":"3.19.3","vitest":"3.2.4"},"_lastModified":"2026-06-26T03:51:38.039Z"}
@@ -1 +1 @@
1
- {"name":"just-bash","version":"2.14.3","description":"A simulated bash environment with virtual filesystem","repository":{"type":"git","url":"git+https://github.com/vercel-labs/just-bash.git"},"homepage":"https://github.com/vercel-labs/just-bash#readme","bugs":{"url":"https://github.com/vercel-labs/just-bash/issues"},"type":"module","main":"dist/bundle/index.js","types":"dist/index.d.ts","exports":{".":{"browser":"./dist/bundle/browser.js","require":{"types":"./dist/index.d.cts","default":"./dist/bundle/index.cjs"},"import":{"types":"./dist/index.d.ts","default":"./dist/bundle/index.js"}},"./browser":{"types":"./dist/browser.d.ts","import":"./dist/bundle/browser.js"}},"files":["dist/bundle/","dist/bin/","dist/*.d.ts","dist/*.d.cts","dist/ast/*.d.ts","dist/commands/**/*.d.ts","dist/fs/**/*.d.ts","dist/interpreter/**/*.d.ts","dist/network/**/*.d.ts","dist/parser/*.d.ts","dist/sandbox/*.d.ts","dist/utils/*.d.ts","vendor/cpython-emscripten/","README.md","CHANGELOG.md","dist/AGENTS.md"],"bin":{"just-bash":"./dist/bin/just-bash.js","just-bash-shell":"./dist/bin/shell/shell.js"},"publishConfig":{"access":"public"},"keywords":[],"author":"Malte and Claude","license":"Apache-2.0","devDependencies":{"@types/ini":"^4.1.1","@types/node":"^25.0.3","@types/papaparse":"^5.5.2","@types/sprintf-js":"^1.1.4","@types/sql.js":"^1.4.9","@types/turndown":"^5.0.6","@vitest/coverage-v8":"^4.0.18","esbuild":"^0.27.2","fast-check":"^3.23.2","knip":"^5.41.1","typescript":"^5.9.3","vitest":"^4.0.16"},"dependencies":{"seek-bzip":"^2.0.0","diff":"^8.0.2","fast-xml-parser":"5.3.3","file-type":"^21.2.0","ini":"^6.0.0","minimatch":"^10.1.1","modern-tar":"^0.7.3","papaparse":"^5.5.3","quickjs-emscripten":"^0.32.0","re2js":"^1.2.1","smol-toml":"^1.6.0","sprintf-js":"^1.1.3","sql.js":"^1.13.0","turndown":"^7.2.2","yaml":"^2.8.2"},"optionalDependencies":{"@mongodb-js/zstd":"^7.0.0","node-liblzma":"^2.0.3"},"scripts":{"build":"rm -rf dist && tsc && pnpm build:lib && pnpm build:lib:cjs && pnpm build:browser && pnpm build:cli && pnpm build:shell && pnpm build:worker && pnpm build:clean && cp dist/index.d.ts dist/index.d.cts && sed '1,/^-->/d' AGENTS.npm.md > dist/AGENTS.md","build:clean":"find dist -name '*.test.js' -delete && find dist -name '*.test.d.ts' -delete","build:worker":"esbuild src/commands/python3/worker.ts --bundle --platform=node --format=esm --outfile=src/commands/python3/worker.js --external:../../../vendor/cpython-emscripten/* && cp src/commands/python3/worker.js dist/commands/python3/worker.js && mkdir -p dist/bin/chunks && cp src/commands/python3/worker.js dist/bin/chunks/worker.js && mkdir -p dist/bundle/chunks && cp src/commands/python3/worker.js dist/bundle/chunks/worker.js && esbuild src/commands/js-exec/js-exec-worker.ts --bundle --platform=node --format=esm --outfile=src/commands/js-exec/js-exec-worker.js --external:quickjs-emscripten && cp src/commands/js-exec/js-exec-worker.js dist/commands/js-exec/js-exec-worker.js && cp src/commands/js-exec/js-exec-worker.js dist/bin/chunks/js-exec-worker.js && cp src/commands/js-exec/js-exec-worker.js dist/bundle/chunks/js-exec-worker.js","build:lib":"esbuild dist/index.js --bundle --splitting --platform=node --format=esm --minify --outdir=dist/bundle --chunk-names=chunks/[name]-[hash] --external:diff --external:minimatch --external:sprintf-js --external:turndown --external:sql.js --external:quickjs-emscripten --external:@mongodb-js/zstd --external:node-liblzma --external:seek-bzip","build:lib:cjs":"esbuild dist/index.js --bundle --platform=node --format=cjs --minify --outfile=dist/bundle/index.cjs --external:diff --external:minimatch --external:sprintf-js --external:turndown --external:sql.js --external:quickjs-emscripten --external:@mongodb-js/zstd --external:node-liblzma --external:seek-bzip","build:browser":"esbuild dist/browser.js --bundle --platform=browser --format=esm --minify --outfile=dist/bundle/browser.js --external:diff --external:minimatch --external:sprintf-js --external:turndown --external:node:zlib --external:@mongodb-js/zstd --external:node-liblzma --external:seek-bzip --define:__BROWSER__=true --alias:node:dns=./src/shims/browser-unsupported.js","build:cli":"esbuild dist/cli/just-bash.js --bundle --splitting --platform=node --format=esm --minify --outdir=dist/bin --entry-names=[name] --chunk-names=chunks/[name]-[hash] --banner:js='#!/usr/bin/env node' --external:sql.js --external:quickjs-emscripten --external:@mongodb-js/zstd --external:node-liblzma --external:seek-bzip","build:shell":"esbuild dist/cli/shell.js --bundle --splitting --platform=node --format=esm --minify --outdir=dist/bin/shell --entry-names=[name] --chunk-names=chunks/[name]-[hash] --banner:js='#!/usr/bin/env node' --external:sql.js --external:quickjs-emscripten --external:@mongodb-js/zstd --external:node-liblzma --external:seek-bzip","validate":"pnpm lint && pnpm knip && pnpm typecheck && pnpm build && pnpm check:worker-sync && pnpm test:run && pnpm test:wasm && pnpm test:dist","typecheck":"tsc --noEmit","lint":"pnpm lint:banned","check:worker-sync":"node scripts/check-worker-sync.js","lint:banned":"node scripts/check-banned-patterns.js","lint:fix":"pnpm --workspace-root lint:fix","knip":"knip","test":"vitest","test:run":"vitest run --exclude src/security/fuzzing/ --exclude src/commands/python3/ --exclude src/commands/sqlite3/ --exclude src/commands/js-exec/ --exclude src/agent-examples/python-scripting.test.ts","test:dist":"vitest run src/cli/just-bash.bundle.test.ts","test:unit":"vitest run --config vitest.unit.config.ts","test:wasm":"vitest run --config vitest.wasm.config.ts","test:comparison":"vitest run --config vitest.comparison.config.ts","test:comparison:record":"RECORD_FIXTURES=1 vitest run --config vitest.comparison.config.ts","test:coverage":"vitest run --coverage","test:coverage:unit":"vitest run --config vitest.unit.config.ts --coverage","test:fuzz":"vitest run src/security/fuzzing/","test:fuzz:long":"FUZZ_RUNS=10000 vitest run src/security/fuzzing/","shell":"npx tsx src/cli/shell.ts","dev:exec":"npx tsx src/cli/exec.ts"},"_lastModified":"2026-06-24T23:39:08.239Z"}
1
+ {"name":"just-bash","version":"2.14.3","description":"A simulated bash environment with virtual filesystem","repository":{"type":"git","url":"git+https://github.com/vercel-labs/just-bash.git"},"homepage":"https://github.com/vercel-labs/just-bash#readme","bugs":{"url":"https://github.com/vercel-labs/just-bash/issues"},"type":"module","main":"dist/bundle/index.js","types":"dist/index.d.ts","exports":{".":{"browser":"./dist/bundle/browser.js","require":{"types":"./dist/index.d.cts","default":"./dist/bundle/index.cjs"},"import":{"types":"./dist/index.d.ts","default":"./dist/bundle/index.js"}},"./browser":{"types":"./dist/browser.d.ts","import":"./dist/bundle/browser.js"}},"files":["dist/bundle/","dist/bin/","dist/*.d.ts","dist/*.d.cts","dist/ast/*.d.ts","dist/commands/**/*.d.ts","dist/fs/**/*.d.ts","dist/interpreter/**/*.d.ts","dist/network/**/*.d.ts","dist/parser/*.d.ts","dist/sandbox/*.d.ts","dist/utils/*.d.ts","vendor/cpython-emscripten/","README.md","CHANGELOG.md","dist/AGENTS.md"],"bin":{"just-bash":"./dist/bin/just-bash.js","just-bash-shell":"./dist/bin/shell/shell.js"},"publishConfig":{"access":"public"},"keywords":[],"author":"Malte and Claude","license":"Apache-2.0","devDependencies":{"@types/ini":"^4.1.1","@types/node":"^25.0.3","@types/papaparse":"^5.5.2","@types/sprintf-js":"^1.1.4","@types/sql.js":"^1.4.9","@types/turndown":"^5.0.6","@vitest/coverage-v8":"^4.0.18","esbuild":"^0.27.2","fast-check":"^3.23.2","knip":"^5.41.1","typescript":"^5.9.3","vitest":"^4.0.16"},"dependencies":{"seek-bzip":"^2.0.0","diff":"^8.0.2","fast-xml-parser":"5.3.3","file-type":"^21.2.0","ini":"^6.0.0","minimatch":"^10.1.1","modern-tar":"^0.7.3","papaparse":"^5.5.3","quickjs-emscripten":"^0.32.0","re2js":"^1.2.1","smol-toml":"^1.6.0","sprintf-js":"^1.1.3","sql.js":"^1.13.0","turndown":"^7.2.2","yaml":"^2.8.2"},"optionalDependencies":{"@mongodb-js/zstd":"^7.0.0","node-liblzma":"^2.0.3"},"scripts":{"build":"rm -rf dist && tsc && pnpm build:lib && pnpm build:lib:cjs && pnpm build:browser && pnpm build:cli && pnpm build:shell && pnpm build:worker && pnpm build:clean && cp dist/index.d.ts dist/index.d.cts && sed '1,/^-->/d' AGENTS.npm.md > dist/AGENTS.md","build:clean":"find dist -name '*.test.js' -delete && find dist -name '*.test.d.ts' -delete","build:worker":"esbuild src/commands/python3/worker.ts --bundle --platform=node --format=esm --outfile=src/commands/python3/worker.js --external:../../../vendor/cpython-emscripten/* && cp src/commands/python3/worker.js dist/commands/python3/worker.js && mkdir -p dist/bin/chunks && cp src/commands/python3/worker.js dist/bin/chunks/worker.js && mkdir -p dist/bundle/chunks && cp src/commands/python3/worker.js dist/bundle/chunks/worker.js && esbuild src/commands/js-exec/js-exec-worker.ts --bundle --platform=node --format=esm --outfile=src/commands/js-exec/js-exec-worker.js --external:quickjs-emscripten && cp src/commands/js-exec/js-exec-worker.js dist/commands/js-exec/js-exec-worker.js && cp src/commands/js-exec/js-exec-worker.js dist/bin/chunks/js-exec-worker.js && cp src/commands/js-exec/js-exec-worker.js dist/bundle/chunks/js-exec-worker.js","build:lib":"esbuild dist/index.js --bundle --splitting --platform=node --format=esm --minify --outdir=dist/bundle --chunk-names=chunks/[name]-[hash] --external:diff --external:minimatch --external:sprintf-js --external:turndown --external:sql.js --external:quickjs-emscripten --external:@mongodb-js/zstd --external:node-liblzma --external:seek-bzip","build:lib:cjs":"esbuild dist/index.js --bundle --platform=node --format=cjs --minify --outfile=dist/bundle/index.cjs --external:diff --external:minimatch --external:sprintf-js --external:turndown --external:sql.js --external:quickjs-emscripten --external:@mongodb-js/zstd --external:node-liblzma --external:seek-bzip","build:browser":"esbuild dist/browser.js --bundle --platform=browser --format=esm --minify --outfile=dist/bundle/browser.js --external:diff --external:minimatch --external:sprintf-js --external:turndown --external:node:zlib --external:@mongodb-js/zstd --external:node-liblzma --external:seek-bzip --define:__BROWSER__=true --alias:node:dns=./src/shims/browser-unsupported.js","build:cli":"esbuild dist/cli/just-bash.js --bundle --splitting --platform=node --format=esm --minify --outdir=dist/bin --entry-names=[name] --chunk-names=chunks/[name]-[hash] --banner:js='#!/usr/bin/env node' --external:sql.js --external:quickjs-emscripten --external:@mongodb-js/zstd --external:node-liblzma --external:seek-bzip","build:shell":"esbuild dist/cli/shell.js --bundle --splitting --platform=node --format=esm --minify --outdir=dist/bin/shell --entry-names=[name] --chunk-names=chunks/[name]-[hash] --banner:js='#!/usr/bin/env node' --external:sql.js --external:quickjs-emscripten --external:@mongodb-js/zstd --external:node-liblzma --external:seek-bzip","validate":"pnpm lint && pnpm knip && pnpm typecheck && pnpm build && pnpm check:worker-sync && pnpm test:run && pnpm test:wasm && pnpm test:dist","typecheck":"tsc --noEmit","lint":"pnpm lint:banned","check:worker-sync":"node scripts/check-worker-sync.js","lint:banned":"node scripts/check-banned-patterns.js","lint:fix":"pnpm --workspace-root lint:fix","knip":"knip","test":"vitest","test:run":"vitest run --exclude src/security/fuzzing/ --exclude src/commands/python3/ --exclude src/commands/sqlite3/ --exclude src/commands/js-exec/ --exclude src/agent-examples/python-scripting.test.ts","test:dist":"vitest run src/cli/just-bash.bundle.test.ts","test:unit":"vitest run --config vitest.unit.config.ts","test:wasm":"vitest run --config vitest.wasm.config.ts","test:comparison":"vitest run --config vitest.comparison.config.ts","test:comparison:record":"RECORD_FIXTURES=1 vitest run --config vitest.comparison.config.ts","test:coverage":"vitest run --coverage","test:coverage:unit":"vitest run --config vitest.unit.config.ts --coverage","test:fuzz":"vitest run src/security/fuzzing/","test:fuzz:long":"FUZZ_RUNS=10000 vitest run src/security/fuzzing/","shell":"npx tsx src/cli/shell.ts","dev:exec":"npx tsx src/cli/exec.ts"},"_lastModified":"2026-06-26T03:51:37.812Z"}
@@ -1 +1 @@
1
- {"name":"nodejs-snowflake","collaborators":["Utkarsh Srivastava <utkarsh@sagacious.dev>"],"description":"Generate time sortable 64 bits unique ids for distributed systems (inspired from twitter snowflake)","version":"2.0.1","license":"Apache 2.0","repository":{"type":"git","url":"https://github.com/utkarsh-pro/nodejs-snowflake.git"},"files":["nodejs_snowflake_bg.wasm","nodejs_snowflake.js","nodejs_snowflake.d.ts"],"main":"nodejs_snowflake.js","types":"nodejs_snowflake.d.ts","_lastModified":"2026-06-24T23:38:57.380Z"}
1
+ {"name":"nodejs-snowflake","collaborators":["Utkarsh Srivastava <utkarsh@sagacious.dev>"],"description":"Generate time sortable 64 bits unique ids for distributed systems (inspired from twitter snowflake)","version":"2.0.1","license":"Apache 2.0","repository":{"type":"git","url":"https://github.com/utkarsh-pro/nodejs-snowflake.git"},"files":["nodejs_snowflake_bg.wasm","nodejs_snowflake.js","nodejs_snowflake.d.ts"],"main":"nodejs_snowflake.js","types":"nodejs_snowflake.d.ts","_lastModified":"2026-06-26T03:51:25.667Z"}
@@ -1 +1 @@
1
- {"name":"openai","version":"6.39.1","description":"The official TypeScript library for the OpenAI API","author":"OpenAI <support@openai.com>","types":"./index.d.ts","main":"./index.js","type":"commonjs","repository":"github:openai/openai-node","license":"Apache-2.0","packageManager":"yarn@1.22.22","files":["**/*"],"private":false,"publishConfig":{"access":"public"},"scripts":{"test":"./scripts/test","build":"./scripts/build","format":"./scripts/format","tsn":"ts-node -r tsconfig-paths/register","lint":"./scripts/lint","fix":"./scripts/format"},"dependencies":{},"bin":{"openai":"bin/cli"},"overrides":{"minimatch":"^9.0.5"},"pnpm":{"overrides":{"minimatch":"^9.0.5"}},"resolutions":{"minimatch":"^9.0.5"},"exports":{".":{"require":{"types":"./index.d.ts","default":"./index.js"},"types":"./index.d.mts","default":"./index.mjs"},"./_vendor/*.mjs":{"default":"./_vendor/*.mjs"},"./_vendor/*.js":{"default":"./_vendor/*.js"},"./_vendor/*":{"import":"./_vendor/*.mjs","require":"./_vendor/*.js"},"./api-promise":{"import":"./api-promise.mjs","require":"./api-promise.js"},"./api-promise.js":{"default":"./api-promise.js"},"./api-promise.mjs":{"default":"./api-promise.mjs"},"./auth/*.mjs":{"default":"./auth/*.mjs"},"./auth/*.js":{"default":"./auth/*.js"},"./auth/*":{"import":"./auth/*.mjs","require":"./auth/*.js"},"./azure":{"import":"./azure.mjs","require":"./azure.js"},"./azure.js":{"default":"./azure.js"},"./azure.mjs":{"default":"./azure.mjs"},"./beta/*.mjs":{"default":"./beta/*.mjs"},"./beta/*.js":{"default":"./beta/*.js"},"./beta/*":{"import":"./beta/*.mjs","require":"./beta/*.js"},"./client":{"import":"./client.mjs","require":"./client.js"},"./client.js":{"default":"./client.js"},"./client.mjs":{"default":"./client.mjs"},"./core/*.mjs":{"default":"./core/*.mjs"},"./core/*.js":{"default":"./core/*.js"},"./core/*":{"import":"./core/*.mjs","require":"./core/*.js"},"./error":{"import":"./error.mjs","require":"./error.js"},"./error.js":{"default":"./error.js"},"./error.mjs":{"default":"./error.mjs"},"./helpers/*.mjs":{"default":"./helpers/*.mjs"},"./helpers/*.js":{"default":"./helpers/*.js"},"./helpers/*":{"import":"./helpers/*.mjs","require":"./helpers/*.js"},"./index":{"import":"./index.mjs","require":"./index.js"},"./index.js":{"default":"./index.js"},"./index.mjs":{"default":"./index.mjs"},"./lib/*.mjs":{"default":"./lib/*.mjs"},"./lib/*.js":{"default":"./lib/*.js"},"./lib/*":{"import":"./lib/*.mjs","require":"./lib/*.js"},"./pagination":{"import":"./pagination.mjs","require":"./pagination.js"},"./pagination.js":{"default":"./pagination.js"},"./pagination.mjs":{"default":"./pagination.mjs"},"./realtime/*.mjs":{"default":"./realtime/*.mjs"},"./realtime/*.js":{"default":"./realtime/*.js"},"./realtime/*":{"import":"./realtime/*.mjs","require":"./realtime/*.js"},"./resource":{"import":"./resource.mjs","require":"./resource.js"},"./resource.js":{"default":"./resource.js"},"./resource.mjs":{"default":"./resource.mjs"},"./resources/*.mjs":{"default":"./resources/*.mjs"},"./resources/*.js":{"default":"./resources/*.js"},"./resources/*":{"import":"./resources/*.mjs","require":"./resources/*.js"},"./resources":{"import":"./resources.mjs","require":"./resources.js"},"./resources.js":{"default":"./resources.js"},"./resources.mjs":{"default":"./resources.mjs"},"./streaming":{"import":"./streaming.mjs","require":"./streaming.js"},"./streaming.js":{"default":"./streaming.js"},"./streaming.mjs":{"default":"./streaming.mjs"},"./uploads":{"import":"./uploads.mjs","require":"./uploads.js"},"./uploads.js":{"default":"./uploads.js"},"./uploads.mjs":{"default":"./uploads.mjs"},"./version":{"import":"./version.mjs","require":"./version.js"},"./version.js":{"default":"./version.js"},"./version.mjs":{"default":"./version.mjs"}},"peerDependencies":{"ws":"^8.18.0","zod":"^3.25 || ^4.0"},"peerDependenciesMeta":{"ws":{"optional":true},"zod":{"optional":true}},"_lastModified":"2026-06-24T23:39:00.045Z"}
1
+ {"name":"openai","version":"6.39.1","description":"The official TypeScript library for the OpenAI API","author":"OpenAI <support@openai.com>","types":"./index.d.ts","main":"./index.js","type":"commonjs","repository":"github:openai/openai-node","license":"Apache-2.0","packageManager":"yarn@1.22.22","files":["**/*"],"private":false,"publishConfig":{"access":"public"},"scripts":{"test":"./scripts/test","build":"./scripts/build","format":"./scripts/format","tsn":"ts-node -r tsconfig-paths/register","lint":"./scripts/lint","fix":"./scripts/format"},"dependencies":{},"bin":{"openai":"bin/cli"},"overrides":{"minimatch":"^9.0.5"},"pnpm":{"overrides":{"minimatch":"^9.0.5"}},"resolutions":{"minimatch":"^9.0.5"},"exports":{".":{"require":{"types":"./index.d.ts","default":"./index.js"},"types":"./index.d.mts","default":"./index.mjs"},"./_vendor/*.mjs":{"default":"./_vendor/*.mjs"},"./_vendor/*.js":{"default":"./_vendor/*.js"},"./_vendor/*":{"import":"./_vendor/*.mjs","require":"./_vendor/*.js"},"./api-promise":{"import":"./api-promise.mjs","require":"./api-promise.js"},"./api-promise.js":{"default":"./api-promise.js"},"./api-promise.mjs":{"default":"./api-promise.mjs"},"./auth/*.mjs":{"default":"./auth/*.mjs"},"./auth/*.js":{"default":"./auth/*.js"},"./auth/*":{"import":"./auth/*.mjs","require":"./auth/*.js"},"./azure":{"import":"./azure.mjs","require":"./azure.js"},"./azure.js":{"default":"./azure.js"},"./azure.mjs":{"default":"./azure.mjs"},"./beta/*.mjs":{"default":"./beta/*.mjs"},"./beta/*.js":{"default":"./beta/*.js"},"./beta/*":{"import":"./beta/*.mjs","require":"./beta/*.js"},"./client":{"import":"./client.mjs","require":"./client.js"},"./client.js":{"default":"./client.js"},"./client.mjs":{"default":"./client.mjs"},"./core/*.mjs":{"default":"./core/*.mjs"},"./core/*.js":{"default":"./core/*.js"},"./core/*":{"import":"./core/*.mjs","require":"./core/*.js"},"./error":{"import":"./error.mjs","require":"./error.js"},"./error.js":{"default":"./error.js"},"./error.mjs":{"default":"./error.mjs"},"./helpers/*.mjs":{"default":"./helpers/*.mjs"},"./helpers/*.js":{"default":"./helpers/*.js"},"./helpers/*":{"import":"./helpers/*.mjs","require":"./helpers/*.js"},"./index":{"import":"./index.mjs","require":"./index.js"},"./index.js":{"default":"./index.js"},"./index.mjs":{"default":"./index.mjs"},"./lib/*.mjs":{"default":"./lib/*.mjs"},"./lib/*.js":{"default":"./lib/*.js"},"./lib/*":{"import":"./lib/*.mjs","require":"./lib/*.js"},"./pagination":{"import":"./pagination.mjs","require":"./pagination.js"},"./pagination.js":{"default":"./pagination.js"},"./pagination.mjs":{"default":"./pagination.mjs"},"./realtime/*.mjs":{"default":"./realtime/*.mjs"},"./realtime/*.js":{"default":"./realtime/*.js"},"./realtime/*":{"import":"./realtime/*.mjs","require":"./realtime/*.js"},"./resource":{"import":"./resource.mjs","require":"./resource.js"},"./resource.js":{"default":"./resource.js"},"./resource.mjs":{"default":"./resource.mjs"},"./resources/*.mjs":{"default":"./resources/*.mjs"},"./resources/*.js":{"default":"./resources/*.js"},"./resources/*":{"import":"./resources/*.mjs","require":"./resources/*.js"},"./resources":{"import":"./resources.mjs","require":"./resources.js"},"./resources.js":{"default":"./resources.js"},"./resources.mjs":{"default":"./resources.mjs"},"./streaming":{"import":"./streaming.mjs","require":"./streaming.js"},"./streaming.js":{"default":"./streaming.js"},"./streaming.mjs":{"default":"./streaming.mjs"},"./uploads":{"import":"./uploads.mjs","require":"./uploads.js"},"./uploads.js":{"default":"./uploads.js"},"./uploads.mjs":{"default":"./uploads.mjs"},"./version":{"import":"./version.mjs","require":"./version.js"},"./version.js":{"default":"./version.js"},"./version.mjs":{"default":"./version.mjs"}},"peerDependencies":{"ws":"^8.18.0","zod":"^3.25 || ^4.0"},"peerDependenciesMeta":{"ws":{"optional":true},"zod":{"optional":true}},"_lastModified":"2026-06-26T03:51:28.697Z"}
@@ -1 +1 @@
1
- {"name":"zod","version":"4.3.5","type":"module","license":"MIT","author":"Colin McDonnell <zod@colinhacks.com>","description":"TypeScript-first schema declaration and validation library with static type inference","homepage":"https://zod.dev","llms":"https://zod.dev/llms.txt","llmsFull":"https://zod.dev/llms-full.txt","mcpServer":"https://mcp.inkeep.com/zod/mcp","funding":"https://github.com/sponsors/colinhacks","sideEffects":false,"files":["src","**/*.js","**/*.mjs","**/*.cjs","**/*.d.ts","**/*.d.mts","**/*.d.cts","**/package.json"],"keywords":["typescript","schema","validation","type","inference"],"main":"./index.cjs","types":"./index.d.cts","module":"./index.js","zshy":{"exports":{"./package.json":"./package.json",".":"./src/index.ts","./mini":"./src/mini/index.ts","./locales":"./src/locales/index.ts","./v3":"./src/v3/index.ts","./v4":"./src/v4/index.ts","./v4-mini":"./src/v4-mini/index.ts","./v4/mini":"./src/v4/mini/index.ts","./v4/core":"./src/v4/core/index.ts","./v4/locales":"./src/v4/locales/index.ts","./v4/locales/*":"./src/v4/locales/*"},"conditions":{"@zod/source":"src"}},"exports":{"./package.json":"./package.json",".":{"@zod/source":"./src/index.ts","types":"./index.d.cts","import":"./index.js","require":"./index.cjs"},"./mini":{"@zod/source":"./src/mini/index.ts","types":"./mini/index.d.cts","import":"./mini/index.js","require":"./mini/index.cjs"},"./locales":{"@zod/source":"./src/locales/index.ts","types":"./locales/index.d.cts","import":"./locales/index.js","require":"./locales/index.cjs"},"./v3":{"@zod/source":"./src/v3/index.ts","types":"./v3/index.d.cts","import":"./v3/index.js","require":"./v3/index.cjs"},"./v4":{"@zod/source":"./src/v4/index.ts","types":"./v4/index.d.cts","import":"./v4/index.js","require":"./v4/index.cjs"},"./v4-mini":{"@zod/source":"./src/v4-mini/index.ts","types":"./v4-mini/index.d.cts","import":"./v4-mini/index.js","require":"./v4-mini/index.cjs"},"./v4/mini":{"@zod/source":"./src/v4/mini/index.ts","types":"./v4/mini/index.d.cts","import":"./v4/mini/index.js","require":"./v4/mini/index.cjs"},"./v4/core":{"@zod/source":"./src/v4/core/index.ts","types":"./v4/core/index.d.cts","import":"./v4/core/index.js","require":"./v4/core/index.cjs"},"./v4/locales":{"@zod/source":"./src/v4/locales/index.ts","types":"./v4/locales/index.d.cts","import":"./v4/locales/index.js","require":"./v4/locales/index.cjs"},"./v4/locales/*":{"@zod/source":"./src/v4/locales/*","types":"./v4/locales/*","import":"./v4/locales/*","require":"./v4/locales/*"}},"repository":{"type":"git","url":"git+https://github.com/colinhacks/zod.git"},"bugs":{"url":"https://github.com/colinhacks/zod/issues"},"support":{"backing":{"npm-funding":true}},"scripts":{"clean":"git clean -xdf . -e node_modules","build":"zshy --project tsconfig.build.json","postbuild":"tsx ../../scripts/write-stub-package-jsons.ts && pnpm biome check --write .","test:watch":"pnpm vitest","test":"pnpm vitest run","prepublishOnly":"tsx ../../scripts/check-versions.ts"},"_lastModified":"2026-06-24T23:38:58.321Z"}
1
+ {"name":"zod","version":"4.3.5","type":"module","license":"MIT","author":"Colin McDonnell <zod@colinhacks.com>","description":"TypeScript-first schema declaration and validation library with static type inference","homepage":"https://zod.dev","llms":"https://zod.dev/llms.txt","llmsFull":"https://zod.dev/llms-full.txt","mcpServer":"https://mcp.inkeep.com/zod/mcp","funding":"https://github.com/sponsors/colinhacks","sideEffects":false,"files":["src","**/*.js","**/*.mjs","**/*.cjs","**/*.d.ts","**/*.d.mts","**/*.d.cts","**/package.json"],"keywords":["typescript","schema","validation","type","inference"],"main":"./index.cjs","types":"./index.d.cts","module":"./index.js","zshy":{"exports":{"./package.json":"./package.json",".":"./src/index.ts","./mini":"./src/mini/index.ts","./locales":"./src/locales/index.ts","./v3":"./src/v3/index.ts","./v4":"./src/v4/index.ts","./v4-mini":"./src/v4-mini/index.ts","./v4/mini":"./src/v4/mini/index.ts","./v4/core":"./src/v4/core/index.ts","./v4/locales":"./src/v4/locales/index.ts","./v4/locales/*":"./src/v4/locales/*"},"conditions":{"@zod/source":"src"}},"exports":{"./package.json":"./package.json",".":{"@zod/source":"./src/index.ts","types":"./index.d.cts","import":"./index.js","require":"./index.cjs"},"./mini":{"@zod/source":"./src/mini/index.ts","types":"./mini/index.d.cts","import":"./mini/index.js","require":"./mini/index.cjs"},"./locales":{"@zod/source":"./src/locales/index.ts","types":"./locales/index.d.cts","import":"./locales/index.js","require":"./locales/index.cjs"},"./v3":{"@zod/source":"./src/v3/index.ts","types":"./v3/index.d.cts","import":"./v3/index.js","require":"./v3/index.cjs"},"./v4":{"@zod/source":"./src/v4/index.ts","types":"./v4/index.d.cts","import":"./v4/index.js","require":"./v4/index.cjs"},"./v4-mini":{"@zod/source":"./src/v4-mini/index.ts","types":"./v4-mini/index.d.cts","import":"./v4-mini/index.js","require":"./v4-mini/index.cjs"},"./v4/mini":{"@zod/source":"./src/v4/mini/index.ts","types":"./v4/mini/index.d.cts","import":"./v4/mini/index.js","require":"./v4/mini/index.cjs"},"./v4/core":{"@zod/source":"./src/v4/core/index.ts","types":"./v4/core/index.d.cts","import":"./v4/core/index.js","require":"./v4/core/index.cjs"},"./v4/locales":{"@zod/source":"./src/v4/locales/index.ts","types":"./v4/locales/index.d.cts","import":"./v4/locales/index.js","require":"./v4/locales/index.cjs"},"./v4/locales/*":{"@zod/source":"./src/v4/locales/*","types":"./v4/locales/*","import":"./v4/locales/*","require":"./v4/locales/*"}},"repository":{"type":"git","url":"git+https://github.com/colinhacks/zod.git"},"bugs":{"url":"https://github.com/colinhacks/zod/issues"},"support":{"backing":{"npm-funding":true}},"scripts":{"clean":"git clean -xdf . -e node_modules","build":"zshy --project tsconfig.build.json","postbuild":"tsx ../../scripts/write-stub-package-jsons.ts && pnpm biome check --write .","test:watch":"pnpm vitest","test":"pnpm vitest run","prepublishOnly":"tsx ../../scripts/check-versions.ts"},"_lastModified":"2026-06-26T03:51:26.681Z"}
@@ -54,6 +54,7 @@ var import_stream = require("@langchain/core/utils/stream");
54
54
  var import_utils2 = require("./utils");
55
55
  var import_base = require("@langchain/core/callbacks/base");
56
56
  var import_shared = require("../../ai/tools/sub-agents/shared");
57
+ var import_tool_call_sanitizer = require("./tool-call-sanitizer");
57
58
  class AIEmployee {
58
59
  sessionId;
59
60
  from = "main-agent";
@@ -1093,7 +1094,16 @@ If information is missing, clearly state it in the summary.</Important>`;
1093
1094
  role: "assistant",
1094
1095
  content,
1095
1096
  tool_calls: msg.toolCalls,
1096
- additional_kwargs: (_b = msg.metadata) == null ? void 0 : _b.additional_kwargs
1097
+ additional_kwargs: (0, import_tool_call_sanitizer.sanitizeAdditionalKwargsForToolCalls)((_b = msg.metadata) == null ? void 0 : _b.additional_kwargs, msg.toolCalls, {
1098
+ onDiscard: (info) => {
1099
+ var _a2;
1100
+ this.logger.warn("Discard malformed raw tool calls from AI message", {
1101
+ phase: "formatMessages",
1102
+ messageId: (_a2 = msg.metadata) == null ? void 0 : _a2.id,
1103
+ ...info
1104
+ });
1105
+ }
1106
+ }).additionalKwargs
1097
1107
  });
1098
1108
  }
1099
1109
  return formattedMessages;
@@ -1302,7 +1312,8 @@ If information is missing, clearly state it in the summary.</Important>`;
1302
1312
  (0, import_middleware.toolInteractionMiddleware)(this, tools),
1303
1313
  (0, import_middleware.toolCallStatusMiddleware)(this),
1304
1314
  ...inWorkflow ? [(0, import_middleware.workflowHistoryMiddleware)(this, this.db)] : [],
1305
- (0, import_middleware.conversationMiddleware)(this, { providerName, llmService, model, messageId, agentThread })
1315
+ (0, import_middleware.conversationMiddleware)(this, { providerName, llmService, model, messageId, agentThread }),
1316
+ (0, import_middleware.toolCallSanitizerMiddleware)({ logger: this.logger })
1306
1317
  ];
1307
1318
  }
1308
1319
  async getCurrentThread() {
@@ -8,5 +8,6 @@
8
8
  */
9
9
  export * from './conversation';
10
10
  export * from './skill-tools';
11
+ export * from './tool-call-sanitizer';
11
12
  export * from './tools';
12
13
  export * from './workflow-history';
@@ -25,12 +25,14 @@ var middleware_exports = {};
25
25
  module.exports = __toCommonJS(middleware_exports);
26
26
  __reExport(middleware_exports, require("./conversation"), module.exports);
27
27
  __reExport(middleware_exports, require("./skill-tools"), module.exports);
28
+ __reExport(middleware_exports, require("./tool-call-sanitizer"), module.exports);
28
29
  __reExport(middleware_exports, require("./tools"), module.exports);
29
30
  __reExport(middleware_exports, require("./workflow-history"), module.exports);
30
31
  // Annotate the CommonJS export names for ESM import in node:
31
32
  0 && (module.exports = {
32
33
  ...require("./conversation"),
33
34
  ...require("./skill-tools"),
35
+ ...require("./tool-call-sanitizer"),
34
36
  ...require("./tools"),
35
37
  ...require("./workflow-history")
36
38
  });
@@ -0,0 +1,16 @@
1
+ /**
2
+ * This file is part of the NocoBase (R) project.
3
+ * Copyright (c) 2020-2024 NocoBase Co., Ltd.
4
+ * Authors: NocoBase Team.
5
+ *
6
+ * This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
7
+ * For more information, please refer to: https://www.nocobase.com/agreement.
8
+ */
9
+ type ToolCallSanitizerLogger = {
10
+ warn: (message: string, meta?: Record<string, unknown>) => void;
11
+ };
12
+ type ToolCallSanitizerMiddlewareOptions = {
13
+ logger?: ToolCallSanitizerLogger;
14
+ };
15
+ export declare const toolCallSanitizerMiddleware: (options?: ToolCallSanitizerMiddlewareOptions) => import("langchain/dist/agents/middleware/types.cjs").AgentMiddleware<never, undefined, unknown, readonly (import("@langchain/core/dist/tools").ClientTool | import("@langchain/core/dist/tools").ServerTool)[]>;
16
+ export {};
@@ -0,0 +1,90 @@
1
+ /**
2
+ * This file is part of the NocoBase (R) project.
3
+ * Copyright (c) 2020-2024 NocoBase Co., Ltd.
4
+ * Authors: NocoBase Team.
5
+ *
6
+ * This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
7
+ * For more information, please refer to: https://www.nocobase.com/agreement.
8
+ */
9
+
10
+ var __defProp = Object.defineProperty;
11
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
12
+ var __getOwnPropNames = Object.getOwnPropertyNames;
13
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
14
+ var __export = (target, all) => {
15
+ for (var name in all)
16
+ __defProp(target, name, { get: all[name], enumerable: true });
17
+ };
18
+ var __copyProps = (to, from, except, desc) => {
19
+ if (from && typeof from === "object" || typeof from === "function") {
20
+ for (let key of __getOwnPropNames(from))
21
+ if (!__hasOwnProp.call(to, key) && key !== except)
22
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
23
+ }
24
+ return to;
25
+ };
26
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
27
+ var tool_call_sanitizer_exports = {};
28
+ __export(tool_call_sanitizer_exports, {
29
+ toolCallSanitizerMiddleware: () => toolCallSanitizerMiddleware
30
+ });
31
+ module.exports = __toCommonJS(tool_call_sanitizer_exports);
32
+ var import_messages = require("@langchain/core/messages");
33
+ var import_langchain = require("langchain");
34
+ var import_tool_call_sanitizer = require("../tool-call-sanitizer");
35
+ const buildMessageUpdates = (messages, options, phase) => {
36
+ const updates = [];
37
+ for (const message of messages) {
38
+ if (!import_messages.AIMessage.isInstance(message) || !message.id) {
39
+ continue;
40
+ }
41
+ const sanitizedMessage = (0, import_tool_call_sanitizer.sanitizeLangChainAIMessage)(message, {
42
+ onDiscard: (info) => {
43
+ var _a, _b;
44
+ (_b = options.logger) == null ? void 0 : _b.warn("Discard malformed raw tool calls from AI message", {
45
+ phase,
46
+ messageId: message.id,
47
+ invalidToolCallCount: ((_a = message.invalid_tool_calls) == null ? void 0 : _a.length) ?? 0,
48
+ ...info
49
+ });
50
+ }
51
+ });
52
+ if (!sanitizedMessage) {
53
+ continue;
54
+ }
55
+ updates.push(
56
+ new import_messages.AIMessage({
57
+ id: sanitizedMessage.id,
58
+ content: sanitizedMessage.content,
59
+ name: sanitizedMessage.name,
60
+ additional_kwargs: sanitizedMessage.additional_kwargs,
61
+ response_metadata: sanitizedMessage.response_metadata,
62
+ tool_calls: sanitizedMessage.tool_calls,
63
+ invalid_tool_calls: sanitizedMessage.invalid_tool_calls,
64
+ usage_metadata: sanitizedMessage.usage_metadata
65
+ })
66
+ );
67
+ }
68
+ return updates;
69
+ };
70
+ const toolCallSanitizerMiddleware = (options = {}) => (0, import_langchain.createMiddleware)({
71
+ name: "ToolCallSanitizerMiddleware",
72
+ beforeModel: (state) => {
73
+ const updates = buildMessageUpdates(state.messages ?? [], options, "beforeModel");
74
+ if (!updates.length) {
75
+ return;
76
+ }
77
+ return { messages: updates };
78
+ },
79
+ afterModel: (state) => {
80
+ const updates = buildMessageUpdates(state.messages ?? [], options, "afterModel");
81
+ if (!updates.length) {
82
+ return;
83
+ }
84
+ return { messages: updates };
85
+ }
86
+ });
87
+ // Annotate the CommonJS export names for ESM import in node:
88
+ 0 && (module.exports = {
89
+ toolCallSanitizerMiddleware
90
+ });
@@ -0,0 +1,26 @@
1
+ /**
2
+ * This file is part of the NocoBase (R) project.
3
+ * Copyright (c) 2020-2024 NocoBase Co., Ltd.
4
+ * Authors: NocoBase Team.
5
+ *
6
+ * This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
7
+ * For more information, please refer to: https://www.nocobase.com/agreement.
8
+ */
9
+ import { AIMessage } from '@langchain/core/messages';
10
+ type AdditionalKwargs = Record<string, unknown>;
11
+ type DiscardedToolCallsInfo = {
12
+ rawToolCallCount: number;
13
+ parsedToolCallCount: number;
14
+ rawToolCallIds: string[];
15
+ rawToolCallNames: string[];
16
+ };
17
+ type SanitizeAdditionalKwargsOptions = {
18
+ onDiscard?: (info: DiscardedToolCallsInfo) => void;
19
+ };
20
+ type SanitizeAdditionalKwargsResult = {
21
+ changed: boolean;
22
+ additionalKwargs?: AdditionalKwargs;
23
+ };
24
+ export declare const sanitizeAdditionalKwargsForToolCalls: (additionalKwargs: AdditionalKwargs | undefined, parsedToolCalls?: unknown[] | null, options?: SanitizeAdditionalKwargsOptions) => SanitizeAdditionalKwargsResult;
25
+ export declare const sanitizeLangChainAIMessage: (message: AIMessage, options?: SanitizeAdditionalKwargsOptions) => AIMessage<import("@langchain/core/dist/messages/message").MessageStructure<import("@langchain/core/dist/messages/message").MessageToolSet>>;
26
+ export {};
@@ -0,0 +1,84 @@
1
+ /**
2
+ * This file is part of the NocoBase (R) project.
3
+ * Copyright (c) 2020-2024 NocoBase Co., Ltd.
4
+ * Authors: NocoBase Team.
5
+ *
6
+ * This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
7
+ * For more information, please refer to: https://www.nocobase.com/agreement.
8
+ */
9
+
10
+ var __defProp = Object.defineProperty;
11
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
12
+ var __getOwnPropNames = Object.getOwnPropertyNames;
13
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
14
+ var __export = (target, all) => {
15
+ for (var name in all)
16
+ __defProp(target, name, { get: all[name], enumerable: true });
17
+ };
18
+ var __copyProps = (to, from, except, desc) => {
19
+ if (from && typeof from === "object" || typeof from === "function") {
20
+ for (let key of __getOwnPropNames(from))
21
+ if (!__hasOwnProp.call(to, key) && key !== except)
22
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
23
+ }
24
+ return to;
25
+ };
26
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
27
+ var tool_call_sanitizer_exports = {};
28
+ __export(tool_call_sanitizer_exports, {
29
+ sanitizeAdditionalKwargsForToolCalls: () => sanitizeAdditionalKwargsForToolCalls,
30
+ sanitizeLangChainAIMessage: () => sanitizeLangChainAIMessage
31
+ });
32
+ module.exports = __toCommonJS(tool_call_sanitizer_exports);
33
+ const hasRawToolCalls = (additionalKwargs) => Array.isArray(additionalKwargs == null ? void 0 : additionalKwargs.tool_calls) && additionalKwargs.tool_calls.length > 0;
34
+ const hasParsedToolCalls = (toolCalls) => Array.isArray(toolCalls) && toolCalls.length > 0;
35
+ const isRecord = (value) => typeof value === "object" && value !== null && !Array.isArray(value);
36
+ const collectRawToolCallValues = (toolCalls, key) => toolCalls.map((toolCall) => {
37
+ if (!isRecord(toolCall)) {
38
+ return null;
39
+ }
40
+ if (key === "name") {
41
+ const fn = toolCall.function;
42
+ if (isRecord(fn) && typeof fn.name === "string") {
43
+ return fn.name;
44
+ }
45
+ }
46
+ const value = toolCall[key];
47
+ return typeof value === "string" ? value : null;
48
+ }).filter((value) => Boolean(value));
49
+ const sanitizeAdditionalKwargsForToolCalls = (additionalKwargs, parsedToolCalls, options = {}) => {
50
+ var _a;
51
+ if (!hasRawToolCalls(additionalKwargs) || hasParsedToolCalls(parsedToolCalls)) {
52
+ return {
53
+ changed: false,
54
+ additionalKwargs
55
+ };
56
+ }
57
+ const rawToolCalls = additionalKwargs.tool_calls;
58
+ (_a = options.onDiscard) == null ? void 0 : _a.call(options, {
59
+ rawToolCallCount: rawToolCalls.length,
60
+ parsedToolCallCount: (parsedToolCalls == null ? void 0 : parsedToolCalls.length) ?? 0,
61
+ rawToolCallIds: collectRawToolCallValues(rawToolCalls, "id"),
62
+ rawToolCallNames: collectRawToolCallValues(rawToolCalls, "name")
63
+ });
64
+ const sanitized = { ...additionalKwargs };
65
+ delete sanitized.tool_calls;
66
+ return {
67
+ changed: true,
68
+ additionalKwargs: Object.keys(sanitized).length > 0 ? sanitized : void 0
69
+ };
70
+ };
71
+ const sanitizeLangChainAIMessage = (message, options = {}) => {
72
+ const sanitized = sanitizeAdditionalKwargsForToolCalls(message.additional_kwargs, message.tool_calls, options);
73
+ if (!sanitized.changed) {
74
+ return null;
75
+ }
76
+ message.additional_kwargs = sanitized.additionalKwargs ?? {};
77
+ message.lc_kwargs.additional_kwargs = message.additional_kwargs;
78
+ return message;
79
+ };
80
+ // Annotate the CommonJS export names for ESM import in node:
81
+ 0 && (module.exports = {
82
+ sanitizeAdditionalKwargsForToolCalls,
83
+ sanitizeLangChainAIMessage
84
+ });
@@ -31,6 +31,7 @@ __export(utils_exports, {
31
31
  convertToolMessage: () => convertToolMessage
32
32
  });
33
33
  module.exports = __toCommonJS(utils_exports);
34
+ var import_tool_call_sanitizer = require("./tool-call-sanitizer");
34
35
  const convertAIMessage = ({
35
36
  aiEmployee,
36
37
  providerName: provider,
@@ -89,8 +90,19 @@ const convertAIMessage = ({
89
90
  if (aiMessage.response_metadata) {
90
91
  values.metadata.response_metadata = aiMessage.response_metadata;
91
92
  }
92
- if (aiMessage.additional_kwargs) {
93
- values.metadata.additional_kwargs = aiMessage.additional_kwargs;
93
+ const additionalKwargs = (0, import_tool_call_sanitizer.sanitizeAdditionalKwargsForToolCalls)(aiMessage.additional_kwargs, toolCalls, {
94
+ onDiscard: (info) => {
95
+ var _a2, _b;
96
+ (_b = aiEmployee.logger) == null ? void 0 : _b.warn("Discard malformed raw tool calls from AI message", {
97
+ phase: "convertAIMessage",
98
+ messageId: aiMessage.id,
99
+ invalidToolCallCount: ((_a2 = aiMessage.invalid_tool_calls) == null ? void 0 : _a2.length) ?? 0,
100
+ ...info
101
+ });
102
+ }
103
+ }).additionalKwargs;
104
+ if (additionalKwargs) {
105
+ values.metadata.additional_kwargs = additionalKwargs;
94
106
  }
95
107
  return values;
96
108
  };
package/package.json CHANGED
@@ -6,7 +6,7 @@
6
6
  "description": "Create AI employees with diverse skills to collaborate with humans, build systems, and handle business operations.",
7
7
  "description.ru-RU": "Поддержка интеграции с AI-сервисами: предоставляются AI-узлы для рабочих процессов, расширяя возможности бизнес-обработки.",
8
8
  "description.zh-CN": "创建各种技能的 AI 员工,与人类协同,搭建系统,处理业务。",
9
- "version": "2.1.11",
9
+ "version": "2.2.0-alpha.2",
10
10
  "main": "dist/server/index.js",
11
11
  "homepage": "https://docs.nocobase.com/handbook/action-ai",
12
12
  "homepage.ru-RU": "https://docs-ru.nocobase.com/handbook/action-ai",
@@ -65,5 +65,5 @@
65
65
  "keywords": [
66
66
  "AI"
67
67
  ],
68
- "gitHead": "1ccf891d837e21089f65f84b892407b34a0a0cb9"
68
+ "gitHead": "9dd5224bb8f6c1ac12d766b9f175bdc29bddd845"
69
69
  }