plugin-agent-orchestrator 1.0.18 → 1.0.19
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.
|
@@ -169,6 +169,21 @@ class SkillHubSubFeature {
|
|
|
169
169
|
this.app.logger.warn("[skill-hub] plugin-file-manager not found, cannot extract skill package");
|
|
170
170
|
return;
|
|
171
171
|
}
|
|
172
|
+
const rawStorageId = attachment.get("storageId") || attachment.storageId;
|
|
173
|
+
if (rawStorageId) {
|
|
174
|
+
const strId = String(rawStorageId);
|
|
175
|
+
let matchedKey = null;
|
|
176
|
+
for (const key of fileManager.storagesCache.keys()) {
|
|
177
|
+
if (String(key) === strId) {
|
|
178
|
+
matchedKey = key;
|
|
179
|
+
break;
|
|
180
|
+
}
|
|
181
|
+
}
|
|
182
|
+
if (matchedKey !== null) {
|
|
183
|
+
attachment.set("storageId", matchedKey);
|
|
184
|
+
attachment.storageId = matchedKey;
|
|
185
|
+
}
|
|
186
|
+
}
|
|
172
187
|
const streamData = await fileManager.getFileStream(attachment);
|
|
173
188
|
if (!streamData || !streamData.stream) {
|
|
174
189
|
this.app.logger.warn(
|
|
@@ -163,6 +163,21 @@ class SkillExecutionTask {
|
|
|
163
163
|
const fmPlugin = this.app.pm.get("@nocobase/plugin-file-manager");
|
|
164
164
|
const attachment = await this.app.db.getRepository("attachments").findOne({ filter: { id: fileId } });
|
|
165
165
|
if (fmPlugin && attachment) {
|
|
166
|
+
const rawStorageId = attachment.get("storageId") || attachment.storageId;
|
|
167
|
+
if (rawStorageId) {
|
|
168
|
+
const strId = String(rawStorageId);
|
|
169
|
+
let matchedKey = null;
|
|
170
|
+
for (const key of fmPlugin.storagesCache.keys()) {
|
|
171
|
+
if (String(key) === strId) {
|
|
172
|
+
matchedKey = key;
|
|
173
|
+
break;
|
|
174
|
+
}
|
|
175
|
+
}
|
|
176
|
+
if (matchedKey !== null) {
|
|
177
|
+
attachment.set("storageId", matchedKey);
|
|
178
|
+
attachment.storageId = matchedKey;
|
|
179
|
+
}
|
|
180
|
+
}
|
|
166
181
|
try {
|
|
167
182
|
const streamData = await fmPlugin.getFileStream(attachment);
|
|
168
183
|
if (streamData == null ? void 0 : streamData.stream) {
|
package/package.json
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
"displayName.zh-CN": "代理协调器",
|
|
5
5
|
"displayName.vi-VN": "Điều phối Agent",
|
|
6
6
|
"description": "Hierarchical Multi-Agent orchestration for NocoBase AI Employees. Enables Leader agents to delegate tasks to Sub-Agent employees without modifying core plugin-ai.",
|
|
7
|
-
"version": "1.0.
|
|
7
|
+
"version": "1.0.19",
|
|
8
8
|
"license": "Apache-2.0",
|
|
9
9
|
"main": "dist/server/index.js",
|
|
10
10
|
"keywords": [
|
|
@@ -153,6 +153,22 @@ export class SkillHubSubFeature {
|
|
|
153
153
|
return;
|
|
154
154
|
}
|
|
155
155
|
|
|
156
|
+
const rawStorageId = attachment.get('storageId') || attachment.storageId;
|
|
157
|
+
if (rawStorageId) {
|
|
158
|
+
const strId = String(rawStorageId);
|
|
159
|
+
let matchedKey = null;
|
|
160
|
+
for (const key of fileManager.storagesCache.keys()) {
|
|
161
|
+
if (String(key) === strId) {
|
|
162
|
+
matchedKey = key;
|
|
163
|
+
break;
|
|
164
|
+
}
|
|
165
|
+
}
|
|
166
|
+
if (matchedKey !== null) {
|
|
167
|
+
attachment.set('storageId', matchedKey);
|
|
168
|
+
attachment.storageId = matchedKey;
|
|
169
|
+
}
|
|
170
|
+
}
|
|
171
|
+
|
|
156
172
|
const streamData = await fileManager.getFileStream(attachment);
|
|
157
173
|
if (!streamData || !streamData.stream) {
|
|
158
174
|
(this as any).app.logger.warn(
|
|
@@ -172,6 +172,21 @@ export class SkillExecutionTask {
|
|
|
172
172
|
const fmPlugin = (this as any).app.pm.get('@nocobase/plugin-file-manager') as any;
|
|
173
173
|
const attachment = await (this as any).app.db.getRepository('attachments').findOne({ filter: { id: fileId } });
|
|
174
174
|
if (fmPlugin && attachment) {
|
|
175
|
+
const rawStorageId = attachment.get('storageId') || attachment.storageId;
|
|
176
|
+
if (rawStorageId) {
|
|
177
|
+
const strId = String(rawStorageId);
|
|
178
|
+
let matchedKey = null;
|
|
179
|
+
for (const key of fmPlugin.storagesCache.keys()) {
|
|
180
|
+
if (String(key) === strId) {
|
|
181
|
+
matchedKey = key;
|
|
182
|
+
break;
|
|
183
|
+
}
|
|
184
|
+
}
|
|
185
|
+
if (matchedKey !== null) {
|
|
186
|
+
attachment.set('storageId', matchedKey);
|
|
187
|
+
attachment.storageId = matchedKey;
|
|
188
|
+
}
|
|
189
|
+
}
|
|
175
190
|
try {
|
|
176
191
|
const streamData = await fmPlugin.getFileStream(attachment);
|
|
177
192
|
if (streamData?.stream) {
|