@nocobase/app-plugin-agents 1.0.0-beta.21 → 1.0.0-beta.23
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 +43 -0
- package/README.md +72 -12
- package/dist/cli/runner-token.js +1 -1
- package/dist/cli/runner-token.js.map +1 -1
- package/dist/client/chat/client-id.d.ts +1 -2
- package/dist/client/chat/client-id.d.ts.map +1 -1
- package/dist/client/chat/client-id.js +1 -16
- package/dist/client/chat/client-id.js.map +1 -1
- package/dist/client/chat/message-model.d.ts +0 -1
- package/dist/client/chat/message-model.d.ts.map +1 -1
- package/dist/client/chat/message-model.js +13 -2
- package/dist/client/chat/message-model.js.map +1 -1
- package/dist/client/components/command-line.d.ts +2 -1
- package/dist/client/components/command-line.d.ts.map +1 -1
- package/dist/client/components/command-line.js +8 -9
- package/dist/client/components/command-line.js.map +1 -1
- package/dist/client/components/variables/variable-dialogs.js +2 -2
- package/dist/client/components/variables/variable-dialogs.js.map +1 -1
- package/dist/client/lib/install.d.ts +3 -3
- package/dist/client/lib/install.d.ts.map +1 -1
- package/dist/client/lib/install.js +3 -5
- package/dist/client/lib/install.js.map +1 -1
- package/dist/client/lib/runner-tools.d.ts +4 -0
- package/dist/client/lib/runner-tools.d.ts.map +1 -0
- package/dist/client/lib/runner-tools.js +5 -0
- package/dist/client/lib/runner-tools.js.map +1 -0
- package/dist/client/locales/chat.en-US.d.ts +17 -0
- package/dist/client/locales/chat.en-US.d.ts.map +1 -1
- package/dist/client/locales/chat.en-US.js +17 -0
- package/dist/client/locales/chat.en-US.js.map +1 -1
- package/dist/client/locales/chat.zh-CN.d.ts.map +1 -1
- package/dist/client/locales/chat.zh-CN.js +17 -0
- package/dist/client/locales/chat.zh-CN.js.map +1 -1
- package/dist/client/locales/de-DE.d.ts.map +1 -1
- package/dist/client/locales/de-DE.js +8 -1
- package/dist/client/locales/de-DE.js.map +1 -1
- package/dist/client/locales/en-US.js +9 -9
- package/dist/client/locales/en-US.js.map +1 -1
- package/dist/client/locales/es-ES.d.ts.map +1 -1
- package/dist/client/locales/es-ES.js +8 -1
- package/dist/client/locales/es-ES.js.map +1 -1
- package/dist/client/locales/fr-FR.d.ts.map +1 -1
- package/dist/client/locales/fr-FR.js +8 -1
- package/dist/client/locales/fr-FR.js.map +1 -1
- package/dist/client/locales/id-ID.d.ts.map +1 -1
- package/dist/client/locales/id-ID.js +8 -1
- package/dist/client/locales/id-ID.js.map +1 -1
- package/dist/client/locales/ja-JP.d.ts.map +1 -1
- package/dist/client/locales/ja-JP.js +8 -1
- package/dist/client/locales/ja-JP.js.map +1 -1
- package/dist/client/locales/pt-BR.d.ts.map +1 -1
- package/dist/client/locales/pt-BR.js +8 -1
- package/dist/client/locales/pt-BR.js.map +1 -1
- package/dist/client/locales/runWait.en-US.js +1 -1
- package/dist/client/locales/runWait.en-US.js.map +1 -1
- package/dist/client/locales/runWait.zh-CN.js +1 -1
- package/dist/client/locales/runtimes.en-US.d.ts +10 -1
- package/dist/client/locales/runtimes.en-US.d.ts.map +1 -1
- package/dist/client/locales/runtimes.en-US.js +18 -9
- package/dist/client/locales/runtimes.en-US.js.map +1 -1
- package/dist/client/locales/runtimes.zh-CN.d.ts.map +1 -1
- package/dist/client/locales/runtimes.zh-CN.js +18 -9
- package/dist/client/locales/runtimes.zh-CN.js.map +1 -1
- package/dist/client/locales/vi-VN.d.ts.map +1 -1
- package/dist/client/locales/vi-VN.js +8 -1
- package/dist/client/locales/vi-VN.js.map +1 -1
- package/dist/client/locales/zh-CN.js +9 -9
- package/dist/client/locales/zh-CN.js.map +1 -1
- package/dist/client/locales/zh-TW.d.ts.map +1 -1
- package/dist/client/locales/zh-TW.js +8 -1
- package/dist/client/locales/zh-TW.js.map +1 -1
- package/dist/client/pages/runtimes/connect.js +18 -8
- package/dist/client/pages/runtimes/connect.js.map +1 -1
- package/dist/client/pages/runtimes/index.js +1 -1
- package/dist/client/pages/runtimes/runner-overview.d.ts.map +1 -1
- package/dist/client/pages/runtimes/runner-overview.js +3 -2
- package/dist/client/pages/runtimes/runner-overview.js.map +1 -1
- package/dist/client/pages/usage/prices/model.d.ts +1 -1
- package/dist/client/pages/usage/prices/model.js +1 -1
- package/dist/client/plugin.js +1 -1
- package/dist/client/plugin.js.map +1 -1
- package/dist/client/routes.d.ts +1 -1
- package/dist/database/migrations/.manifest.json +4 -0
- package/dist/database/migrations/202610290001_ag_repair_runner_agents.d.ts +5 -0
- package/dist/database/migrations/202610290001_ag_repair_runner_agents.d.ts.map +1 -0
- package/dist/database/migrations/202610290001_ag_repair_runner_agents.js +72 -0
- package/dist/database/migrations/202610290001_ag_repair_runner_agents.js.map +1 -0
- package/dist/package.json +2 -1
- package/dist/server/composition.d.ts +2 -0
- package/dist/server/composition.d.ts.map +1 -1
- package/dist/server/composition.js +9 -3
- package/dist/server/composition.js.map +1 -1
- package/dist/server/core/agents/agent.store.d.ts +5 -3
- package/dist/server/core/agents/agent.store.d.ts.map +1 -1
- package/dist/server/core/agents/agent.store.js +25 -6
- package/dist/server/core/agents/agent.store.js.map +1 -1
- package/dist/server/core/conversations/availability.d.ts +1 -1
- package/dist/server/core/runs/claim.js +6 -6
- package/dist/server/core/runs/claim.js.map +1 -1
- package/dist/server/core/runs/eligibility.d.ts +3 -3
- package/dist/server/core/runs/eligibility.d.ts.map +1 -1
- package/dist/server/core/runs/run-requests.js +1 -1
- package/dist/server/core/runs/run-requests.js.map +1 -1
- package/dist/server/core/runs/run.service.d.ts +1 -1
- package/dist/server/core/runs/run.store.d.ts +1 -1
- package/dist/server/core/runs/run.store.d.ts.map +1 -1
- package/dist/server/core/runs/workload.js +1 -1
- package/dist/server/core/runs/workload.js.map +1 -1
- package/dist/server/core/variables/variable.service.d.ts +2 -2
- package/dist/server/core/variables/variable.service.js +1 -1
- package/dist/server/core/variables/variable.service.js.map +1 -1
- package/dist/server/index.d.ts +2 -0
- package/dist/server/index.d.ts.map +1 -1
- package/dist/server/index.js +1 -0
- package/dist/server/index.js.map +1 -1
- package/dist/server/jobs/job.service.d.ts +1 -1
- package/dist/server/jobs/job.service.js +1 -1
- package/dist/server/jobs/spec.d.ts +1 -1
- package/dist/server/jobs/spec.d.ts.map +1 -1
- package/dist/server/jobs/spec.js +2 -2
- package/dist/server/jobs/spec.js.map +1 -1
- package/dist/server/online/agent/contracts.d.ts +0 -3
- package/dist/server/online/agent/contracts.d.ts.map +1 -1
- package/dist/server/online/agent/messages/projection.d.ts.map +1 -1
- package/dist/server/online/agent/messages/projection.js +3 -0
- package/dist/server/online/agent/messages/projection.js.map +1 -1
- package/dist/server/online/agent/native/backend.d.ts +2 -0
- package/dist/server/online/agent/native/backend.d.ts.map +1 -1
- package/dist/server/online/agent/native/backend.js.map +1 -1
- package/dist/server/online/agent/native/execution.d.ts +2 -0
- package/dist/server/online/agent/native/execution.d.ts.map +1 -1
- package/dist/server/online/agent/native/execution.js +56 -11
- package/dist/server/online/agent/native/execution.js.map +1 -1
- package/dist/server/online/agent/persistence/manager.d.ts +1 -2
- package/dist/server/online/agent/persistence/manager.d.ts.map +1 -1
- package/dist/server/online/agent/persistence/manager.js +0 -7
- package/dist/server/online/agent/persistence/manager.js.map +1 -1
- package/dist/server/online/agent/persistence/store.d.ts +12 -11
- package/dist/server/online/agent/persistence/store.d.ts.map +1 -1
- package/dist/server/online/agent/persistence/store.js +56 -39
- package/dist/server/online/agent/persistence/store.js.map +1 -1
- package/dist/server/online/agent/service.d.ts +2 -0
- package/dist/server/online/agent/service.d.ts.map +1 -1
- package/dist/server/online/agent/service.js.map +1 -1
- package/dist/server/online/files/cache.d.ts +19 -0
- package/dist/server/online/files/cache.d.ts.map +1 -0
- package/dist/server/online/files/cache.js +52 -0
- package/dist/server/online/files/cache.js.map +1 -0
- package/dist/server/online/files/errors.d.ts +8 -0
- package/dist/server/online/files/errors.d.ts.map +1 -0
- package/dist/server/online/files/errors.js +14 -0
- package/dist/server/online/files/errors.js.map +1 -0
- package/dist/server/online/files/input.d.ts +23 -0
- package/dist/server/online/files/input.d.ts.map +1 -0
- package/dist/server/online/files/input.js +129 -0
- package/dist/server/online/files/input.js.map +1 -0
- package/dist/server/online/files/kimi.d.ts +11 -0
- package/dist/server/online/files/kimi.d.ts.map +1 -0
- package/dist/server/online/files/kimi.js +177 -0
- package/dist/server/online/files/kimi.js.map +1 -0
- package/dist/server/online/files/profiles.d.ts +13 -0
- package/dist/server/online/files/profiles.d.ts.map +1 -0
- package/dist/server/online/files/profiles.js +124 -0
- package/dist/server/online/files/profiles.js.map +1 -0
- package/dist/server/online/files/service.d.ts +35 -0
- package/dist/server/online/files/service.d.ts.map +1 -0
- package/dist/server/online/files/service.js +174 -0
- package/dist/server/online/files/service.js.map +1 -0
- package/dist/server/online/files/types.d.ts +32 -0
- package/dist/server/online/files/types.d.ts.map +1 -0
- package/dist/server/online/files/types.js +2 -0
- package/dist/server/online/files/types.js.map +1 -0
- package/dist/server/online/search/capabilities.d.ts.map +1 -1
- package/dist/server/online/search/capabilities.js +22 -7
- package/dist/server/online/search/capabilities.js.map +1 -1
- package/dist/server/providers/agents.d.ts +1 -0
- package/dist/server/providers/agents.d.ts.map +1 -1
- package/dist/server/providers/agents.js +1 -0
- package/dist/server/providers/agents.js.map +1 -1
- package/dist/server/providers/authorization.d.ts +2 -2
- package/dist/server/providers/authorization.js +2 -2
- package/dist/server/routes/admin.js +3 -3
- package/dist/server/routes/admin.js.map +1 -1
- package/dist/server/routes/run-requests.js +1 -1
- package/dist/server/routes/run-requests.js.map +1 -1
- package/dist/server/routes/runners/admin.js +6 -6
- package/dist/server/routes/runners/admin.js.map +1 -1
- package/dist/server/routes/runners/install.js +1 -1
- package/dist/server/routes/schemas.d.ts.map +1 -1
- package/dist/server/routes/schemas.js +17 -7
- package/dist/server/routes/schemas.js.map +1 -1
- package/dist/server/runners/runner.service.js +1 -1
- package/dist/server/vendor/just-bash.js +117 -117
- package/dist/shared/access.d.ts +2 -2
- package/dist/shared/access.js +2 -2
- package/dist/shared/agents.d.ts +2 -2
- package/dist/shared/agents.d.ts.map +1 -1
- package/dist/shared/conversations.d.ts +1 -1
- package/dist/shared/conversations.d.ts.map +1 -1
- package/dist/shared/file-input-failures.d.ts +5 -0
- package/dist/shared/file-input-failures.d.ts.map +1 -0
- package/dist/shared/file-input-failures.js +20 -0
- package/dist/shared/file-input-failures.js.map +1 -0
- package/dist/shared/locales/access.en-US.js +3 -3
- package/dist/shared/locales/access.en-US.js.map +1 -1
- package/dist/shared/locales/access.zh-CN.js +3 -3
- package/dist/shared/locales/access.zh-CN.js.map +1 -1
- package/dist/shared/models.d.ts +2 -0
- package/dist/shared/models.d.ts.map +1 -1
- package/dist/shared/models.js.map +1 -1
- package/dist/shared/runners.d.ts +4 -4
- package/dist/shared/runners.d.ts.map +1 -1
- package/dist/shared/runners.js +2 -2
- package/dist/shared/runs.d.ts +5 -5
- package/dist/shared/runs.d.ts.map +1 -1
- package/dist/shared/runs.js +1 -1
- package/dist/shared/variables.d.ts +3 -3
- package/dist/shared/variables.d.ts.map +1 -1
- package/dist/shared/variables.js +1 -1
- package/docs/execution-history.md +1 -1
- package/docs/runner-agents.md +3 -3
- package/package.json +6 -5
- package/skills/nocobase-app-plugin-agents/SKILL.md +7 -1
- package/skills/nocobase-app-plugin-agents/references/extension-points.md +1 -1
- package/skills/nocobase-app-plugin-agents/references/runners.md +7 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,48 @@
|
|
|
1
1
|
# @nocobase/app-plugin-agents
|
|
2
2
|
|
|
3
|
+
## 1.0.0-beta.23
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- 58531da: Support plain HTTP origins when creating session and upload identifiers or copying text. Provide shared browser UUID and clipboard helpers so draft, submission and invitation actions work without secure-context APIs.
|
|
8
|
+
|
|
9
|
+
Document capability checks and user-facing explanations for secure-context browser features, require HTTP-compatible UUID and copy actions, and return an explicit copy result for localized recovery UI.
|
|
10
|
+
|
|
11
|
+
- Updated dependencies [58531da]
|
|
12
|
+
- @nocobase/app-client@4.0.0-beta.3
|
|
13
|
+
- @nocobase/app-cli@1.0.0-beta.27
|
|
14
|
+
- @nocobase/app-server@3.0.0-beta.3
|
|
15
|
+
- @nocobase/authorization@1.0.0-beta.15
|
|
16
|
+
- @nocobase/db@1.0.0-beta.22
|
|
17
|
+
- @nocobase/i18n@2.0.0-beta.1
|
|
18
|
+
- @nocobase/markdown-mermaid@0.1.0-beta.2
|
|
19
|
+
- @nocobase/service-provider@0.0.2-beta.2
|
|
20
|
+
- @nocobase/app-plugin-authentication@2.0.0-beta.13
|
|
21
|
+
- @nocobase/app-plugin-authorization@1.0.0-beta.31
|
|
22
|
+
- @nocobase/app-plugin-file@1.0.0-beta.26
|
|
23
|
+
|
|
24
|
+
## 1.0.0-beta.22
|
|
25
|
+
|
|
26
|
+
### Minor Changes
|
|
27
|
+
|
|
28
|
+
- d490379: Prepare Native OnlineAgent document attachments in detached user-level model replay copies while preserving original messages, attachment authorization, public history and search text. Reuse the same preparation pipeline for realtime and background execution, history, approvals and message editing or regeneration.
|
|
29
|
+
|
|
30
|
+
Apply Provider forwarding defaults with exact service/model/Provider/protocol/base URL overrides, bounded file and text budgets, and an instance-owned TTL/LRU cache that reauthorizes and reads current source bytes before every reuse. Unsupported user inputs become honest parsing-limitation descriptions without hiding permission, validation, budget, cancellation or genuine extraction failures.
|
|
31
|
+
|
|
32
|
+
Support connection-pinned Kimi Files extraction for Moonshot documents by default and explicitly configured compatible services. Bound upload and content responses, attempt independent best-effort remote deletion, reuse remote results only within an execution, and keep credentials and remote identifiers out of messages. Preserve canonical tool evidence during approval and finalization recovery, and omit embedded DOCX images from extracted model text.
|
|
33
|
+
|
|
34
|
+
### Patch Changes
|
|
35
|
+
|
|
36
|
+
- d490379: Show safe, actionable, localized attachment preparation failures in live chat and saved history, including unconfigured image input, unreadable documents, extraction timeouts, and file or text limits. Keep Provider messages and document contents private, preserve cancellation and model capability checks, and use a generic localized explanation for historical failures without a saved reason.
|
|
37
|
+
- d490379: Declare official DeepSeek Flash JPEG, PNG, GIF, and WebP capability in the shared model capability catalog, and derive native file routing from it regardless of service name. Remove the duplicated Examples profile while preserving exact model and endpoint admission, explicit deployment-policy overrides, local document extraction, and existing file limits.
|
|
38
|
+
- d490379: Restore legacy PDF and image routing defaults for native agent providers while preserving DeepSeek behavior and exact model overrides. Moonshot now uploads supported documents to its selected Kimi Files service by default; an exact local profile disables remote extraction. Extract Ollama PDF text locally by default and describe explicit PDF-original overrides as unavailable when its SDK would silently omit them. Preserve authorization, budgets, cancellation and user-level document replay.
|
|
39
|
+
- d490379: Keep native agent conversations usable when a user attaches an unsupported file type. Describe the filename, MIME type and parsing limitation in user-level model replay instead of failing the execution, including historical follow-up and unsupported image inputs. Preserve original attachments, authorization, input budgets and genuine parsing or Provider failures; update the Examples regression coverage without granting additional image capabilities.
|
|
40
|
+
- d490379: Omit empty or whitespace-only system instructions from native agent model requests instead of sending an empty system message rejected by Moonshot/Kimi and other strict providers. Preserve nonempty instructions verbatim and keep extracted attachment content in user messages.
|
|
41
|
+
- 4c98f67: Clarify personal and shared runtime usage, offer agent prompts and manual installation for macOS, Linux and Windows through WSL, and explain how to recover missing coding tools with the service PATH. New runtimes default to three concurrent runs. Expand installation prompts in full and require Windows agents to verify WSL Ubuntu before continuing.
|
|
42
|
+
- 01e03b7: Keep runner agents visible according to their status, derive their model entry from their tool and model, and repair stale markers or missing model entries in existing installations.
|
|
43
|
+
- Updated dependencies [d490379]
|
|
44
|
+
- @nocobase/document-extractor@0.1.0-beta.0
|
|
45
|
+
|
|
3
46
|
## 1.0.0-beta.21
|
|
4
47
|
|
|
5
48
|
### Minor Changes
|
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# @nocobase/app-plugin-agents
|
|
2
2
|
|
|
3
|
-
Applications may restrict personal runner use for comment-origin work by supplying `EnqueueRequest.comment` only at their authenticated comment entry point and binding `SubjectBinding.commentOwnerKey` and `responsibleUserId`. Runs share their first comment run as `commentRootRunId`; independent events carry no comment fields. Unconfirmed external comment work remains queued for
|
|
3
|
+
Applications may restrict personal runner use for comment-origin work by supplying `EnqueueRequest.comment` only at their authenticated comment entry point and binding `SubjectBinding.commentOwnerKey` and `responsibleUserId`. Runs share their first comment run as `commentRootRunId`; independent events carry no comment fields. Unconfirmed external comment work remains queued for shared runners. When no compatible shared runner exists, a `personalRunner` run request releases the existing chain on confirmation instead of creating another run. The original requester can use the existing `runAsMe` endpoint from a pending or rejected personal runner request; rejection remains recorded. Claims, decisions and input merging enforce this boundary on the server without changing the runner protocol.
|
|
4
4
|
|
|
5
5
|
Agents for NocoBase applications: the agents discovered from the runners people connect, their runs, and people's conversations with agents. Agents run on runners (each a runtime: a runner on a server, a VM or someone's own device), which this plugin registers, hands work to and serves the runner and CLI tarballs for; the wire protocol runners and the application's CLI speak is `@nocobase/agent-protocol`, and the runner is `@nocobase/agent-runner` (`nocobase-runner`).
|
|
6
6
|
|
|
@@ -16,22 +16,22 @@ The plugin knows no domain of its own beyond conversations: what agents work on
|
|
|
16
16
|
|
|
17
17
|
Registering the same runner name and hostname again revokes every active prior registration and its keys for the token's owner, leaving other owners' runners untouched. Registration uses the existing transaction without a dedicated lock or additional table. Simultaneous registrations may leave multiple active records until the next registration cleans them up. Existing tasks continue through the usual sweep and retry rules.
|
|
18
18
|
|
|
19
|
-
Applications forward the `notice` event of type `run_secrets_not_allowed` to the run's actor and owner: a personal runner left the run because some of its variables are for
|
|
19
|
+
Applications forward the `notice` event of type `run_secrets_not_allowed` to the run's actor and owner: a personal runner left the run because some of its variables are for shared runners only. Its subject is the run, its parameters are `runId`, `agentId` and `variables` (in words), and its key is stable per run. `notice.cleared` settles it once a runner takes the run.
|
|
20
20
|
|
|
21
21
|
Repository access providers that mint credentials in `prepare` implement the idempotent `discard(run, prepared)` hook to revoke them when the claim is skipped or rolled back. It runs outside the transaction and receives the same prepared value as `forRun`. The application owns code host credentials and their revocation API; providers without this hook cannot revoke externally issued credentials.
|
|
22
22
|
|
|
23
23
|
- **Agents** (`agAgents`): one for each coding tool and model the runners report (`source` `runner`, its id `runnerAgentId(tool, model)`), and the application's own (`source` `system`). An agent has a name (the catalog's, or the model's id), what it is good at (`description`: the project manager hands it work by this; required to enable it), its `status` (`pending` until someone enables it, `enabled` or `disabled`), its tool and normalized model, one model entry (`modelEntries`: the tool, the model and the default reasoning effort, `medium` when the tool takes it), and when a runner last reported it (`lastReportedAt`, refreshed at most every ten minutes). Its instructions and business actions are the application's, the same for every discovered agent (`agents.setDefaults(provider)`, written to each that differs by `applyDefaults()`; actions marked `defaultOn` otherwise), and it keeps its skills, its variables and its tool policy (of which runners use only the idle timeout and the turn limit: they run agents with full access, see the agent-runner README); it may have as many runs at once as runners' slots allow. An agent no runner reported for 14 days (`AGENT_UNREPORTED_AFTER_MS`) is listed as unreported and left out of the roster until a runner reports it again. Changing an agent (`PATCH /api/agents/:agentId`, `agents.agents` manage) writes only what it is good at, its effort (one its tool takes, else 400 `EFFORT_UNSUPPORTED`) and whether it is enabled (400 `GOOD_AT_REQUIRED` without a description); an application's own agent is changed through the application (400 `AGENT_MANAGED`). Every change raises its `revision`: a patch names the revision it was made against (`expectedRevision`) and is refused with 409 `REVISION_CONFLICT` (`metadata.revision` the current one) when someone changed the agent since, and a patch that changes nothing raises nothing. Every change is kept in its history (`agAgentChanges`, `GET /api/agents/:agentId/history`, with `afterRevision` for what came after a revision): who, when, and the fields that changed with their values before and after, except its variables, which are named with whether they were added, changed or removed, never valued. Disabling an agent withdraws its queued runs at once and announces `agent.removed` (`reason` `disabled`); work for an agent that is not enabled is refused (`AGENT_NOT_ENABLED`). Nobody deletes an agent: the agents an earlier version kept were removed by the `202610240020_ag_runner_agents` migration, their rows kept with `deletedAt` for the names their runs, comments and conversations show (`GET /api/agents/agentNames` answers every agent's name, those included), their queued runs cancelled and their pending run requests withdrawn.
|
|
24
|
-
- **Runners** (`agRunners`), shown as runtimes: registered with a one-time token (`POST /api/agents/runners/registrationTokens`, or `pnpm nocobase agents runner-token`). Anyone may add a personal runner (`ownerOnly`: it runs only work its owner started) and later share it with the team; adding a
|
|
24
|
+
- **Runners** (`agRunners`), shown as runtimes: registered with a one-time token (`POST /api/agents/runners/registrationTokens`, or `pnpm nocobase agents runner-token`). Anyone may add a personal runner (`ownerOnly`: it runs only work its owner started) and later share it with the team; adding a shared runner needs `agents.runners` manage. A runner reports its system, its features, its coding tools with versions and whether each is signed in, and what its owner's local policy lets it take (`policy`); it authenticates with its key (`agRunnerCredentials`), sends heartbeats and long-polls for work. Which of its coding tools it is offered work for is chosen on the web (`enabledTools`, null for every tool), carried from "Add runtime" on the registration token (`agRegistrationTokens`). A runner speaking a protocol this application does not serve is kept connected as `upgrade_required`: it gets no work, has what it holds released, and its owner is told once per protocol through the `notice` event (`runner_upgrade_required`; `notice.cleared` once it no longer holds). Only its owner changes a runner (its name, slots, coding tools and trust), because it is their machine with their tools' sign-ins and credentials; a manager of runners changes only a runner whose owner can no longer act (none recorded, or disabled or deleted in the application's directory, `people.provide({ inactive })`). A manager of runners may still revoke anyone's runner in an emergency, and delete it once revoked: its owner is told (`runner_revoked`) and the application's `security` log records who did it. A runner whose owner can no longer act (`people.provide({ inactive })`) is refused with `RUNNER_OWNER_DISABLED`. A runner fits an agent's run only when its owner's local policy lets it take that agent's runs, on that subject, with those repositories; `availability` and the agents list count only such runners. Every heartbeat answer announces workspace reports (`workspaces`): a runner reports the working directories it keeps for this application (`POST /api/agents/runners/workspaces`, each with the last run that worked there and whether it holds unpushed work, with the free space on the disk holding them) and is told which of those runs belong to subjects whose work is over (`remove`) or goes on (`keep`), as each subject kind's `workspaces.settled` says; a kind without it never counts as over, and only the runner's own runs are answered for. The last report is kept on the runner (`agRunners.workspaceUsage`, `Runner.workspaceUsage`) with each directory's subject and what was decided, for the Runtimes page.
|
|
25
25
|
- **The claim**: one long-poll (`POST /api/agents/runners/claim?wait=true`) answers `jobs` and `runs` together, at most `free` items, from the runner's slots, which jobs and runs share (`slots`): jobs first. A heartbeat reconciles both, releasing what the server no longer thinks the runner holds and asking it to stop what was cancelled.
|
|
26
26
|
- **Jobs** (`agJobs`, `agJobEvents`): only for the off-by-default runner build method (such as an application's `acme.builds.method: runner`): a `build` (check out a commit, run an administrator's command, upload its outputs), of kinds the application registers (`jobs.register(kind, { validate, prepare, onEvent, onDone })`, then `jobs.enqueue`, `get` and `watch`). A runner takes a job only when it reports `jobs.build`, someone turned on "Takes build jobs" (`acceptJobs`), it is shared or belongs to who started the job, and its policy lets it check out the job's repository. Jobs retry `runnerOffline`, `leaseExpired`, `startTimeout`, `checkoutFailed` and `policyRefused` while attempts remain, and open the stored variables they name through this plugin's variables at claim, audited as delivered.
|
|
27
27
|
- **Distribution**: the application serves two products as standalone tarballs that bundle Node, one per platform, or as one universal tarball (`cli build --universal`) that runs on the machine's Node.js 24 or newer and is served to every platform without one of its own, answered with `universal: true` (`server/distribution`): its CLI (`agents.cli.name`, such as `acme`) and the runner, `nocobase-runner` (`RUNNER_PRODUCT`). `pnpm nocobase cli build` of `@nocobase/app-cli` packs the CLI the application's `package.json` declares under `nocobase.cli`, and `cli build --runner` the runner, each into a directory of its own, `storage/runners/dist/<channel>/<product>/`, with a `manifest.json` of every file's SHA-256 and size, so CI builds them as separate artifacts mounted into storage, or an application builds them into its own build output and points `agents.dist.dir` there, as NocoBase Studio does. The install script installs the CLI under `~/.local/share/<cli>`: by default the CLI alone, with a download token any signed-in person mints (`POST /api/agents/dist/downloadTokens`, `agDownloadTokens`: the CLI for one platform, three downloads within 30 minutes), as `curl -fsSL <server>/api/agents/dist/installScript | sh -s -- --token <token>`; "Add runtime" shows the same line with `--runner --server <server>` and a registration token, which also installs `nocobase-runner` under `~/.local/share/nocobase-runner`, runs `nocobase-runner register` and `nocobase-runner service install` (an application that serves no CLI still gets its runtime). A token of the other kind fails before anything is installed. A runner reports the product it runs as on registration and every heartbeat (`agRunners.product`), and the heartbeat answer carries an `upgrade` notice when the channel serves a newer version of that product for the runner's platform; a runner that reports none (one from before) is offered no update, and the Runtimes page says to install it again. A product the directory has no current version of may be named on npm instead (`agents.dist.npm`: its package and exact version, which a machine installs with the Node.js 24 or later it already has): the resolve route answers `{ kind: 'npm', product, version, package, channel }` to a caller that sends `accept=npm`, and a heartbeat answer carries `npmUpgrade` to a runner with the `npm` feature when it runs an older version. Everyone else is answered as before (404, no update), and a product the directory has is always served from it. The install script, `<cli> update` and the runner's self-update all ask with `accept=npm` (the runner declares `npm`) and install an npm answer with the machine's npm into the same layout as a tarball: `npm install --prefix <prefix>/versions/<version> --no-save --no-audit --no-fund --omit=optional <package>@<version>`, then a launcher at `versions/<version>/bin/<command>` that starts `node_modules/.bin/<command>` on `<prefix>/node` (`npmLauncherScript` of `@nocobase/app-cli-client/install`).
|
|
28
28
|
|
|
29
|
-
- **Runs** (`agRuns`): one agent working on one subject, keyed by (agent, subject, thread) (`agentType` is `runner`; `online` only on runs earlier versions kept). New work joins the run already on it as the same person (`actorUserId`) while that run can still be told, else that person's queued one, else starts a new run: work woken by different people never shares a run, so it neither borrows another's identity nor waits for a runner that will not take it. Runs of one key are still claimed one at a time, whoever they work as. Queued runs are claimed by `priority` (lower first; 0 by default), then oldest first; a run given a `fireAt` is not claimed before that moment. Work merged into a queued run raises it to the more urgent priority and the earlier moment of the two. A claim hands a run to a runner that fits in one transaction: the agent's tool enabled, installed and signed in there with its model among those the runner reports for the tool and not marked unavailable there (`runsEntry` in `shared/runners.ts`; recorded on the run as `tool` and `model` and passed to the tool; a model the tool's account cannot use fails the run `modelUnavailable` and marks that tool and model unavailable on the runner, `Runner.unavailableModels`, until it reports the tool's models differently), the runner shared with
|
|
29
|
+
- **Runs** (`agRuns`): one agent working on one subject, keyed by (agent, subject, thread) (`agentType` is `runner`; `online` only on runs earlier versions kept). New work joins the run already on it as the same person (`actorUserId`) while that run can still be told, else that person's queued one, else starts a new run: work woken by different people never shares a run, so it neither borrows another's identity nor waits for a runner that will not take it. Runs of one key are still claimed one at a time, whoever they work as. Queued runs are claimed by `priority` (lower first; 0 by default), then oldest first; a run given a `fireAt` is not claimed before that moment. Work merged into a queued run raises it to the more urgent priority and the earlier moment of the two. A claim hands a run to a runner that fits in one transaction: the agent's tool enabled, installed and signed in there with its model among those the runner reports for the tool and not marked unavailable there (`runsEntry` in `shared/runners.ts`; recorded on the run as `tool` and `model` and passed to the tool; a model the tool's account cannot use fails the run `modelUnavailable` and marks that tool and model unavailable on the runner, `Runner.unavailableModels`, until it reports the tool's models differently), the runner shared with all users or owned by the person who woke the agent, its features covering what the run needs (worked out from the payload: checkouts, directories, skills, secrets), a shared runner when one of the variables the run gets is for shared runners only (`teamRunnersOnly`), and a free slot within the agent's concurrency. The variables are checked and opened in the claim's transaction, so the runner receives what was checked; a personal runner left out for them notes on the run which variables asked for a shared runner (`teamOnlyVariables`, cleared when the run is taken, requeued or given new input), and its wait is `secretsNotAllowed` with those variables. Before a run exists, `eligibility` (`runnersFor`, `canClaim`, `mayQueue`, `teamOnly`) answers by the same rules whether a runner would take an agent's work done as a person, with the scopes and features the caller names; `availability` and `GET /api/agents/available` use it for the caller. A working directory that is a directory on one runner pins the run to that runner, one run at a time per directory. The claim renders the brief (kept per run, `agRunBriefs`), mints a run token, and hands over the working directories, the merged variables, the skills and the CLI to install. Events, usage and branches are recorded as the runner reports them; completing requires every input to be handled. A failed attempt is tried again after 30 seconds (`agents.runs.retryBaseDelayMs`), doubling up to ten minutes, except when the runner went away or lost its lease, which retries at once. A runner that finds the subject's working directory held by another live run reports `workspaceBusy`: the run goes back to the queue, freeing its slot, and is tried again after 30 seconds, doubling up to two minutes; these waits do not count against the agent's attempts, and the run fails `workspaceBusy` only once it has waited six hours (`WORKSPACE_WAIT_LIMIT_MS`).
|
|
30
30
|
- **Run requests** (`agRunRequests`): work someone asked of an agent on a subject another person answers for, waiting for that person to confirm it (see "Work someone else causes" below).
|
|
31
31
|
- **Workload** (`runs.workload({ subjectKind, limit? })`, `shared/runs.ts`): the open runs on one kind of subject for a board of work, without claiming anything. Held runs come with their runner, the newest input's trigger and their newest text, tool call, status or error (`lastActivity`); queued runs with their place in the claim order (among the runs claimable now, and among the agent's) and why they wait, by the claim's own rules in its order (`RUN_WAIT_REASONS`: the agent not enabled, `agentArchived`, delayed until a moment, no runner online, the agent's named runners offline, its tool not signed in anywhere, only other people's personal runners, missing features, only personal runners whose owner may not receive the run's variables, the same work already held, the agent's concurrency full, every fitting runner busy, preparation retrying, or next). A wait is a code and the values its words need (`params`), never text: the client words it with `formatRunWait(t, wait)` from `client/runs.ts`, in this plugin's namespace (`runWait.reasons.<reason>`), which an application may override in its locale file or replace with its own formatter. It also answers each agent's load (held, queued, its limit, whether a runner could take its work) and the runners' (online, holding work, slots and slots used). It reads a bounded number of tables, never one query per subject; the caller decides what of it a person may see.
|
|
32
32
|
- **Redaction**: what runners report is stored redacted. The runner redacts first; the server redacts every run event (content, output, input and meta), summary and failure detail, and every job event and failure detail again before storing them, with the protocol's redactor (`createRedactor` of `@nocobase/agent-protocol`): the secrets the claim handed out (a run's variables and token, a job's opened variables, repository token and upload headers, remembered in memory for recent claims) and the common secret patterns, each replaced with `[REDACTED]` (`server/kernel/redaction.ts`). After a restart, or on another instance, the patterns and the runner's own redaction still apply.
|
|
33
33
|
- **The sweep** (`server/runners/sweeper.ts`, the `RunnersSweep` schedule every 30 seconds, or `agents.runners.sweepIntervalMs`, on the application's jobs service, or an in-process timer without one) marks runners not heard from for 150 s offline, takes jobs back from silent runners and fails jobs far past their timeout, and takes runs back from runners that went away, lost their lease or never started, fails runs idle for twice their idle timeout, records unacknowledged cancellations, cancels queued runs of archived agents, and fails a queued run that waited longer than its subject allows (`queuedExpiryMs` on the subject's binding, counted from the run's last change or from its `fireAt`) as `queuedExpired`.
|
|
34
|
-
- **Variables** (`agSecrets`): environment variables for the agent's process, every one a secret sealed with the application's secrets service (`secrets.keys`) and bound to its scope and name, set on an agent, a working directory (`workdir`) or a scope the application registers, merged for a run in the order the subject names its scopes < its working directories < the agent, delivered only to runners with the `secrets` feature: to whichever runner takes the run, a personal runner of anyone who may use the agent included, since sharing an agent shares the tokens it works with. A variable marked `teamRunnersOnly` (off by default; `PUT /api/agents/variables/...` with `teamRunnersOnly`, and without `value` to change only that) keeps runs and jobs that get it on
|
|
34
|
+
- **Variables** (`agSecrets`): environment variables for the agent's process, every one a secret sealed with the application's secrets service (`secrets.keys`) and bound to its scope and name, set on an agent, a working directory (`workdir`) or a scope the application registers, merged for a run in the order the subject names its scopes < its working directories < the agent, delivered only to runners with the `secrets` feature: to whichever runner takes the run, a personal runner of anyone who may use the agent included, since sharing an agent shares the tokens it works with. A variable marked `teamRunnersOnly` (off by default; `PUT /api/agents/variables/...` with `teamRunnersOnly`, and without `value` to change only that) keeps runs and jobs that get it on shared runners. Jobs check the exact variables referenced by their prepared spec, including repository credentials, before opening any value in the claim transaction; a personal runner skips such a job without counting a preparation failure, leaving it queued for a shared runner and continuing to other jobs. Values are write-only; reading them back and every delivery are audited (`agSecretAudits`).
|
|
35
35
|
- **Skills** (`agSkills`, `agSkillVersions`, `agSkillAttachments`): a library of skills in the open Agent Skills format (https://agentskills.io/specification): a directory of `SKILL.md` and supporting files, conventionally under `scripts/`, `references/` and `assets/`. Only the front matter of `SKILL.md` names and describes a skill: `name` (1–64 lower-case letters, digits and single hyphens) is its slug and directory, so a save that changes it renames the skill, and `description` (1–1024 characters) is required; `license`, `compatibility` (at most 500 characters), `metadata` (string values) and `allowed-tools` are checked when present, and other keys are kept. Every create, save, restore and import is checked against these rules in the browser as it is typed and on the server (`shared/skill-markdown.ts`), which answers 400 with each problem's `field` and `reason` in `metadata.problems` (`taken` for a name another skill has; `mismatch` for an archive whose folder is named otherwise). Files under `scripts/` or marked executable are scripts (`Skill.scripts`): runners may run them. Every save is a new version that runs get at once, with older versions to compare and restore. Skills are attached globally, or as defaults to a working directory or a registered scope. A skill's revision is its current version: a save or a restore names the version it was made against (`expectedRevision`) and is refused with 409 `REVISION_CONFLICT` when another save came first. A runner fetches a run's skills from `GET /api/agents/runners/runs/:runId/skills/:slug` and places them where the run's coding tool finds them.
|
|
36
36
|
- **Conversations** (`agConversations`, `agConversationMessages`): owner-only chats through the OnlineAgent service, with native model execution or a callable Runner binding. Existing bindings are immutable. Historical unbound conversations retain readable history and owner-authorized Stop for unfinished runs, but cannot continue chatting through HTTP. Ordinary conversations default to visible; new background sessions are hidden from lists before pagination. The [OnlineAgent reference](skills/nocobase-app-plugin-agents/references/online-agent.md) documents execution, result observation, browser configuration, notification transactions and migration from removed start/fallback/restore endpoints and CLI commands.
|
|
37
37
|
- **Chat defaults**: the system default chat agent (`agSettings`, `PATCH /api/agents/chatSettings` by who manages `agents.agents`, or the application), each person's default chat agent (`agChatPreferences`), and each agent's "confirm before changing data" (`confirmChanges`: `always` or only `larger` changes).
|
|
@@ -41,6 +41,62 @@ Repository access providers that mint credentials in `prepare` implement the ide
|
|
|
41
41
|
|
|
42
42
|
Runner affinity uses the same ordered-model admission decision as actual claims, without loading the full waiting diagnostic. Queue traversal evaluates only candidates it reaches before a successful claim. Capacity comes from the existing batch, while resource metadata is cached by scope within the poll and loaded in batches across relevant machines; known agent scopes share the first metadata read. Preferred-model admission needs a compatible or unknown first choice, even when busy, so it does not read per-machine slot counts. The broader machine inventory is read at most once for this affinity pass. Full diagnostics remain available through the waiting projection. Application context assembly and policy providers may issue their own reads; visiting new subject scopes adds metadata batches, and returned-row budgets do not bound the database's internal scans.
|
|
43
43
|
|
|
44
|
+
## Native document inputs
|
|
45
|
+
|
|
46
|
+
Native chats prepare attachments after the original user message commits. Supported local documents are extracted through `@nocobase/document-extractor` into user-level model replay copies only; the original user message, search index and public history retain file references. Knowledge is not an Agents dependency, and File remains responsible for authorized byte access.
|
|
47
|
+
|
|
48
|
+
When neither the configured system prompt nor generated execution instructions contain non-whitespace text, Native execution omits the SDK system option rather than sending an empty system message. Nonempty instructions retain their original content, and attachments remain user-level data. This avoids Moonshot/Kimi HTTP 400 errors without adding a placeholder system prompt or changing file routing.
|
|
49
|
+
|
|
50
|
+
**Upgrade note:** Native file routing follows legacy Provider defaults unless an exact profile overrides them. OpenAI, Anthropic, Google and OpenAI-compatible services forward PDF originals and images; Alibaba forwards images and extracts document text locally; Moonshot forwards images and uploads supported documents to its selected service's Kimi Files API by default. Ollama forwards images and extracts PDF and other supported document text locally, without attempting PDF-original delivery first. An explicit profile requesting PDF-original forwarding is described to the model as unavailable instead of letting the current SDK silently drop the file. DeepSeek and Cohere retain local document extraction. DeepSeek image capability is declared centrally in `server/online/search/capabilities.ts`: only the official endpoint's exact `deepseek-flash` model forwards JPEG, PNG, GIF and WebP, regardless of the service name; other DeepSeek models/endpoints and Cohere receive no default image grant. Existing exact file-input profiles still take precedence, including explicit opt-outs. `profiles: []` removes overrides, not code-owned capabilities. These are forwarding policies, not evidence that every model accepts every MIME type. No failure automatically changes the model, service or extraction route.
|
|
51
|
+
|
|
52
|
+
```yaml
|
|
53
|
+
agents:
|
|
54
|
+
fileInputs:
|
|
55
|
+
profiles:
|
|
56
|
+
- modelService: company-chat
|
|
57
|
+
model: verified-vision-model
|
|
58
|
+
provider: openai-compatible
|
|
59
|
+
protocol: chat-completions
|
|
60
|
+
baseUrl: https://gateway.example.invalid/v1
|
|
61
|
+
nativeMediaTypes: [image/png, image/jpeg]
|
|
62
|
+
maxNativeFiles: 10 # Example verified Provider limit; omit for the global ceiling.
|
|
63
|
+
extraction: local
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
Protocols follow the existing SDK construction path: OpenAI `responses`, Anthropic `messages`, Google `generate-content`, DeepSeek/Alibaba/Moonshot/OpenAI-compatible `chat-completions`, Ollama `ollama-chat`, and Cohere `cohere-chat`. A profile does not switch the Provider protocol. Exact overrides must match the complete service/model/Provider/protocol/effective base URL identity; a stale profile fails instead of falling back to defaults. Native MIME values must be exact, except for the restricted `image/*` wildcard. An explicit `nativeMediaTypes: []` and `extraction: local` override disables native forwarding and remote extraction for that model. An empty `profiles` array removes overrides, not Provider defaults. OCR and arbitrary URL downloading are not provided. Provider references use an allowed native route or become an unavailable-attachment description in model replay; their original private representation remains unchanged.
|
|
67
|
+
|
|
68
|
+
Unsupported user attachment formats, unconfigured native images, unsupported file references and an extractor's explicit `unsupported` result do not fail the conversation. Model replay replaces only the affected user file part with an untrusted-metadata description containing its filename, MIME type and controlled limitation, stating that no contents were parsed and asking the model to explain honestly and continue with readable inputs. Historical files use the same rule on follow-up, including after an earlier failed turn. Descriptions count toward the existing context budget, are not cached as extracted text, and are not persisted into original user messages, search indexes or public history. Authorized stored bytes are still reread and bounded on every turn; permission failures, invalid inline data, mismatched formats, budgets, cancellation, timeouts and actual parser or Provider failures retain their existing behavior.
|
|
69
|
+
|
|
70
|
+
Local DOCX preparation explicitly omits embedded image data before applying the text budget. The model receives extracted text, not base64 image payloads; its document wrapper warns that images and visual layout may be omitted. Image-only DOCX files fail as unreadable instead of being reported as read. This performs no OCR and leaves Knowledge's default Markdown output unchanged.
|
|
71
|
+
Local extraction caches only completed successful text in this NativeFileInputs instance: 30-minute non-sliding TTL, 128-entry LRU and 32 MiB of UTF-8 text. Every use still authorizes and reads the current bounded bytes, checking their digest before a cache hit; no in-flight work is shared between executions. Limits include historical files and cache hits: 20 MiB per actual file, 64 MiB of distinct source bytes, 100,000 Unicode characters per extracted document and 200,000 characters of wrapped document context. An execution admits at most 100 file inputs, including native references; a profile can lower the native count with `maxNativeFiles` (0–100). These ceilings do not infer any Provider's actual capabilities or token context limits. A private file-only background input retains its original file parts and projects to empty public text, without indexing or exposing its bytes.
|
|
72
|
+
|
|
73
|
+
Missing permission, unreadable nonempty documents and budget failures end the accepted execution without sending another user message or dropping attachments. Stop forwards the execution signal and waits for file-stream cancellation, Worker termination or bounded remote cleanup. Direct `OnlineAgentService` composition can omit file inputs for text-only use; file-enabled hosts must supply the grouped file-input capability and its model binding.
|
|
74
|
+
|
|
75
|
+
Controlled file preparation failures persist an allowlisted `fileInputReason` in the existing execution-status notice's `params`, with a fixed English fallback title. Chat renders the reason in the viewer's language in both live responses and history; raw parser/Provider messages, file contents and credentials never become public failure text. An unknown preparation exception uses generic safe guidance, Stop remains cancellation, and old `Interrupted` notices without a saved reason get a generic explanation rather than a reason inferred from today's model configuration.
|
|
76
|
+
|
|
77
|
+
### Kimi extraction and exact overrides
|
|
78
|
+
|
|
79
|
+
Selecting the Moonshot Provider enables Kimi Files document uploads by default, using the selected service's saved API key (not an environment-key fallback) and execution-bound endpoint. Native images and text-only turns do not initialize or call the Files API adapter. No model-name heuristic enables remote extraction on another Provider, and the adapter never selects a second service. OpenAI-compatible services still require an exact `extraction: kimi-file-extract` profile to grant uploads. For Moonshot, an exact `extraction: local` profile opts out; configure `nativeMediaTypes: ['image/*']` to keep images native while parsing documents locally. The profile below illustrates an exact remote override, not real Provider acceptance evidence:
|
|
80
|
+
|
|
81
|
+
```yaml
|
|
82
|
+
agents:
|
|
83
|
+
fileInputs:
|
|
84
|
+
profiles:
|
|
85
|
+
- modelService: company-kimi
|
|
86
|
+
model: kimi-k2.5
|
|
87
|
+
provider: moonshotai
|
|
88
|
+
protocol: chat-completions
|
|
89
|
+
baseUrl: https://api.moonshot.ai/v1
|
|
90
|
+
nativeMediaTypes: []
|
|
91
|
+
extraction: kimi-file-extract
|
|
92
|
+
```
|
|
93
|
+
|
|
94
|
+
An explicitly supported native file still goes directly to the model without an extra upload. Otherwise the authorized bytes go to `POST <base>/files` with multipart `purpose=file-extract`, followed by `GET <base>/files/:id/content`. Proxy prefixes and API roots are preserved; requests do not follow redirects. Only `text/plain` and JSON with a string `content` field are accepted. Upload metadata is limited to 64 KiB; content response bytes are bounded by the character budget (4 bytes per character for text or 12 for JSON escapes, plus 64 KiB of envelope allowance), then the decoded text is checked without truncation. File IDs must be bounded alphanumeric/underscore/hyphen tokens; unknown response contracts fail safely rather than being guessed.
|
|
95
|
+
|
|
96
|
+
Upload and content share one five-minute deadline and the execution signal. Once an ID is known, success, failure and cancellation all attempt DELETE with the same pinned connection and a separate cleanup signal lasting at most five seconds. Stop and shutdown await that cleanup. Deletion failure produces a sanitized diagnostic without replacing successful extraction; cleanup is best-effort, not proof of removal. A lost upload response without a usable ID cannot be reliably cleaned and emits an uncertainty diagnostic.
|
|
97
|
+
|
|
98
|
+
Remote text is reused only within the current execution, never in the cross-execution local cache. History and approval continuations reauthorize and re-extract from originals; finalization retries do not re-upload. Credentials, remote IDs and raw upstream failure bodies are not written into user messages or public history. Real Provider testing and external file upload require separate authorization; loopback fixtures do not verify a live gateway's capabilities.
|
|
99
|
+
|
|
44
100
|
## Chat integration documentation
|
|
45
101
|
|
|
46
102
|
- [OnlineAgent service and business tools](skills/nocobase-app-plugin-agents/references/online-agent.md): trusted server configuration, Native/Runner sessions, public browser transport and lifecycle boundaries.
|
|
@@ -104,7 +160,7 @@ Every route lives under the plugin's namespace, `/api/agents`, and names its own
|
|
|
104
160
|
| `/api/agents/cli/*` | Run token header, or the application's authentication | The CLI's custom commands (`CLI_ROUTES.command`); the manifest is the application's `GET /api/cli/manifest` |
|
|
105
161
|
| everything else under `/api/agents` | Session and authorization context | Agents and brief previews, variables, skills, runs, the vocabulary, usage, prices, conversations, the model services and their models |
|
|
106
162
|
|
|
107
|
-
Scoped API keys reach only the routes whose every operation is a settings check (skills, model services, prices and usage); elsewhere they are refused with `SCOPED_KEY_FORBIDDEN`. The API checks four settings items, which the plugin lists under an Agent
|
|
163
|
+
Scoped API keys reach only the routes whose every operation is a settings check (skills, model services, prices and usage); elsewhere they are refused with `SCOPED_KEY_FORBIDDEN`. The API checks four settings items, which the plugin lists under an Agent management subsection of the permission workspace: `agents.agents` (manage changes agents and their variables; read sees agents' variables, skills and every run, and every runner; anyone signed in reads the agents themselves, `GET /api/agents`, with `canEdit` for a manager), `agents.runners` (read every runner; manage revokes and deletes any runner, changes a runner whose owner can no longer act and adds shared runners; anyone signed in adds personal runners and changes, revokes and deletes their own, and only the owner changes a runner), `agents.prices` (the model prices) and `agents.services` (the model services the application calls: read lists them, manage adds, edits, tests and deletes them and sets their keys; a scoped key may only read them). It also declares one business action with three levels (`BUSINESS_ACTIONS` and `RELATIONS` in `shared/access.ts`), registered as the `agents` resource type under an Agent management subsection of business, one action per level (`edit.related`, `edit.all`), whose level the application tells it through `agentsAccessToken` (`scopeOf(identity, key)`; unbound, every level is `none`): `agents.agents/edit` edits skills (saving, restoring a version), every one at `all` and at `related` the skills the caller created; agents are changed only by who manages them. Managing agents reaches every skill whatever the level; creating and deleting skills still need it. A skill answers `canEdit` for the caller. Anyone signed in reads which model services and models are offered (`GET /api/agents/models`, names only, chat models unless `?kind=embedding` or `rerank` asks for another kind; `shared/models.ts`), and anyone who reads agents may test one (`POST /api/agents/checkModel`). Anyone signed in sees, cancels and retries the runs they started or own, and reads the vocabulary (labels only). A working directory's or a registered scope's variables and default skills follow the scope's kind: it decides who reads and who changes them.
|
|
108
164
|
|
|
109
165
|
Realtime announcements carry no content: `agents:runs:<runId>` when a run's status, transcript or input changes and `agents:runners` when a runner changes. A page that hears one fetches through the API.
|
|
110
166
|
|
|
@@ -173,7 +229,7 @@ Work somebody causes on a subject another person answers for runs only with that
|
|
|
173
229
|
|
|
174
230
|
- The source is the responsible, or nobody answers for the subject: the work is queued as before, run as the responsible (or as `actorUserId`).
|
|
175
231
|
- The source is someone else and `execution` is `auto` (the default): nothing is queued. A run request (`agRunRequests`) keeps the input as it was asked and waits for the responsible; `enqueue` answers `outcome: 'pending'` with its `requestId`.
|
|
176
|
-
- `execution: 'mine'`: the work is queued at once as the source, on a runner they may use (their own or a
|
|
232
|
+
- `execution: 'mine'`: the work is queued at once as the source, on a runner they may use (their own or a shared runner, never the responsible's own). With none online it is refused with `NO_RUNNER_AVAILABLE` instead of waiting unseen.
|
|
177
233
|
- `causedByRunId`: the source is that run's, who confirmed it or else who it was requested by, so a chain somebody else started never runs as the responsible unconfirmed. Runs record it as `requestedByUserId`, and the confirmer as `confirmedByUserId`.
|
|
178
234
|
|
|
179
235
|
Only the request's responsible confirms it (queued as them with the input as it was asked, its actor the asker, joining only a run acting as them while it takes input) or rejects it; not an administrator, a manager of agents or a run acting for them. Confirming checks again that they may still wake the agent. A subject with mutable responsibility should bind `SubjectBinding.responsibleUserId(conn, subjectId)`, which reads the current responsible inside the confirmation or rejection transaction; a changed or null responsible prevents the old responsible from acting even before `reassign` is called. Without that resolver the request uses its recorded responsible, so the application must call `reassign` with the subject's responsibility change. The asker withdraws it, or runs it as themselves. People do this over `GET /api/agents/runRequests` (`role=responsible&status=pending` is an inbox), `GET /api/agents/runRequests/{requestId}`, and `POST …/{requestId}/confirm`, `reject`, `withdraw` and `runAsMe`, by session or unscoped API key only. Concurrent settlement returns 409.
|
|
@@ -241,11 +297,11 @@ Model services are not configured here: they are added on the application's page
|
|
|
241
297
|
|
|
242
298
|
## Web UI
|
|
243
299
|
|
|
244
|
-
The plugin registers no routes of its own: an application mounts its pages and joins them to the pages of the runner agents do. The assembling application puts them under "Agent
|
|
300
|
+
The plugin registers no routes of its own: an application mounts its pages and joins them to the pages of the runner agents do. The assembling application puts them under "Agent management" in its sidebar.
|
|
245
301
|
|
|
246
302
|
- `@nocobase/app-plugin-agents/client/routes` exports `agentsRoute` (`/agents`), `runtimesRoute` (`/runtimes`, with the `connect` dialog), `skillsRoute` (`/skills`, with `new` and `:skillId`) and `usageRoute` (`/usage`: what runs used and cost over a date range, filtered by group, agent and person and summed by one of the groupings (`?groupBy=`, agent by default), with a daily chart of tokens or cost above the table, stacked by the top five agents or models when grouped by those (the usage route's `series`), its group and subject named and linked by the vocabulary's `groupTitle`, `path` and `groupPath`; for who reads `agents.prices` a "Set prices" header button opens the prices sheet, `?prices=1`: models by service and model, coding tools by the models their runs report, each tool with its subscription switch and price rules, changed by who manages it; the note on missing prices links to it). Each page renders its own heading, and stands behind a page grant of the same id as its route name (`agents`, `runtimes`, `skills`, `usage`, exported as `PAGES` from `shared/access`); a page grant only opens the page, and what it shows is decided by the admin API on the settings items. It also exports `modelsRoute` (`/models`), which stands behind `agents.services` read instead: the model services (a page header with "Add service", then a table with one row per service: its name and host, provider type, status and a menu to edit it, turn it on or off or delete it; "Add service" and clicking a row open one dialog with a single form saved at once: provider type when adding, name, base URL, the write-only key as a `SecretInput` (`client/components/secret-input.tsx`: a password field whose empty value keeps the saved key), an OpenCode base URL's note on which provider type serves which of its model families (its session header is sent automatically), connection test, models fetched from the provider or added by id and checked, each with its kind, changeable before and after it is checked, and a Test that checks it as that kind, and an on/off switch), changeable by who manages `agents.services`.
|
|
247
|
-
- Runtimes (on `/api/agents/runners`): one overview row per runtime — its name with its system, its state with the slots in use ("Busy 1/1", "Offline · 3 hours ago"), its coding tools by sign-in, personal or
|
|
248
|
-
- Agents (`client/pages/agents`, on `GET /api/agents`): one row per agent discovered from runners, filtered by All, Enabled, To enable and No runner: its name with its tool and model, what it is good at, where it can run now (the
|
|
303
|
+
- Runtimes (on `/api/agents/runners`): one overview row per runtime — its name with its system, its state with the slots in use ("Busy 1/1", "Offline · 3 hours ago"), its coding tools by sign-in, personal or shared, its runner version (marked "Upgradable" when a newer version of the product it runs as is served, with `nocobase-runner update`, or `<cli> runner update` for a CLI that carries the runner; the runner also updates itself) and when it was last seen — with a "…" menu (Edit, then revoke or delete). A row opens the runtime's sheet: General (name, concurrent runs, personal or shared after a warning, and "Allow build jobs" only when the application gives runners jobs, as an application's off-by-default runner build method does), Tools (a switch per supported tool with its detection state, version, sign-in and, when the API sent it, its path as small text), Local policy (read only: what its owner's policy on the machine lets it take) and Recent runs (`GET /agents/runners/:runnerId/runs`). Only its owner changes it (the managers of runners only a runner whose owner can no longer act); a manager of runners sees someone else's read only, with revoke or delete as the only menu items. Its owner, the managers of runners and anyone who may use an agent get its host name and its tools' paths from the API, everyone else neither. "Add runtime" asks for its usage scope (shared only for managers of runners), which coding tools it detects and may run (Codex and Claude Code by default) and its max concurrent runs (3 by default, carried by the online registration token), then offers Prompt and Manual installation for macOS, Linux and Windows through WSL Ubuntu, using the same one-time registration command (copy buttons, expiry), and waits until the runtime connects, then shows the coding tools it reported.
|
|
304
|
+
- Agents (`client/pages/agents`, on `GET /api/agents`): one row per agent discovered from runners, filtered by All, Enabled, To enable and No runner: its name with its tool and model, what it is good at, where it can run now (the shared and personal runners online with it, the caller's own counted, with a few of their names; "personal runners only", or when a runner last reported it), its default reasoning effort and its state. For who manages `agents.agents`, a pending agent offers "Fill in and enable" and the others "Edit": one dialog (`agent-dialog.tsx`) with what it is good at (started from the catalog's suggestion in the viewer's language), the effort among those its tool takes, and, when editing, whether it is enabled, saved against the revision it shows. Everyone else reads. Under the table, how to add an agent: connect a runner whose tool has the model. An application that keeps agents of its own composes `RunnerAgentsSection` (from `client/kit`) into its own page instead.
|
|
249
305
|
- Skills: the library (each skill's name, description, compatibility and whether it holds scripts), and a skill as a directory: its files in a tree beside the selected one (`client/pages/skills/workbench/`), SKILL.md rendered, other text shown, images and PDFs previewed. Editing uses the same workbench: files and folders are created (in a folder chosen from the skill's and the conventional `scripts/`, `references/`, `assets/`), uploaded (also by dropping files onto a folder), renamed and deleted from the tree, never by typing a path; SKILL.md and other Markdown are written beside their preview (in tabs on a narrow pane), with the front matter's problems listed above the source as it is typed. A new skill (`/skills/new`, a covering page) starts from a template of front matter and suggested sections. Versions can be compared with the current one and restored, and the page shows where the skill is attached. When someone saved a version while the editor was open, the draft stays and a banner offers to load the latest version. A scope's default skills list the scripts of the chosen skills, which online agents do not run (`SkillScriptsNotice`).
|
|
250
306
|
- The new skill and variable dialogs ask "Discard unsaved changes?" before closing with input in them (NP-200), through `@nocobase/app-client`'s unsaved-changes guard.
|
|
251
307
|
- `@nocobase/app-plugin-agents/client/kit` exports `RunnerAgentsSection` (the Agent page's list, for an application's own page), `VariablesSection` and `DefaultSkillsSection` for a scope's settings on the application's pages (`scope` `workdir` or a registered key, with an optional `description`), `useRunnerOptions` for picking the runner a directory is on (with how many runners are `online`), and `useAgentOptions` for picking an agent.
|
|
@@ -303,14 +359,18 @@ The supported tool identities are the native adapter registry plus the shared AC
|
|
|
303
359
|
|
|
304
360
|
`enabledTools` is an explicit server selection. New tokens default to Codex and Claude Code; the install command carries only the registration token. Registration sends no tool inspection, receives the selection, and caches it for the connection. The daemon fetches the latest selection before inspecting after a restart, then detects only selected tools. Existing null selections are migrated to the original four native tools; existing explicit lists, including empty lists, stay intact. API null input is normalized to those four tools, never to future catalog additions. No local tool-selection command or runner-authenticated settings route is provided.
|
|
305
361
|
|
|
306
|
-
An owner changes their own tools. A manager of `agents.runners` may change a
|
|
362
|
+
An owner changes their own tools. A manager of `agents.runners` may change a shared runtime's tools or request detection, without gaining access to its other settings. Personal tools remain owner-only. Disabled tools stop receiving work immediately; an active run finishes normally. Newly selected tools wait for a fresh report. The runtime page distinguishes waiting, not installed, login required, ready and detection failed, and offers Detect again for an online runtime. Quota data an ACP agent does not supply is shown as Not provided.
|
|
307
363
|
|
|
308
364
|
Protocol 13 adds catalog identities and selection delivery. Upgrade the server before the runner. Older runners remain usable for native tools and retain their previous detection behavior until upgraded; the server filters their reports by the explicit selection. A protocol-13 runner stays connected without claiming work on an older server's compatibility refusal. ACP agents without model listing generate a single agent named after the tool with a null model; execution omits the model. Explicit unavailable models fail instead of falling back. ACP model identifiers retain their spelling and release suffixes.
|
|
309
365
|
|
|
310
366
|
Heartbeats never start a tool process. Background checks observe program paths, resolved targets, sizes and modification times every five minutes, and re-probe only changed programs. Startup, selection/environment changes, explicit detection and a real authentication failure also trigger inspection. No periodic ACP handshake is scheduled. At most two tools are inspected concurrently, with a thirty-second deadline and bounded process cleanup; detection sends no prompt and cancels permission requests. Manual/authentication refresh signals are best effort in process memory; a restart always fetches settings and inspects again. Session resume/load, prompt-boundary input, cancellation and the runner's prepared environment, git credential broker, CLI wrappers and hooks use the existing worker lifecycle.
|
|
311
367
|
|
|
368
|
+
### Runtime usage scope and installation
|
|
369
|
+
|
|
370
|
+
Personal runtimes execute only their owner’s tasks; shared runtimes execute any user’s tasks and receive their variables and secrets. Run either scope in a VM or isolated environment: agents have full access and the runner is not a sandbox. The wire values stay `ownerOnly` (personal) and `team` (shared). Installation prompts cover Node.js 24, coding-tool sign-in, service PATH, proxies, npm global permissions and avoiding snap tools. For Windows, the prompt first asks the agent to verify it is running inside WSL Ubuntu. Otherwise it must stop and ask the user to run `wsl --install` in PowerShell, restart Windows, then open the agent inside WSL Ubuntu and run the prompt again. Only then may it continue, with Node.js and coding tools installed inside WSL; enable mirrored networking if WSL cannot reach the internet. Finish with `nocobase-runner status`. If no coding tools are found, use a terminal where `which codex` / `which claude` works to rerun `nocobase-runner service install` and restart the service, or rerun `nocobase-runner start`, so the runner gets the correct PATH.
|
|
371
|
+
|
|
312
372
|
### Effective runner slots
|
|
313
373
|
|
|
314
374
|
Capacity belongs to each application independently. Heartbeat replies include the complete capacity configuration; updated runners apply it without restarting and send one confirmation heartbeat when it changes. Their load report identifies the source and actual total and tool limits. The existing load JSON stores these values, and capacity changes emit runner.changed through the existing refresh mechanism; no schema migration is needed. Normal heartbeats and claims add no database operations, locks or transactions. A configuration change adds one confirmation heartbeat, with the same database cost as a normal heartbeat.
|
|
315
375
|
|
|
316
|
-
The runtime status cell displays reported capacity, a pending-sync notice when online settings differ, and unknown synchronization support for older runners. Offline runtimes display the last report time. Editing continues to change online configuration. New registrations default to
|
|
376
|
+
The runtime status cell displays reported capacity, a pending-sync notice when online settings differ, and unknown synchronization support for older runners. Offline runtimes display the last report time. Editing continues to change online configuration. New registrations default to three slots; legacy clients cannot override a token's online settings through registration. Applications with custom runner projections must forward reportedSlots, capacitySource, capacityReportedAt and toolLoad; installed UI component copies need an explicit merge. Update the application server before relying on dynamic slots; upgraded runners connected to an older server temporarily retain their legacy local allowance.
|
package/dist/cli/runner-token.js
CHANGED
|
@@ -7,7 +7,7 @@ export default class RunnerToken extends AppCommand {
|
|
|
7
7
|
trust: Flags.string({
|
|
8
8
|
default: 'ownerOnly',
|
|
9
9
|
options: ['team', 'ownerOnly'],
|
|
10
|
-
description: 'team runs
|
|
10
|
+
description: 'Usage scope: team is shared (runs any user’s tasks with their variables and secrets); ownerOnly is personal (only its owner’s tasks).',
|
|
11
11
|
}),
|
|
12
12
|
owner: Flags.string({
|
|
13
13
|
description: 'The user id that owns the runner (required for ownerOnly).',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"runner-token.js","sourceRoot":"","sources":["../../cli/runner-token.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAkB,MAAM,0BAA0B,CAAC;AACvE,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAC/C,OAAO,EAAE,KAAK,EAAE,MAAM,aAAa,CAAC;AAYpC,MAAM,CAAC,OAAO,OAAO,WAAY,SAAQ,UAAU;IACjD,MAAM,CAAU,OAAO,GACrB,yEAAyE,CAAC;IAC5E,MAAM,CAAU,KAAK,GAIjB;QACF,KAAK,EAAE,KAAK,CAAC,MAAM,CAAC;YAClB,OAAO,EAAE,WAAW;YACpB,OAAO,EAAE,CAAC,MAAM,EAAE,WAAW,CAAC;YAC9B,WAAW,EACT,
|
|
1
|
+
{"version":3,"file":"runner-token.js","sourceRoot":"","sources":["../../cli/runner-token.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAkB,MAAM,0BAA0B,CAAC;AACvE,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAC/C,OAAO,EAAE,KAAK,EAAE,MAAM,aAAa,CAAC;AAYpC,MAAM,CAAC,OAAO,OAAO,WAAY,SAAQ,UAAU;IACjD,MAAM,CAAU,OAAO,GACrB,yEAAyE,CAAC;IAC5E,MAAM,CAAU,KAAK,GAIjB;QACF,KAAK,EAAE,KAAK,CAAC,MAAM,CAAC;YAClB,OAAO,EAAE,WAAW;YACpB,OAAO,EAAE,CAAC,MAAM,EAAE,WAAW,CAAC;YAC9B,WAAW,EACT,uIAAuI;SAC1I,CAAC;QACF,KAAK,EAAE,KAAK,CAAC,MAAM,CAAC;YAClB,WAAW,EAAE,4DAA4D;SAC1E,CAAC;QACF,KAAK,EAAE,KAAK,CAAC,MAAM,CAAC;YAClB,WAAW,EAAE,yDAAyD,WAAW,CAAC,IAAI,CAA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AAI,EAAE;gBACpD,KAAK,EAAE,KAAK,CAAC,KAA6B;gBAC1C,GAAG,CAAC,KAAK,CAAC,CAAC,CAAC,EAAE,YAAY,EAAE,KAAoB,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;aACzD,CAAC,CAAC;QACP,CAAC,CAAC,CAAC;QACH,IAAI,CAAC,GAAG,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;QACxB,OAAO;YACL,KAAK,EAAE,OAAO,CAAC,KAAK;YACpB,KAAK,EAAE,OAAO,CAAC,KAAK;YACpB,YAAY,EAAE,OAAO,CAAC,YAAY;YAClC,SAAS,EAAE,OAAO,CAAC,SAAS;SAC7B,CAAC;IACJ,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"client-id.d.ts","sourceRoot":"","sources":["../../../client/chat/client-id.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"client-id.d.ts","sourceRoot":"","sources":["../../../client/chat/client-id.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,IAAI,cAAc,EAAE,MAAM,sBAAsB,CAAC"}
|
|
@@ -1,17 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
export function createClientId() {
|
|
3
|
-
const bytes = crypto.getRandomValues(new Uint8Array(16));
|
|
4
|
-
bytes[6] = (bytes[6] & 0x0f) | 0x40;
|
|
5
|
-
bytes[8] = (bytes[8] & 0x3f) | 0x80;
|
|
6
|
-
const hex = [...bytes]
|
|
7
|
-
.map((byte) => byte.toString(16).padStart(2, '0'))
|
|
8
|
-
.join('');
|
|
9
|
-
return [
|
|
10
|
-
hex.slice(0, 8),
|
|
11
|
-
hex.slice(8, 12),
|
|
12
|
-
hex.slice(12, 16),
|
|
13
|
-
hex.slice(16, 20),
|
|
14
|
-
hex.slice(20),
|
|
15
|
-
].join('-');
|
|
16
|
-
}
|
|
1
|
+
export { createUuid as createClientId } from '@nocobase/app-client';
|
|
17
2
|
//# sourceMappingURL=client-id.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"client-id.js","sourceRoot":"","sources":["../../../client/chat/client-id.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"client-id.js","sourceRoot":"","sources":["../../../client/chat/client-id.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,IAAI,cAAc,EAAE,MAAM,sBAAsB,CAAC"}
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
/** UIMessage reconciliation at the durable-history boundary. SDK Chat owns the active messages. */
|
|
2
1
|
import type { ConsultationIdentity } from './consultation-identity.js';
|
|
3
2
|
import type { RunEvent } from '@nocobase/agent-protocol';
|
|
4
3
|
import type { ChatAgent, ConversationNotice, MessageAttachment, PageContext } from '../../shared/conversations.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"message-model.d.ts","sourceRoot":"","sources":["../../../client/chat/message-model.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"message-model.d.ts","sourceRoot":"","sources":["../../../client/chat/message-model.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,4BAA4B,CAAC;AACvE,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,0BAA0B,CAAC;AACzD,OAAO,KAAK,EACV,SAAS,EACT,kBAAkB,EAClB,iBAAiB,EACjB,WAAW,EACZ,MAAM,+BAA+B,CAAC;AACvC,OAAO,KAAK,EAAE,SAAS,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAC;AAG5E,gGAAgG;AAChG,MAAM,WAAW,cAAc;IAC7B,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;IAC1B,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,OAAO,EAAE,WAAW,GAAG,SAAS,CAAC;IAC1C,QAAQ,CAAC,WAAW,CAAC,EAAE,SAAS,iBAAiB,EAAE,CAAC;IACpD,QAAQ,CAAC,SA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wBAAgB,UAAU,CACxB,CAAC,EAAE,SAAS,EACZ,MAAM,EAAE,kBAAkB,GAAG,SAAS,EACtC,QAAQ,EAAE,MAAM,EAChB,SAAS,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,MAAM,EACtC,QAAQ,CAAC,EAAE,CAAC,MAAM,EAAE,UAAU,EAAE,CAAC,EAAE,SAAS,KAAK,MAAM,GAAG,IAAI,EAC9D,oBAAoB,CAAC,EAAE,oBAAoB,GAC1C,MAAM,CA+DR"}
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
/** UIMessage reconciliation at the durable-history boundary. SDK Chat owns the active messages. */
|
|
2
|
+
import { isFileInputFailureReason } from '../../shared/file-input-failures.js';
|
|
1
3
|
import { toolSummary } from '../lib/tool-summary.js';
|
|
2
4
|
export const EMPTY_MESSAGES = {
|
|
3
5
|
items: [],
|
|
@@ -287,8 +289,17 @@ export function noticeText(t, notice, fallback, agentName, newsText, consultatio
|
|
|
287
289
|
// The historical code names a cancellation request, not a terminal outcome.
|
|
288
290
|
case 'runCancelled':
|
|
289
291
|
return t('chat.notice.runCancelled');
|
|
290
|
-
case 'news':
|
|
291
|
-
|
|
292
|
+
case 'news': {
|
|
293
|
+
const custom = newsText?.(notice, t);
|
|
294
|
+
if (custom !== undefined && custom !== null)
|
|
295
|
+
return custom;
|
|
296
|
+
const reason = notice.params?.fileInputReason;
|
|
297
|
+
if (notice.type === 'failed' && reason !== undefined)
|
|
298
|
+
return t(`chat.fileInputFailures.${isFileInputFailureReason(reason) ? reason : 'preparationFailed'}`);
|
|
299
|
+
if (notice.type === 'failed' && notice.title === 'Interrupted')
|
|
300
|
+
return t('chat.executionFailed');
|
|
301
|
+
return notice.title;
|
|
302
|
+
}
|
|
292
303
|
case 'consultation':
|
|
293
304
|
if (consultationIdentity?.state === 'unavailable')
|
|
294
305
|
return t('chat.consultation.unavailableTitle');
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"message-model.js","sourceRoot":"","s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C;QACtB,CAAC;QACD,KAAK,cAAc;YACjB,IAAI,oBAAoB,EAAE,KAAK,KAAK,aAAa;gBAC/C,OAAO,CAAC,CAAC,oCAAoC,CAAC,CAAC;YACjD,OAAO,CAAC,CACN,oBAAoB,EAAE,KAAK,KAAK,UAAU;gBACxC,CAAC,CAAC,oBAAoB;oBACpB,CAAC,MAAM,CAAC,gBAAgB,IAAI,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC;gBAC/C,CAAC,CAAC,iCAAiC;gBACnC,CAAC,CAAC,yBAAyB,EAC7B;gBACE,IAAI,EAAE,oBAAoB;oBACxB,CAAC,CAAC,oBAAoB,CAAC,KAAK,KAAK,SAAS;wBACxC,CAAC,CAAC,GAAG;wBACL,CAAC,CAAC,oBAAoB,CAAC,IAAI;oBAC7B,CAAC,CAAC,MAAM,CAAC,OAAO,IAAI,CAAC,MAAM,CAAC,gBAAgB;wBAC1C,CAAC,CAAC,SAAS,CAAC,MAAM,CAAC,OAAO,CAAC;wBAC3B,CAAC,CAAC,MAAM,CAAC,SAAS;aACvB,CACF,CAAC;QACJ;YACE,OAAO,QAAQ,CAAC;IACpB,CAAC;AACH,CAAC"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { type ReactElement } from 'react';
|
|
2
2
|
/** A shell command with a copy button (the add-runner dialog, the upgrade popover). */
|
|
3
|
-
export declare function CommandLine({ command, }: {
|
|
3
|
+
export declare function CommandLine({ command, expanded, }: {
|
|
4
4
|
readonly command: string;
|
|
5
|
+
readonly expanded?: boolean;
|
|
5
6
|
}): ReactElement;
|
|
6
7
|
//# sourceMappingURL=command-line.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"command-line.d.ts","sourceRoot":"","sources":["../../../client/components/command-line.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"command-line.d.ts","sourceRoot":"","sources":["../../../client/components/command-line.tsx"],"names":[],"mappings":"AAGA,OAAO,EAAY,KAAK,YAAY,EAAE,MAAM,OAAO,CAAC;AAKpD,uFAAuF;AACvF,wBAAgB,WAAW,CAAC,EAC1B,OAAO,EACP,QAAgB,GACjB,EAAE;IACD,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,QAAQ,CAAC,EAAE,OAAO,CAAC;CAC7B,GAAG,YAAY,CA6Bf"}
|
|
@@ -1,24 +1,23 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { copyText } from '@nocobase/app-client';
|
|
2
3
|
import { useTranslation } from '@nocobase/i18n/client';
|
|
3
4
|
import { CheckIcon, CopyIcon } from 'lucide-react';
|
|
4
5
|
import { useState } from 'react';
|
|
5
6
|
import { useNotify } from '../hooks/use-notify.js';
|
|
6
7
|
import { Button } from './ui/button.js';
|
|
7
8
|
/** A shell command with a copy button (the add-runner dialog, the upgrade popover). */
|
|
8
|
-
export function CommandLine({ command, }) {
|
|
9
|
+
export function CommandLine({ command, expanded = false, }) {
|
|
9
10
|
const { t } = useTranslation();
|
|
10
11
|
const notify = useNotify();
|
|
11
12
|
const [copied, setCopied] = useState(false);
|
|
12
13
|
async function copy() {
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
14
|
+
const copied = await copyText(command);
|
|
15
|
+
setCopied(copied);
|
|
16
|
+
if (copied)
|
|
16
17
|
window.setTimeout(() => setCopied(false), 2000);
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
notify.error(error, t('command.copyFailed'));
|
|
20
|
-
}
|
|
18
|
+
else
|
|
19
|
+
notify.error(null, t('command.copyFailed'));
|
|
21
20
|
}
|
|
22
|
-
return (_jsxs("div", { className: 'flex items-start gap-2 rounded-lg border bg-muted p-2 pl-3', children: [_jsx("code", { className:
|
|
21
|
+
return (_jsxs("div", { className: 'flex items-start gap-2 rounded-lg border bg-muted p-2 pl-3', children: [_jsx("code", { className: `min-w-0 flex-1 py-1 font-mono text-xs break-all whitespace-pre-wrap select-all ${expanded ? '' : 'max-h-64 overflow-y-auto'}`, children: command }), _jsx(Button, { variant: 'ghost', size: 'icon-sm', "aria-label": copied ? t('command.copied') : t('command.copy'), onClick: () => void copy(), children: copied ? _jsx(CheckIcon, {}) : _jsx(CopyIcon, {}) })] }));
|
|
23
22
|
}
|
|
24
23
|
//# sourceMappingURL=command-line.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"command-line.js","sourceRoot":"","sources":["../../../client/components/command-line.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AACvD,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,cAAc,CAAC;AACnD,OAAO,EAAE,QAAQ,EAAqB,MAAM,OAAO,CAAC;AAEpD,OAAO,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAC;AACnD,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC,uFAAuF;AACvF,MAAM,UAAU,WAAW,CAAC,EAC1B,OAAO,
|
|
1
|
+
{"version":3,"file":"command-line.js","sourceRoot":"","sources":["../../../client/components/command-line.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAChD,OAAO,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AACvD,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,cAAc,CAAC;AACnD,OAAO,EAAE,QAAQ,EAAqB,MAAM,OAAO,CAAC;AAEpD,OAAO,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAC;AACnD,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC,uFAAuF;AACvF,MAAM,UAAU,WAAW,CAAC,EAC1B,OAAO,EACP,QAAQ,GAAG,KAAK,GAIjB;IACC,MAAM,EAAE,CAAC,EAAE,GAAG,cAAc,EAAE,CAAC;IAC/B,MAAM,MAAM,GAAG,SAAS,EAAE,CAAC;IAC3B,MAAM,CAAC,MAAM,EAAE,SAAS,CAAC,GAAG,QAAQ,CAAC,KAAK,CAAC,CAAC;IAE5C,KAAK,UAAU,IAAI;QACjB,MAAM,MAAM,GAAG,MAAM,QAAQ,CAAC,OAAO,CAAC,CAAC;QACvC,SAAS,CAAC,MAAM,CAAC,CAAC;QAClB,IAAI,MAAM;YAAE,MAAM,CAAC,UAAU,CAAC,GAAG,EAAE,CAAC,SAAS,CAAC,KAAK,CAAC,EAAE,IAAI,CAAC,CAAC;;YACvD,MAAM,CAAC,KAAK,CAAC,IAAI,EAAE,CAAC,CAAC,oBAAoB,CAAC,CAAC,CAAC;IACnD,CAAC;IAED,OAAO,CACL,eAAK,SAAS,EAAC,4DAA4D,aACzE,eACE,SAAS,EAAE,kFAAkF,QAAQ,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,0BAA0B,EAAE,YAExI,OAAO,GACH,EACP,KAAC,MAAM,IACL,OAAO,EAAC,OAAO,EACf,IAAI,EAAC,SAAS,gBACF,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,gBAAgB,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,cAAc,CAAC,EAC5D,OAAO,EAAE,GAAG,EAAE,CAAC,KAAK,IAAI,EAAE,YAEzB,MAAM,CAAC,CAAC,CAAC,KAAC,SAAS,KAAG,CAAC,CAAC,CAAC,KAAC,QAAQ,KAAG,GAC/B,IACL,CACP,CAAC;AACJ,CAAC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
/**
|
|
3
3
|
* Adding a variable (`target.name === null`), in the scope chosen in the dialog when the panel lists several, or
|
|
4
|
-
* replacing one's value or whether only
|
|
4
|
+
* replacing one's value or whether only shared runtimes receive it, and showing revealed values. The value field starts
|
|
5
5
|
* empty: stored values never reach the browser except through the audited reveal, and an empty value when replacing
|
|
6
6
|
* keeps the stored one. "Take from the runtime" keeps a name only: the runtime that takes a run provides the value.
|
|
7
7
|
*
|
|
@@ -77,7 +77,7 @@ function VariableForm({ scopes, initialAt, fixedScope, fixedName, initialTeamRun
|
|
|
77
77
|
return;
|
|
78
78
|
setSaving(true);
|
|
79
79
|
try {
|
|
80
|
-
// Replacing with an empty value keeps the stored one: only whether
|
|
80
|
+
// Replacing with an empty value keeps the stored one: only whether shared runtimes alone receive it changes.
|
|
81
81
|
await api.setVariable(scope.scope, scope.scopeId, trimmed, fromRunner || (fixedName !== null && value === '') ? undefined : value, fromRunner ? { fromRunner: true } : { teamRunnersOnly });
|
|
82
82
|
notify.success(t('envVars.saved', { name: trimmed }));
|
|
83
83
|
markSaved();
|