a2acalling 0.6.42 → 0.6.44
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -5
- package/bin/cli.js +146 -34
- package/package.json +1 -1
- package/src/lib/claude-subagent.js +485 -0
- package/src/lib/conversation-driver.js +109 -28
- package/src/lib/disclosure.js +5 -6
- package/src/lib/runtime-adapter.js +221 -437
- package/src/routes/dashboard.js +5 -5
- package/src/server.js +5 -10
package/src/routes/dashboard.js
CHANGED
|
@@ -157,13 +157,13 @@ function parseTopicObjects(values) {
|
|
|
157
157
|
detail = sanitizeString(parts.slice(1).join(':') || parts[0], 250);
|
|
158
158
|
} else if (entry && typeof entry === 'object') {
|
|
159
159
|
topic = sanitizeString(entry.topic, 120);
|
|
160
|
-
detail = sanitizeString(entry.
|
|
160
|
+
detail = sanitizeString(entry.description || entry.topic, 250);
|
|
161
161
|
}
|
|
162
162
|
|
|
163
163
|
if (!topic) continue;
|
|
164
164
|
if (seen.has(topic)) continue;
|
|
165
165
|
seen.add(topic);
|
|
166
|
-
cleaned.push({ topic,
|
|
166
|
+
cleaned.push({ topic, description: detail || topic });
|
|
167
167
|
if (cleaned.length >= 100) break;
|
|
168
168
|
}
|
|
169
169
|
return cleaned;
|
|
@@ -1045,7 +1045,7 @@ function createDashboardApiRouter(options = {}) {
|
|
|
1045
1045
|
const cfg = context.config.getAll();
|
|
1046
1046
|
const manifest = loadManifest();
|
|
1047
1047
|
const configTiers = cfg.tiers || {};
|
|
1048
|
-
const manifestTiers = manifest.
|
|
1048
|
+
const manifestTiers = manifest.tiers || {};
|
|
1049
1049
|
const tierIds = new Set([...Object.keys(configTiers), ...Object.keys(manifestTiers)]);
|
|
1050
1050
|
|
|
1051
1051
|
const tiers = Array.from(tierIds).sort().map(tierId => {
|
|
@@ -1195,8 +1195,8 @@ function createDashboardApiRouter(options = {}) {
|
|
|
1195
1195
|
}
|
|
1196
1196
|
|
|
1197
1197
|
const manifest = loadManifest();
|
|
1198
|
-
if (manifest.
|
|
1199
|
-
manifest.
|
|
1198
|
+
if (manifest.tiers && manifest.tiers[fromTier]) {
|
|
1199
|
+
manifest.tiers[toTier] = JSON.parse(JSON.stringify(manifest.tiers[fromTier]));
|
|
1200
1200
|
saveManifest(manifest);
|
|
1201
1201
|
}
|
|
1202
1202
|
|
package/src/server.js
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
/**
|
|
3
3
|
* A2A Server
|
|
4
4
|
*
|
|
5
|
-
* Routes A2A calls through a runtime adapter (OpenClaw or
|
|
5
|
+
* Routes A2A calls through a runtime adapter (OpenClaw or Claude).
|
|
6
6
|
* Auto-adds contacts, generates summaries, notifies owner.
|
|
7
7
|
*/
|
|
8
8
|
|
|
@@ -210,7 +210,7 @@ function collectTopicKeywords(tierTopics) {
|
|
|
210
210
|
const objectivesList = tierTopics?.objectives || [];
|
|
211
211
|
|
|
212
212
|
for (const item of topicsList) {
|
|
213
|
-
for (const part of [item?.topic, item?.description
|
|
213
|
+
for (const part of [item?.topic, item?.description]) {
|
|
214
214
|
if (!part) continue;
|
|
215
215
|
const terms = String(part)
|
|
216
216
|
.toLowerCase()
|
|
@@ -673,8 +673,8 @@ async function callAgent(message, a2aContext) {
|
|
|
673
673
|
return cleanResponse || '[Sub-agent returned empty response]';
|
|
674
674
|
|
|
675
675
|
} catch (err) {
|
|
676
|
-
callLogger.error('Runtime turn handling failed
|
|
677
|
-
event: '
|
|
676
|
+
callLogger.error('Runtime turn handling failed', {
|
|
677
|
+
event: 'call_turn_failed',
|
|
678
678
|
error_code: 'RUNTIME_TURN_FAILED',
|
|
679
679
|
hint: 'Inspect runtime adapter logs in this trace to identify CLI/bridge failure.',
|
|
680
680
|
error: err,
|
|
@@ -682,11 +682,7 @@ async function callAgent(message, a2aContext) {
|
|
|
682
682
|
phase: 'runtime_turn'
|
|
683
683
|
}
|
|
684
684
|
});
|
|
685
|
-
|
|
686
|
-
caller: a2aContext.caller,
|
|
687
|
-
ownerName: agentContext.owner,
|
|
688
|
-
allowedTopics: a2aContext.allowed_topics || []
|
|
689
|
-
}, err.message);
|
|
685
|
+
throw err;
|
|
690
686
|
}
|
|
691
687
|
}
|
|
692
688
|
|
|
@@ -903,7 +899,6 @@ async function startServer() {
|
|
|
903
899
|
port,
|
|
904
900
|
agent_name: agentContext.name,
|
|
905
901
|
runtime_mode: runtime.mode,
|
|
906
|
-
failover_enabled: runtime.failoverEnabled,
|
|
907
902
|
collaboration_mode: resolveCollabMode(),
|
|
908
903
|
features: ['adaptive collaboration', 'auto-contacts', 'summaries', 'dashboard']
|
|
909
904
|
}
|