@pellux/goodvibes-agent 1.0.7 → 1.0.9
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 +10 -0
- package/README.md +2 -2
- package/dist/package/main.js +410 -259
- package/docs/README.md +1 -1
- package/docs/getting-started.md +1 -1
- package/docs/tools-and-commands.md +2 -2
- package/docs/voice-and-live-tts.md +1 -1
- package/package.json +1 -1
- package/src/input/commands/shell-core.ts +135 -67
- package/src/tools/agent-harness-tool.ts +1 -1
- package/src/tools/agent-harness-ui-surface-metadata.ts +174 -3
- package/src/version.ts +1 -1
package/dist/package/main.js
CHANGED
|
@@ -389257,23 +389257,6 @@ function createSchema2(db) {
|
|
|
389257
389257
|
`);
|
|
389258
389258
|
db.run(`CREATE INDEX IF NOT EXISTS idx_knowledge_schedules_job_id ON knowledge_schedules(job_id)`);
|
|
389259
389259
|
}
|
|
389260
|
-
function getKnowledgeSchemaStatements() {
|
|
389261
|
-
const statements = [];
|
|
389262
|
-
createSchema2({
|
|
389263
|
-
run(sql) {
|
|
389264
|
-
const normalized = sql.trim();
|
|
389265
|
-
if (normalized.length > 0)
|
|
389266
|
-
statements.push(normalized);
|
|
389267
|
-
}
|
|
389268
|
-
});
|
|
389269
|
-
return statements;
|
|
389270
|
-
}
|
|
389271
|
-
function renderKnowledgeSchemaSql() {
|
|
389272
|
-
return `${getKnowledgeSchemaStatements().map((statement) => statement.endsWith(";") ? statement : `${statement};`).join(`
|
|
389273
|
-
|
|
389274
|
-
`)}
|
|
389275
|
-
`;
|
|
389276
|
-
}
|
|
389277
389260
|
function rowObject(columns, values2) {
|
|
389278
389261
|
return Object.fromEntries(columns.map((column, index) => [column, values2[index]]));
|
|
389279
389262
|
}
|
|
@@ -702611,9 +702594,6 @@ var init_ingest = __esm(() => {
|
|
|
702611
702594
|
// node_modules/@pellux/goodvibes-sdk/dist/platform/knowledge/browser-history/index.js
|
|
702612
702595
|
var init_browser_history = __esm(() => {
|
|
702613
702596
|
init_ingest();
|
|
702614
|
-
init_discover();
|
|
702615
|
-
init_readers();
|
|
702616
|
-
init_paths2();
|
|
702617
702597
|
});
|
|
702618
702598
|
|
|
702619
702599
|
// node_modules/graphql/jsutils/devAssert.mjs
|
|
@@ -720253,7 +720233,6 @@ var init_semantic = __esm(() => {
|
|
|
720253
720233
|
init_llm();
|
|
720254
720234
|
init_gap_repair();
|
|
720255
720235
|
init_service4();
|
|
720256
|
-
init_self_improvement();
|
|
720257
720236
|
});
|
|
720258
720237
|
|
|
720259
720238
|
// node_modules/@pellux/goodvibes-sdk/dist/platform/knowledge/home-graph/helpers.js
|
|
@@ -724222,40 +724201,8 @@ var init_map_view = __esm(() => {
|
|
|
724222
724201
|
});
|
|
724223
724202
|
|
|
724224
724203
|
// node_modules/@pellux/goodvibes-sdk/dist/platform/knowledge/home-graph/types.js
|
|
724225
|
-
var
|
|
724204
|
+
var HOME_GRAPH_CAPABILITIES;
|
|
724226
724205
|
var init_types6 = __esm(() => {
|
|
724227
|
-
HOME_GRAPH_NODE_KINDS = [
|
|
724228
|
-
"ha_home",
|
|
724229
|
-
"ha_entity",
|
|
724230
|
-
"ha_device",
|
|
724231
|
-
"ha_area",
|
|
724232
|
-
"ha_automation",
|
|
724233
|
-
"ha_script",
|
|
724234
|
-
"ha_scene",
|
|
724235
|
-
"ha_label",
|
|
724236
|
-
"ha_integration",
|
|
724237
|
-
"ha_room",
|
|
724238
|
-
"ha_device_passport",
|
|
724239
|
-
"ha_maintenance_item",
|
|
724240
|
-
"ha_troubleshooting_case",
|
|
724241
|
-
"ha_purchase",
|
|
724242
|
-
"ha_network_node"
|
|
724243
|
-
];
|
|
724244
|
-
HOME_GRAPH_RELATIONS = [
|
|
724245
|
-
"controls",
|
|
724246
|
-
"located_in",
|
|
724247
|
-
"belongs_to_device",
|
|
724248
|
-
"has_manual",
|
|
724249
|
-
"has_receipt",
|
|
724250
|
-
"has_warranty",
|
|
724251
|
-
"has_issue",
|
|
724252
|
-
"fixed_by",
|
|
724253
|
-
"uses_battery",
|
|
724254
|
-
"connected_via",
|
|
724255
|
-
"part_of_network",
|
|
724256
|
-
"mentioned_by",
|
|
724257
|
-
"source_for"
|
|
724258
|
-
];
|
|
724259
724206
|
HOME_GRAPH_CAPABILITIES = [
|
|
724260
724207
|
"knowledge-space-isolation",
|
|
724261
724208
|
"snapshot-sync",
|
|
@@ -725662,7 +725609,6 @@ var init_service5 = __esm(() => {
|
|
|
725662
725609
|
var init_home_graph = __esm(() => {
|
|
725663
725610
|
init_service5();
|
|
725664
725611
|
init_extension();
|
|
725665
|
-
init_types6();
|
|
725666
725612
|
});
|
|
725667
725613
|
|
|
725668
725614
|
// node_modules/@pellux/goodvibes-sdk/dist/platform/knowledge/store-refinement.js
|
|
@@ -727990,14 +727936,10 @@ var init_service6 = __esm(() => {
|
|
|
727990
727936
|
var init_project_planning = __esm(() => {
|
|
727991
727937
|
init_service6();
|
|
727992
727938
|
init_helpers3();
|
|
727993
|
-
init_readiness();
|
|
727994
727939
|
});
|
|
727995
727940
|
|
|
727996
727941
|
// node_modules/@pellux/goodvibes-sdk/dist/platform/knowledge/persistence.js
|
|
727997
|
-
var init_persistence =
|
|
727998
|
-
init_store_schema();
|
|
727999
|
-
init_store_load();
|
|
728000
|
-
});
|
|
727942
|
+
var init_persistence = () => {};
|
|
728001
727943
|
|
|
728002
727944
|
// node_modules/@pellux/goodvibes-sdk/dist/platform/knowledge/projections.js
|
|
728003
727945
|
class KnowledgeProjectionService {
|
|
@@ -731505,21 +731447,21 @@ var init_service7 = __esm(() => {
|
|
|
731505
731447
|
var exports_knowledge = {};
|
|
731506
731448
|
__export(exports_knowledge, {
|
|
731507
731449
|
withKnowledgeSpace: () => withKnowledgeSpace,
|
|
731508
|
-
uniqKnowledgeValues: () =>
|
|
731509
|
-
stabilizeKnowledgeText: () =>
|
|
731510
|
-
runKnowledgeSemanticSelfImprovement: () =>
|
|
731450
|
+
uniqKnowledgeValues: () => uniq3,
|
|
731451
|
+
stabilizeKnowledgeText: () => stableText2,
|
|
731452
|
+
runKnowledgeSemanticSelfImprovement: () => runKnowledgeSemanticSelfImprovement2,
|
|
731511
731453
|
resolveProjectPlanningSpace: () => resolveProjectPlanningSpace,
|
|
731512
|
-
resolveKnowledgeDbPathFromControlPlaneDir: () =>
|
|
731454
|
+
resolveKnowledgeDbPathFromControlPlaneDir: () => resolveKnowledgeDbPathFromControlPlaneDir2,
|
|
731513
731455
|
renderPacket: () => renderPacket,
|
|
731514
731456
|
renderKnowledgeSchemaSql: () => renderKnowledgeSchemaSql,
|
|
731515
731457
|
renderKnowledgeMap: () => renderKnowledgeMap,
|
|
731516
731458
|
readKnowledgeSearchText: () => readKnowledgeSearchText,
|
|
731517
|
-
readBrowserKnowledgeProfile: () =>
|
|
731459
|
+
readBrowserKnowledgeProfile: () => readBrowserKnowledgeProfile2,
|
|
731518
731460
|
projectPlanningSourceId: () => projectPlanningSourceId,
|
|
731519
731461
|
projectPlanningProjectIdFromPath: () => projectPlanningProjectIdFromPath,
|
|
731520
731462
|
projectPlanningCanonicalUri: () => projectPlanningCanonicalUri,
|
|
731521
731463
|
projectKnowledgeSpaceId: () => projectKnowledgeSpaceId,
|
|
731522
|
-
parseKnowledgeJsonValue: () =>
|
|
731464
|
+
parseKnowledgeJsonValue: () => parseJsonValue2,
|
|
731523
731465
|
normalizeProjectId: () => normalizeProjectId,
|
|
731524
731466
|
normalizeKnowledgeSpaceId: () => normalizeKnowledgeSpaceId,
|
|
731525
731467
|
normalizeHomeAssistantInstallationId: () => normalizeHomeAssistantInstallationId,
|
|
@@ -731527,12 +731469,12 @@ __export(exports_knowledge, {
|
|
|
731527
731469
|
materializeGeneratedKnowledgeProjection: () => materializeGeneratedKnowledgeProjection,
|
|
731528
731470
|
looksLikeRawPdfPayload: () => looksLikeRawPdfPayload,
|
|
731529
731471
|
looksBinaryLikeText: () => looksBinaryLikeText,
|
|
731530
|
-
loadKnowledgeStoreSnapshot: () =>
|
|
731472
|
+
loadKnowledgeStoreSnapshot: () => loadKnowledgeStoreSnapshot2,
|
|
731531
731473
|
listGeneratedKnowledgePages: () => listGeneratedKnowledgePages,
|
|
731532
|
-
listBrowserKinds: () =>
|
|
731474
|
+
listBrowserKinds: () => listBrowserKinds2,
|
|
731533
731475
|
knowledgeSpaceMetadata: () => knowledgeSpaceMetadata,
|
|
731534
731476
|
knowledgePageSourceWeight: () => knowledgePageSourceWeight,
|
|
731535
|
-
knowledgeNowMs: () =>
|
|
731477
|
+
knowledgeNowMs: () => nowMs2,
|
|
731536
731478
|
knowledgeExtractionNeedsRefresh: () => knowledgeExtractionNeedsRefresh,
|
|
731537
731479
|
isUsefulKnowledgePageSourceCandidate: () => isUsefulKnowledgePageSourceCandidate,
|
|
731538
731480
|
isUsefulKnowledgePageSource: () => isUsefulKnowledgePageSource,
|
|
@@ -731552,12 +731494,12 @@ __export(exports_knowledge, {
|
|
|
731552
731494
|
generatedKnowledgeSourceId: () => generatedKnowledgeSourceId,
|
|
731553
731495
|
generatedKnowledgeCanonicalUri: () => generatedKnowledgeCanonicalUri,
|
|
731554
731496
|
extractKnowledgeArtifact: () => extractKnowledgeArtifact,
|
|
731555
|
-
evaluateProjectPlanningReadiness: () =>
|
|
731556
|
-
discoverBrowserKnowledgeProfiles: () =>
|
|
731497
|
+
evaluateProjectPlanningReadiness: () => evaluateProjectPlanningReadiness2,
|
|
731498
|
+
discoverBrowserKnowledgeProfiles: () => discoverBrowserKnowledgeProfiles2,
|
|
731557
731499
|
createWebKnowledgeGapRepairer: () => createWebKnowledgeGapRepairer,
|
|
731558
731500
|
createProviderBackedKnowledgeSemanticLlm: () => createProviderBackedKnowledgeSemanticLlm,
|
|
731559
731501
|
createMemoryApi: () => createMemoryApi,
|
|
731560
|
-
createKnowledgeSchema: () =>
|
|
731502
|
+
createKnowledgeSchema: () => createSchema3,
|
|
731561
731503
|
createKnowledgeApi: () => createKnowledgeApi,
|
|
731562
731504
|
createDefaultKnowledgeConnectorRegistry: () => createDefaultKnowledgeConnectorRegistry,
|
|
731563
731505
|
compareKnowledgePageSources: () => compareKnowledgePageSources,
|
|
@@ -733995,7 +733937,7 @@ var init_delivery_manager = __esm(() => {
|
|
|
733995
733937
|
});
|
|
733996
733938
|
|
|
733997
733939
|
// node_modules/@pellux/goodvibes-sdk/dist/platform/automation/scheduler-capacity.js
|
|
733998
|
-
function computeSchedulerCapacity(slotsTotal, runs,
|
|
733940
|
+
function computeSchedulerCapacity(slotsTotal, runs, nowMs3 = Date.now()) {
|
|
733999
733941
|
let slotsInUse = 0;
|
|
734000
733942
|
const queuedRuns = [];
|
|
734001
733943
|
for (const run7 of runs) {
|
|
@@ -734005,7 +733947,7 @@ function computeSchedulerCapacity(slotsTotal, runs, nowMs2 = Date.now()) {
|
|
|
734005
733947
|
queuedRuns.push(run7);
|
|
734006
733948
|
}
|
|
734007
733949
|
const queueDepth = queuedRuns.length;
|
|
734008
|
-
const oldestQueuedAgeMs = queueDepth > 0 ?
|
|
733950
|
+
const oldestQueuedAgeMs = queueDepth > 0 ? nowMs3 - Math.min(...queuedRuns.map((r5) => r5.queuedAt)) : null;
|
|
734009
733951
|
return { slotsTotal, slotsInUse, queueDepth, oldestQueuedAgeMs };
|
|
734010
733952
|
}
|
|
734011
733953
|
|
|
@@ -816566,7 +816508,7 @@ var createStyledCell = (char, overrides = {}) => ({
|
|
|
816566
816508
|
// src/version.ts
|
|
816567
816509
|
import { readFileSync } from "fs";
|
|
816568
816510
|
import { join } from "path";
|
|
816569
|
-
var _version = "1.0.
|
|
816511
|
+
var _version = "1.0.9";
|
|
816570
816512
|
var _sdkVersion = "0.33.35";
|
|
816571
816513
|
try {
|
|
816572
816514
|
const pkg = JSON.parse(readFileSync(join(import.meta.dir, "..", "package.json"), "utf-8"));
|
|
@@ -839428,7 +839370,7 @@ var WORK_PLAN_STATUSES = [
|
|
|
839428
839370
|
"failed",
|
|
839429
839371
|
"cancelled"
|
|
839430
839372
|
];
|
|
839431
|
-
function
|
|
839373
|
+
function nowMs3() {
|
|
839432
839374
|
return Date.now();
|
|
839433
839375
|
}
|
|
839434
839376
|
function isObject5(value) {
|
|
@@ -839534,7 +839476,7 @@ class WorkPlanStore {
|
|
|
839534
839476
|
if (!normalizedTitle)
|
|
839535
839477
|
throw new Error("Work plan item title is required.");
|
|
839536
839478
|
const plan = this.readPlan();
|
|
839537
|
-
const time4 =
|
|
839479
|
+
const time4 = nowMs3();
|
|
839538
839480
|
const item = {
|
|
839539
839481
|
id: createItemId(),
|
|
839540
839482
|
title: normalizedTitle,
|
|
@@ -839558,7 +839500,7 @@ class WorkPlanStore {
|
|
|
839558
839500
|
updateItem(idOrPrefix, patch2) {
|
|
839559
839501
|
const plan = this.readPlan();
|
|
839560
839502
|
const item = this.resolveItem(plan, idOrPrefix);
|
|
839561
|
-
const time4 =
|
|
839503
|
+
const time4 = nowMs3();
|
|
839562
839504
|
const nextStatus = patch2.status ?? item.status;
|
|
839563
839505
|
const next = this.pruneItem({
|
|
839564
839506
|
...item,
|
|
@@ -839591,7 +839533,7 @@ class WorkPlanStore {
|
|
|
839591
839533
|
removeItem(idOrPrefix) {
|
|
839592
839534
|
const plan = this.readPlan();
|
|
839593
839535
|
const item = this.resolveItem(plan, idOrPrefix);
|
|
839594
|
-
const time4 =
|
|
839536
|
+
const time4 = nowMs3();
|
|
839595
839537
|
const remaining = plan.items.filter((candidate) => candidate.id !== item.id);
|
|
839596
839538
|
this.writePlan({
|
|
839597
839539
|
...plan,
|
|
@@ -839611,7 +839553,7 @@ class WorkPlanStore {
|
|
|
839611
839553
|
...plan,
|
|
839612
839554
|
items: remaining,
|
|
839613
839555
|
activeItemId: remaining[0]?.id,
|
|
839614
|
-
updatedAt:
|
|
839556
|
+
updatedAt: nowMs3()
|
|
839615
839557
|
});
|
|
839616
839558
|
return removed;
|
|
839617
839559
|
}
|
|
@@ -839650,7 +839592,7 @@ class WorkPlanStore {
|
|
|
839650
839592
|
const parsed = JSON.parse(raw);
|
|
839651
839593
|
if (!isObject5(parsed))
|
|
839652
839594
|
return this.createEmptyPlan();
|
|
839653
|
-
const time4 =
|
|
839595
|
+
const time4 = nowMs3();
|
|
839654
839596
|
const createdAt = typeof parsed.createdAt === "number" ? parsed.createdAt : time4;
|
|
839655
839597
|
const updatedAt = typeof parsed.updatedAt === "number" ? parsed.updatedAt : createdAt;
|
|
839656
839598
|
const items = Array.isArray(parsed.items) ? parsed.items.map((item) => normalizeItem(item, createdAt)).filter((item) => item !== null) : [];
|
|
@@ -839669,7 +839611,7 @@ class WorkPlanStore {
|
|
|
839669
839611
|
};
|
|
839670
839612
|
}
|
|
839671
839613
|
createEmptyPlan() {
|
|
839672
|
-
const time4 =
|
|
839614
|
+
const time4 = nowMs3();
|
|
839673
839615
|
return {
|
|
839674
839616
|
id: createPlanId(this.options.projectId, this.options.projectRoot),
|
|
839675
839617
|
projectId: this.options.projectId,
|
|
@@ -847775,13 +847717,13 @@ init_state3();
|
|
|
847775
847717
|
|
|
847776
847718
|
// src/input/commands/recall-shared.ts
|
|
847777
847719
|
var VALID_CLASSES = ["decision", "constraint", "incident", "pattern", "fact", "risk", "runbook", "architecture", "ownership"];
|
|
847778
|
-
var
|
|
847720
|
+
var VALID_SCOPES2 = ["session", "project", "team"];
|
|
847779
847721
|
var VALID_REVIEW_STATES = ["fresh", "reviewed", "stale", "contradicted"];
|
|
847780
847722
|
function isValidClass(s4) {
|
|
847781
847723
|
return VALID_CLASSES.includes(s4);
|
|
847782
847724
|
}
|
|
847783
847725
|
function isValidScope(s4) {
|
|
847784
|
-
return
|
|
847726
|
+
return VALID_SCOPES2.includes(s4);
|
|
847785
847727
|
}
|
|
847786
847728
|
function isValidReviewState(s4) {
|
|
847787
847729
|
return VALID_REVIEW_STATES.includes(s4);
|
|
@@ -847824,7 +847766,7 @@ function handleRecallSearch(args2, context) {
|
|
|
847824
847766
|
if (isValidScope(scope))
|
|
847825
847767
|
filter.scope = scope;
|
|
847826
847768
|
else {
|
|
847827
|
-
context.print(`[memory] Unknown scope "${scope}". Valid values ${
|
|
847769
|
+
context.print(`[memory] Unknown scope "${scope}". Valid values ${VALID_SCOPES2.join(", ")}.`);
|
|
847828
847770
|
return;
|
|
847829
847771
|
}
|
|
847830
847772
|
}
|
|
@@ -847999,7 +847941,7 @@ function handleRecallList(args2, context) {
|
|
|
847999
847941
|
if (scopeIdx !== -1 && args2[scopeIdx + 1]) {
|
|
848000
847942
|
const scope = args2[scopeIdx + 1];
|
|
848001
847943
|
if (!isValidScope(scope)) {
|
|
848002
|
-
context.print(`[memory] Unknown scope "${scope}". Valid values ${
|
|
847944
|
+
context.print(`[memory] Unknown scope "${scope}". Valid values ${VALID_SCOPES2.join(", ")}.`);
|
|
848003
847945
|
return;
|
|
848004
847946
|
}
|
|
848005
847947
|
filter.scope = scope;
|
|
@@ -848049,7 +847991,7 @@ async function handleRecallAdd(args2, context) {
|
|
|
848049
847991
|
const tags = tagsRaw ? tagsRaw.split(",").map((token) => token.trim()).filter(Boolean) : [];
|
|
848050
847992
|
const scope = scopeRaw && isValidScope(scopeRaw) ? scopeRaw : "project";
|
|
848051
847993
|
if (scopeRaw && !isValidScope(scopeRaw)) {
|
|
848052
|
-
context.print(`[memory] Invalid scope "${scopeRaw}". Valid values ${
|
|
847994
|
+
context.print(`[memory] Invalid scope "${scopeRaw}". Valid values ${VALID_SCOPES2.join(", ")}.`);
|
|
848053
847995
|
return;
|
|
848054
847996
|
}
|
|
848055
847997
|
const provenance = [];
|
|
@@ -848183,7 +848125,7 @@ function handleRecallExport(args2, context) {
|
|
|
848183
848125
|
if (scopeIdx !== -1 && commandArgs[scopeIdx + 1]) {
|
|
848184
848126
|
const scope = commandArgs[scopeIdx + 1];
|
|
848185
848127
|
if (!isValidScope(scope)) {
|
|
848186
|
-
context.print(`[memory] Unknown scope "${scope}". Valid values ${
|
|
848128
|
+
context.print(`[memory] Unknown scope "${scope}". Valid values ${VALID_SCOPES2.join(", ")}.`);
|
|
848187
848129
|
return;
|
|
848188
848130
|
}
|
|
848189
848131
|
filter.scope = scope;
|
|
@@ -848262,7 +848204,7 @@ function handleRecallHandoffExport(args2, context) {
|
|
|
848262
848204
|
const scopeIdx = commandArgs.indexOf("--scope");
|
|
848263
848205
|
const scopeRaw = scopeIdx !== -1 ? commandArgs[scopeIdx + 1] : "team";
|
|
848264
848206
|
if (!scopeRaw || !isValidScope(scopeRaw)) {
|
|
848265
|
-
context.print(`[memory] Unknown scope "${scopeRaw ?? ""}". Valid values ${
|
|
848207
|
+
context.print(`[memory] Unknown scope "${scopeRaw ?? ""}". Valid values ${VALID_SCOPES2.join(", ")}.`);
|
|
848266
848208
|
return;
|
|
848267
848209
|
}
|
|
848268
848210
|
const bundle = memory.exportBundle({ scope: scopeRaw });
|
|
@@ -848378,7 +848320,7 @@ function handleRecallPromote(args2, context) {
|
|
|
848378
848320
|
const id = parsed.rest[0];
|
|
848379
848321
|
const scope = parsed.rest[1];
|
|
848380
848322
|
if (!id || !scope || !isValidScope(scope)) {
|
|
848381
|
-
context.print(`[memory] Usage: /memory promote <id> <${
|
|
848323
|
+
context.print(`[memory] Usage: /memory promote <id> <${VALID_SCOPES2.join("|")}> --yes`);
|
|
848382
848324
|
return;
|
|
848383
848325
|
}
|
|
848384
848326
|
if (!parsed.yes) {
|
|
@@ -849256,6 +849198,136 @@ var knowledgeCommand = {
|
|
|
849256
849198
|
};
|
|
849257
849199
|
|
|
849258
849200
|
// src/input/commands/shell-core.ts
|
|
849201
|
+
function commandCategory(commandName) {
|
|
849202
|
+
if ([
|
|
849203
|
+
"agent",
|
|
849204
|
+
"agent-profile",
|
|
849205
|
+
"brief",
|
|
849206
|
+
"health",
|
|
849207
|
+
"welcome",
|
|
849208
|
+
"setup",
|
|
849209
|
+
"tasks",
|
|
849210
|
+
"approval",
|
|
849211
|
+
"automation",
|
|
849212
|
+
"delegate",
|
|
849213
|
+
"schedule",
|
|
849214
|
+
"workplan",
|
|
849215
|
+
"plan"
|
|
849216
|
+
].includes(commandName))
|
|
849217
|
+
return "Agent Operator";
|
|
849218
|
+
if ([
|
|
849219
|
+
"knowledge",
|
|
849220
|
+
"memory",
|
|
849221
|
+
"notes",
|
|
849222
|
+
"personas",
|
|
849223
|
+
"skills",
|
|
849224
|
+
"routines"
|
|
849225
|
+
].includes(commandName))
|
|
849226
|
+
return "Knowledge & Local Context";
|
|
849227
|
+
if ([
|
|
849228
|
+
"channels",
|
|
849229
|
+
"notify",
|
|
849230
|
+
"qrcode",
|
|
849231
|
+
"pair"
|
|
849232
|
+
].includes(commandName))
|
|
849233
|
+
return "Channels";
|
|
849234
|
+
if ([
|
|
849235
|
+
"model",
|
|
849236
|
+
"provider",
|
|
849237
|
+
"providers",
|
|
849238
|
+
"effort",
|
|
849239
|
+
"pin",
|
|
849240
|
+
"unpin",
|
|
849241
|
+
"refresh-models",
|
|
849242
|
+
"mode",
|
|
849243
|
+
"tts",
|
|
849244
|
+
"voice",
|
|
849245
|
+
"media",
|
|
849246
|
+
"image"
|
|
849247
|
+
].includes(commandName))
|
|
849248
|
+
return "Model, Voice & Media";
|
|
849249
|
+
if ([
|
|
849250
|
+
"settings",
|
|
849251
|
+
"config",
|
|
849252
|
+
"keybindings",
|
|
849253
|
+
"shortcuts",
|
|
849254
|
+
"mcp",
|
|
849255
|
+
"secrets",
|
|
849256
|
+
"auth",
|
|
849257
|
+
"accounts",
|
|
849258
|
+
"subscription",
|
|
849259
|
+
"compat",
|
|
849260
|
+
"security",
|
|
849261
|
+
"trust",
|
|
849262
|
+
"bundle"
|
|
849263
|
+
].includes(commandName))
|
|
849264
|
+
return "Setup & Security";
|
|
849265
|
+
if ([
|
|
849266
|
+
"save",
|
|
849267
|
+
"load",
|
|
849268
|
+
"sessions",
|
|
849269
|
+
"session",
|
|
849270
|
+
"conversation",
|
|
849271
|
+
"export",
|
|
849272
|
+
"title",
|
|
849273
|
+
"clear",
|
|
849274
|
+
"reset",
|
|
849275
|
+
"compact",
|
|
849276
|
+
"undo",
|
|
849277
|
+
"redo",
|
|
849278
|
+
"retry",
|
|
849279
|
+
"expand",
|
|
849280
|
+
"collapse",
|
|
849281
|
+
"context",
|
|
849282
|
+
"bookmarks",
|
|
849283
|
+
"paste",
|
|
849284
|
+
"next-error",
|
|
849285
|
+
"prev-error"
|
|
849286
|
+
].includes(commandName))
|
|
849287
|
+
return "Conversation";
|
|
849288
|
+
return "Tools & System";
|
|
849289
|
+
}
|
|
849290
|
+
function commandDetail(command8) {
|
|
849291
|
+
const parts2 = [command8.description];
|
|
849292
|
+
if (command8.usage)
|
|
849293
|
+
parts2.push(`usage: /${command8.name} ${command8.usage}`);
|
|
849294
|
+
if (command8.aliases?.length)
|
|
849295
|
+
parts2.push(`aliases: ${command8.aliases.map((alias) => `/${alias}`).join(", ")}`);
|
|
849296
|
+
return parts2.join(" | ");
|
|
849297
|
+
}
|
|
849298
|
+
function listRegisteredCommandItems(registry5) {
|
|
849299
|
+
return registry5.list().slice().sort((a4, b3) => a4.name.localeCompare(b3.name)).map((command8) => ({
|
|
849300
|
+
id: `/${command8.name}`,
|
|
849301
|
+
label: `/${command8.name}`,
|
|
849302
|
+
detail: commandDetail(command8),
|
|
849303
|
+
category: commandCategory(command8.name),
|
|
849304
|
+
primaryAction: "select",
|
|
849305
|
+
actions: "[Enter] run command"
|
|
849306
|
+
}));
|
|
849307
|
+
}
|
|
849308
|
+
function registeredCommandListText(registry5) {
|
|
849309
|
+
const commands3 = listRegisteredCommandItems(registry5);
|
|
849310
|
+
return [
|
|
849311
|
+
"Open the Agent workspace first, then press / inside it to search every product action.",
|
|
849312
|
+
"",
|
|
849313
|
+
"Registered slash commands:",
|
|
849314
|
+
...commands3.map((item) => ` ${item.label} - ${item.detail}`)
|
|
849315
|
+
].join(`
|
|
849316
|
+
`);
|
|
849317
|
+
}
|
|
849318
|
+
function openRegisteredCommandSelection(registry5, ctx) {
|
|
849319
|
+
ctx.openSelection?.("Help - Commands", listRegisteredCommandItems(registry5), { allowSearch: true }, (result2) => {
|
|
849320
|
+
if (!result2)
|
|
849321
|
+
return;
|
|
849322
|
+
const command8 = result2.item.id;
|
|
849323
|
+
if (command8.startsWith("/")) {
|
|
849324
|
+
const parts2 = command8.slice(1).trim().split(/\s+/);
|
|
849325
|
+
const name51 = parts2[0];
|
|
849326
|
+
const cmdArgs = parts2.slice(1);
|
|
849327
|
+
ctx.executeCommand?.(name51, cmdArgs) ?? registry5.execute(name51, cmdArgs, ctx);
|
|
849328
|
+
}
|
|
849329
|
+
});
|
|
849330
|
+
}
|
|
849259
849331
|
function registerShellCoreCommands(registry5) {
|
|
849260
849332
|
registry5.register({
|
|
849261
849333
|
name: "model",
|
|
@@ -849305,6 +849377,10 @@ function registerShellCoreCommands(registry5) {
|
|
|
849305
849377
|
aliases: ["cmds"],
|
|
849306
849378
|
description: "Browse all commands in a scrollable list",
|
|
849307
849379
|
handler(_args, ctx) {
|
|
849380
|
+
if (ctx.openSelection) {
|
|
849381
|
+
openRegisteredCommandSelection(registry5, ctx);
|
|
849382
|
+
return;
|
|
849383
|
+
}
|
|
849308
849384
|
if (ctx.openHelpOverlay) {
|
|
849309
849385
|
ctx.openHelpOverlay();
|
|
849310
849386
|
return;
|
|
@@ -849369,75 +849445,10 @@ function registerShellCoreCommands(registry5) {
|
|
|
849369
849445
|
argsHint: "[command]",
|
|
849370
849446
|
handler(_args, ctx) {
|
|
849371
849447
|
if (ctx.openSelection) {
|
|
849372
|
-
|
|
849373
|
-
{ id: "/agent", label: "/agent", detail: "Open the Agent operator workspace; press / inside it to search every action", category: "Agent Operator" },
|
|
849374
|
-
{ id: "/agent setup", label: "/agent setup", detail: "Open the Agent setup workspace; workspace search can find every setup action", category: "Agent Operator" },
|
|
849375
|
-
{ id: "/agent channels", label: "/agent channels", detail: "Open channel readiness and delivery safety", category: "Agent Operator" },
|
|
849376
|
-
{ id: "/agent knowledge", label: "/agent knowledge", detail: "Open isolated Agent Knowledge workflows", category: "Agent Operator" },
|
|
849377
|
-
{ id: "/agent voice-media", label: "/agent voice-media", detail: "Open voice, TTS, image, browser, and media setup", category: "Agent Operator" },
|
|
849378
|
-
{ id: "/home", label: "/home", detail: "Alias for the Agent operator workspace", category: "Agent Operator" },
|
|
849379
|
-
{ id: "/brief", label: "/brief", detail: "Show a concise Agent operator briefing and next actions", category: "Agent Operator" },
|
|
849380
|
-
{ id: "/knowledge", label: "/knowledge", detail: "Inspect isolated Agent Knowledge status, ask/search, and ingest flows", category: "Agent Operator" },
|
|
849381
|
-
{ id: "/memory", label: "/memory", detail: "Review Agent-local memory records", category: "Agent Operator" },
|
|
849382
|
-
{ id: "/notes", label: "/notes", detail: "Open Agent-local scratchpad notes for source triage and temporary context", category: "Agent Operator" },
|
|
849383
|
-
{ id: "/personas", label: "/personas", detail: "Create, review, and activate Agent-local personas", category: "Agent Operator" },
|
|
849384
|
-
{ id: "/skills", label: "/skills", detail: "Create, review, and enable reusable Agent skills", category: "Agent Operator" },
|
|
849385
|
-
{ id: "/routines", label: "/routines", detail: "Create, review, start, and promote Agent routines explicitly", category: "Agent Operator" },
|
|
849386
|
-
{ id: "/automation", label: "/automation", detail: "Run confirmed connected-host automation actions", category: "Agent Operator" },
|
|
849387
|
-
{ id: "/delegate", label: "/delegate [task]", detail: "Explicit build/fix/review handoff to GoodVibes TUI", category: "Agent Operator" },
|
|
849388
|
-
{ id: "/channels", label: "/channels", detail: "Inspect messaging-channel readiness without sending messages", category: "Agent Operator" },
|
|
849389
|
-
{ id: "/pair", label: "/pair", detail: "Pair companion clients through connected GoodVibes host", category: "Agent Operator" },
|
|
849390
|
-
{ id: "/model", label: "/model [id]", detail: "Select LLM model", category: "Model & Provider" },
|
|
849391
|
-
{ id: "/provider", label: "/provider [name]", detail: "Switch provider", category: "Model & Provider" },
|
|
849392
|
-
{ id: "/effort", label: "/effort [level]", detail: "Reasoning effort (instant/low/medium/high)", category: "Model & Provider" },
|
|
849393
|
-
{ id: "/config", label: "/config [category|key]", detail: "Open fullscreen configuration workspace", category: "Config & Display" },
|
|
849394
|
-
{ id: "/expand", label: "/expand [type]", detail: "Expand blocks (all|thinking|tool|code)", category: "Config & Display" },
|
|
849395
|
-
{ id: "/collapse", label: "/collapse [type]", detail: "Collapse blocks", category: "Config & Display" },
|
|
849396
|
-
{ id: "/bookmarks", label: "/bookmarks", detail: "List bookmarked blocks", category: "Config & Display" },
|
|
849397
|
-
{ id: "/clear", label: "/clear", detail: "Clear display (keep context)", category: "Conversation" },
|
|
849398
|
-
{ id: "/reset", label: "/reset", detail: "Clear display + context", category: "Conversation" },
|
|
849399
|
-
{ id: "/compact", label: "/compact", detail: "Summarize to free context", category: "Conversation" },
|
|
849400
|
-
{ id: "/export", label: "/export [file] --yes", detail: "Export as markdown", category: "Conversation" },
|
|
849401
|
-
{ id: "/title", label: "/title [text]", detail: "Show or set title", category: "Conversation" },
|
|
849402
|
-
{ id: "/save", label: "/save [name]", detail: "Save session", category: "Conversation" },
|
|
849403
|
-
{ id: "/load", label: "/load <name>", detail: "Load session", category: "Conversation" },
|
|
849404
|
-
{ id: "/sessions", label: "/sessions", detail: "List saved sessions", category: "Conversation" },
|
|
849405
|
-
{ id: "/session", label: "/session", detail: "Current session info", category: "Conversation" },
|
|
849406
|
-
{ id: "/session list", label: "/session list", detail: "List all sessions", category: "Conversation" },
|
|
849407
|
-
{ id: "/session rename", label: "/session rename <name>", detail: "Rename current session", category: "Conversation" },
|
|
849408
|
-
{ id: "/session resume", label: "/session resume <id>", detail: "Load and resume a session", category: "Conversation" },
|
|
849409
|
-
{ id: "/session fork", label: "/session fork [name]", detail: "Fork current session to new ID", category: "Conversation" },
|
|
849410
|
-
{ id: "/session save", label: "/session save [name]", detail: "Force-save current session", category: "Conversation" },
|
|
849411
|
-
{ id: "/session info", label: "/session info [id]", detail: "Show session details", category: "Conversation" },
|
|
849412
|
-
{ id: "/session export", label: "/session export <id> [format]", detail: "Export session as markdown/text", category: "Conversation" },
|
|
849413
|
-
{ id: "/session search", label: "/session search <query>", detail: "Search across all sessions", category: "Conversation" },
|
|
849414
|
-
{ id: "/session delete", label: "/session delete <id> --yes", detail: "Delete a session", category: "Conversation" },
|
|
849415
|
-
{ id: "/undo", label: "/undo", detail: "Remove last turn", category: "Conversation" },
|
|
849416
|
-
{ id: "/redo", label: "/redo", detail: "Restore undone turn", category: "Conversation" },
|
|
849417
|
-
{ id: "/retry", label: "/retry [text]", detail: "Re-send last message", category: "Conversation" },
|
|
849418
|
-
{ id: "/paste", label: "/paste", detail: "Insert clipboard text or image into the prompt", category: "Tools & System" },
|
|
849419
|
-
{ id: "/shortcuts", label: "/shortcuts", detail: "View keyboard shortcuts reference", category: "Tools & System" },
|
|
849420
|
-
{ id: "/commands", label: "/commands", detail: "Browse all commands in a scrollable list", category: "Tools & System" },
|
|
849421
|
-
{ id: "/compat", label: "/compat", detail: "Inspect connected-host and Agent Knowledge compatibility", category: "Tools & System" },
|
|
849422
|
-
{ id: "/secrets", label: "/secrets set|link|get|test|list|delete", detail: "Manage encrypted and provider-backed secrets", category: "Tools & System" },
|
|
849423
|
-
{ id: "/bundle", label: "/bundle export|inspect|import", detail: "Manage redacted Agent support bundles", category: "Tools & System" },
|
|
849424
|
-
{ id: "/help", label: "/help", detail: "This help", category: "Tools & System" },
|
|
849425
|
-
{ id: "/quit", label: "/quit", detail: "Exit", category: "Tools & System" }
|
|
849426
|
-
];
|
|
849427
|
-
ctx.openSelection("Help \u2014 Commands", items, { allowSearch: true }, (result2) => {
|
|
849428
|
-
if (!result2)
|
|
849429
|
-
return;
|
|
849430
|
-
const command8 = result2.item.id;
|
|
849431
|
-
if (command8.startsWith("/")) {
|
|
849432
|
-
const parts2 = command8.slice(1).trim().split(/\s+/);
|
|
849433
|
-
const name51 = parts2[0];
|
|
849434
|
-
const cmdArgs = parts2.slice(1);
|
|
849435
|
-
ctx.executeCommand?.(name51, cmdArgs) ?? registry5.execute(name51, cmdArgs, ctx);
|
|
849436
|
-
}
|
|
849437
|
-
});
|
|
849448
|
+
openRegisteredCommandSelection(registry5, ctx);
|
|
849438
849449
|
return;
|
|
849439
849450
|
}
|
|
849440
|
-
ctx.print(
|
|
849451
|
+
ctx.print(registeredCommandListText(registry5));
|
|
849441
849452
|
}
|
|
849442
849453
|
});
|
|
849443
849454
|
registry5.register({
|
|
@@ -862154,7 +862165,7 @@ import { mkdirSync as mkdirSync64, readFileSync as readFileSync86, writeFileSync
|
|
|
862154
862165
|
import { dirname as dirname63, resolve as resolve39 } from "path";
|
|
862155
862166
|
init_state3();
|
|
862156
862167
|
var VALID_CLASSES2 = ["decision", "constraint", "incident", "pattern", "fact", "risk", "runbook", "architecture", "ownership"];
|
|
862157
|
-
var
|
|
862168
|
+
var VALID_SCOPES4 = ["session", "project", "team"];
|
|
862158
862169
|
var VALID_REVIEW_STATES3 = ["fresh", "reviewed", "stale", "contradicted"];
|
|
862159
862170
|
var VALID_PROVENANCE_KINDS = ["session", "turn", "task", "event", "file"];
|
|
862160
862171
|
var VALUE_OPTIONS = new Set([
|
|
@@ -862254,7 +862265,7 @@ function isMemoryClass2(value) {
|
|
|
862254
862265
|
return VALID_CLASSES2.includes(value);
|
|
862255
862266
|
}
|
|
862256
862267
|
function isMemoryScope2(value) {
|
|
862257
|
-
return
|
|
862268
|
+
return VALID_SCOPES4.includes(value);
|
|
862258
862269
|
}
|
|
862259
862270
|
function isReviewState(value) {
|
|
862260
862271
|
return VALID_REVIEW_STATES3.includes(value);
|
|
@@ -862269,7 +862280,7 @@ function requireClass(value) {
|
|
|
862269
862280
|
}
|
|
862270
862281
|
function requireScope(value) {
|
|
862271
862282
|
if (!value || !isMemoryScope2(value))
|
|
862272
|
-
throw new Error(`Invalid memory scope "${value ?? ""}". Valid values ${
|
|
862283
|
+
throw new Error(`Invalid memory scope "${value ?? ""}". Valid values ${VALID_SCOPES4.join(", ")}`);
|
|
862273
862284
|
return value;
|
|
862274
862285
|
}
|
|
862275
862286
|
function optionalScope(value) {
|
|
@@ -880725,6 +880736,101 @@ var AGENT_HARNESS_PARAMETER_PROPERTIES = {
|
|
|
880725
880736
|
}
|
|
880726
880737
|
};
|
|
880727
880738
|
|
|
880739
|
+
// src/input/tts-settings-actions.ts
|
|
880740
|
+
function getStreamingTtsProviders(ctx) {
|
|
880741
|
+
const registry5 = ctx.platform.voiceProviderRegistry;
|
|
880742
|
+
if (!registry5)
|
|
880743
|
+
return [];
|
|
880744
|
+
return registry5.list().filter((provider5) => provider5.capabilities.includes("tts-stream"));
|
|
880745
|
+
}
|
|
880746
|
+
function setTtsConfigValue(ctx, key, value) {
|
|
880747
|
+
ctx.platform.configManager.setDynamic(key, value);
|
|
880748
|
+
}
|
|
880749
|
+
function openTtsProviderPicker(ctx) {
|
|
880750
|
+
if (!ctx.openSelection)
|
|
880751
|
+
return false;
|
|
880752
|
+
const registry5 = ctx.platform.voiceProviderRegistry;
|
|
880753
|
+
if (!registry5) {
|
|
880754
|
+
ctx.print("Voice provider registry is not available in this runtime.");
|
|
880755
|
+
return true;
|
|
880756
|
+
}
|
|
880757
|
+
const providers2 = getStreamingTtsProviders(ctx);
|
|
880758
|
+
if (providers2.length === 0) {
|
|
880759
|
+
ctx.print("No streaming TTS providers are registered.");
|
|
880760
|
+
return true;
|
|
880761
|
+
}
|
|
880762
|
+
const current = String(ctx.platform.configManager.get("tts.provider") ?? "").trim();
|
|
880763
|
+
const items = providers2.map((provider5) => ({
|
|
880764
|
+
id: provider5.id,
|
|
880765
|
+
label: provider5.label,
|
|
880766
|
+
detail: provider5.id === current ? `${provider5.id} (current)` : provider5.id,
|
|
880767
|
+
category: "streaming TTS providers",
|
|
880768
|
+
primaryAction: "select",
|
|
880769
|
+
actions: "[Enter] set provider"
|
|
880770
|
+
}));
|
|
880771
|
+
ctx.openSelection("Choose TTS Provider", items, { preSelectId: current, allowSearch: true }, (result2) => {
|
|
880772
|
+
if (!result2)
|
|
880773
|
+
return;
|
|
880774
|
+
const previous = String(ctx.platform.configManager.get("tts.provider") ?? "").trim();
|
|
880775
|
+
setTtsConfigValue(ctx, "tts.provider", result2.item.id);
|
|
880776
|
+
if (previous && previous !== result2.item.id) {
|
|
880777
|
+
setTtsConfigValue(ctx, "tts.voice", "");
|
|
880778
|
+
ctx.print(`TTS provider set to ${result2.item.id}. TTS voice was cleared because voices are provider-specific.`);
|
|
880779
|
+
} else {
|
|
880780
|
+
ctx.print(`TTS provider set to ${result2.item.id}.`);
|
|
880781
|
+
}
|
|
880782
|
+
ctx.renderRequest();
|
|
880783
|
+
});
|
|
880784
|
+
return true;
|
|
880785
|
+
}
|
|
880786
|
+
async function openTtsVoicePicker(ctx, providerArg) {
|
|
880787
|
+
if (!ctx.openSelection)
|
|
880788
|
+
return false;
|
|
880789
|
+
const service = ctx.platform.voiceService;
|
|
880790
|
+
if (!service) {
|
|
880791
|
+
ctx.print("Voice service is not available in this runtime.");
|
|
880792
|
+
return true;
|
|
880793
|
+
}
|
|
880794
|
+
const providerId = (providerArg ?? String(ctx.platform.configManager.get("tts.provider") ?? "")).trim() || undefined;
|
|
880795
|
+
try {
|
|
880796
|
+
const voices = await service.listVoices(providerId);
|
|
880797
|
+
if (voices.length === 0) {
|
|
880798
|
+
ctx.print(providerId ? `No voices returned for ${providerId}.` : "No TTS voices returned.");
|
|
880799
|
+
return true;
|
|
880800
|
+
}
|
|
880801
|
+
const current = String(ctx.platform.configManager.get("tts.voice") ?? "").trim();
|
|
880802
|
+
const items = [
|
|
880803
|
+
{
|
|
880804
|
+
id: "__default__",
|
|
880805
|
+
label: "Use provider default voice",
|
|
880806
|
+
detail: current ? "clears tts.voice" : "(current)",
|
|
880807
|
+
category: "voice",
|
|
880808
|
+
primaryAction: "select"
|
|
880809
|
+
},
|
|
880810
|
+
...voices.map((voice) => ({
|
|
880811
|
+
id: voice.id,
|
|
880812
|
+
label: voice.label || voice.id,
|
|
880813
|
+
detail: voice.id === current ? `${voice.id} (current)` : voice.id,
|
|
880814
|
+
category: providerId ?? "voices",
|
|
880815
|
+
primaryAction: "select",
|
|
880816
|
+
actions: "[Enter] set voice"
|
|
880817
|
+
}))
|
|
880818
|
+
];
|
|
880819
|
+
ctx.openSelection(`Choose TTS Voice${providerId ? ` (${providerId})` : ""}`, items, { preSelectId: current || "__default__", allowSearch: true }, (result2) => {
|
|
880820
|
+
if (!result2)
|
|
880821
|
+
return;
|
|
880822
|
+
const nextVoice = result2.item.id === "__default__" ? "" : result2.item.id;
|
|
880823
|
+
setTtsConfigValue(ctx, "tts.voice", nextVoice);
|
|
880824
|
+
ctx.print(nextVoice ? `TTS voice set to ${nextVoice}.` : "TTS voice cleared. The provider default voice will be used.");
|
|
880825
|
+
ctx.renderRequest();
|
|
880826
|
+
});
|
|
880827
|
+
return true;
|
|
880828
|
+
} catch (error52) {
|
|
880829
|
+
ctx.print(`Unable to list TTS voices: ${error52 instanceof Error ? error52.message : String(error52)}`);
|
|
880830
|
+
return true;
|
|
880831
|
+
}
|
|
880832
|
+
}
|
|
880833
|
+
|
|
880728
880834
|
// src/tools/agent-harness-ui-surface-metadata.ts
|
|
880729
880835
|
function readString56(value) {
|
|
880730
880836
|
return typeof value === "string" ? value.trim() : "";
|
|
@@ -880765,6 +880871,40 @@ function workspaceCategory(args2) {
|
|
|
880765
880871
|
function settingsTarget(args2) {
|
|
880766
880872
|
return readString56(args2.target || args2.key || args2.prefix) || undefined;
|
|
880767
880873
|
}
|
|
880874
|
+
function providerTarget(args2) {
|
|
880875
|
+
return readString56(args2.target || args2.key || args2.prefix) || undefined;
|
|
880876
|
+
}
|
|
880877
|
+
function optionalPane(args2) {
|
|
880878
|
+
const pane = readString56(args2.pane);
|
|
880879
|
+
return pane === "top" || pane === "bottom" ? pane : undefined;
|
|
880880
|
+
}
|
|
880881
|
+
function openAgentWorkspaceCategory(context, surface, categoryId, extra = {}) {
|
|
880882
|
+
if (!context.openAgentWorkspace)
|
|
880883
|
+
return routeUnavailable(surface);
|
|
880884
|
+
context.openAgentWorkspace(categoryId);
|
|
880885
|
+
return opened(surface, { categoryId, ...extra });
|
|
880886
|
+
}
|
|
880887
|
+
function openPanelWorkspaceSurface(context, args2, surface, options) {
|
|
880888
|
+
if (context.openAgentWorkspace) {
|
|
880889
|
+
context.openAgentWorkspace(options.categoryId);
|
|
880890
|
+
return opened(surface, { categoryId: options.categoryId, panelId: options.panelId });
|
|
880891
|
+
}
|
|
880892
|
+
if (options.opener) {
|
|
880893
|
+
options.opener();
|
|
880894
|
+
return opened(surface, { categoryId: options.categoryId, panelId: options.panelId, route: "named-opener" });
|
|
880895
|
+
}
|
|
880896
|
+
if (context.showPanel) {
|
|
880897
|
+
const pane = optionalPane(args2);
|
|
880898
|
+
context.showPanel(options.panelId, pane);
|
|
880899
|
+
return opened(surface, {
|
|
880900
|
+
categoryId: options.categoryId,
|
|
880901
|
+
panelId: options.panelId,
|
|
880902
|
+
pane: pane ?? "default",
|
|
880903
|
+
route: "panel-bridge"
|
|
880904
|
+
});
|
|
880905
|
+
}
|
|
880906
|
+
return routeUnavailable(surface);
|
|
880907
|
+
}
|
|
880768
880908
|
var UI_SURFACES = [
|
|
880769
880909
|
{
|
|
880770
880910
|
id: "agent-workspace",
|
|
@@ -880784,6 +880924,77 @@ var UI_SURFACES = [
|
|
|
880784
880924
|
return opened(surface, { categoryId: categoryId ?? "default" });
|
|
880785
880925
|
}
|
|
880786
880926
|
},
|
|
880927
|
+
{
|
|
880928
|
+
id: "panel-picker",
|
|
880929
|
+
label: "Panel Picker",
|
|
880930
|
+
kind: "picker",
|
|
880931
|
+
summary: "Keyboard-accessible operator panel route that now opens the Agent Workspace home surface.",
|
|
880932
|
+
command: "Ctrl+P",
|
|
880933
|
+
preferredModelRoute: "Use panels/panel/open_panel for panel catalog and routing, or workspace_actions for concrete model operation.",
|
|
880934
|
+
available: (context) => typeof context.openPanelPicker === "function" || typeof context.openAgentWorkspace === "function",
|
|
880935
|
+
open: (context) => {
|
|
880936
|
+
const surface = findSurfaceById("panel-picker");
|
|
880937
|
+
if (context.openPanelPicker) {
|
|
880938
|
+
context.openPanelPicker();
|
|
880939
|
+
return opened(surface, { categoryId: "home", route: "panel-picker" });
|
|
880940
|
+
}
|
|
880941
|
+
return openAgentWorkspaceCategory(context, surface, "home");
|
|
880942
|
+
}
|
|
880943
|
+
},
|
|
880944
|
+
{
|
|
880945
|
+
id: "security-panel",
|
|
880946
|
+
label: "Security Panel",
|
|
880947
|
+
kind: "workspace",
|
|
880948
|
+
summary: "Security review operator surface for token posture, MCP attack paths, policy posture, and plugin risk.",
|
|
880949
|
+
command: "/security",
|
|
880950
|
+
preferredModelRoute: "Use workspace_actions for security review actions or run_command /security review for compact read-only output.",
|
|
880951
|
+
parameters: ["pane"],
|
|
880952
|
+
available: (context) => typeof context.openAgentWorkspace === "function" || typeof context.openSecurityPanel === "function" || typeof context.showPanel === "function",
|
|
880953
|
+
open: (context, args2) => {
|
|
880954
|
+
const surface = findSurfaceById("security-panel");
|
|
880955
|
+
return openPanelWorkspaceSurface(context, args2, surface, {
|
|
880956
|
+
panelId: "security",
|
|
880957
|
+
categoryId: "tools",
|
|
880958
|
+
opener: context.openSecurityPanel
|
|
880959
|
+
});
|
|
880960
|
+
}
|
|
880961
|
+
},
|
|
880962
|
+
{
|
|
880963
|
+
id: "knowledge-panel",
|
|
880964
|
+
label: "Knowledge Panel",
|
|
880965
|
+
kind: "workspace",
|
|
880966
|
+
summary: "Agent Knowledge operator surface for isolated status, source libraries, graph review, ask/search, and ingest forms.",
|
|
880967
|
+
command: "/knowledge",
|
|
880968
|
+
preferredModelRoute: "Use agent_knowledge, agent_knowledge_ingest, workspace_actions, or run_command /knowledge for concrete model operation.",
|
|
880969
|
+
parameters: ["pane"],
|
|
880970
|
+
available: (context) => typeof context.openAgentWorkspace === "function" || typeof context.openKnowledgePanel === "function" || typeof context.showPanel === "function",
|
|
880971
|
+
open: (context, args2) => {
|
|
880972
|
+
const surface = findSurfaceById("knowledge-panel");
|
|
880973
|
+
return openPanelWorkspaceSurface(context, args2, surface, {
|
|
880974
|
+
panelId: "knowledge",
|
|
880975
|
+
categoryId: "knowledge",
|
|
880976
|
+
opener: context.openKnowledgePanel
|
|
880977
|
+
});
|
|
880978
|
+
}
|
|
880979
|
+
},
|
|
880980
|
+
{
|
|
880981
|
+
id: "subscription-panel",
|
|
880982
|
+
label: "Subscription Panel",
|
|
880983
|
+
kind: "workspace",
|
|
880984
|
+
summary: "Provider subscription operator surface for subscription review, provider inspection, login, logout, and bundle flows.",
|
|
880985
|
+
command: "/subscription",
|
|
880986
|
+
preferredModelRoute: "Use workspace_actions or confirmed run_command /subscription mirrors for concrete subscription operation.",
|
|
880987
|
+
parameters: ["pane"],
|
|
880988
|
+
available: (context) => typeof context.openAgentWorkspace === "function" || typeof context.openSubscriptionPanel === "function" || typeof context.showPanel === "function",
|
|
880989
|
+
open: (context, args2) => {
|
|
880990
|
+
const surface = findSurfaceById("subscription-panel");
|
|
880991
|
+
return openPanelWorkspaceSurface(context, args2, surface, {
|
|
880992
|
+
panelId: "subscription",
|
|
880993
|
+
categoryId: "setup",
|
|
880994
|
+
opener: context.openSubscriptionPanel
|
|
880995
|
+
});
|
|
880996
|
+
}
|
|
880997
|
+
},
|
|
880787
880998
|
{
|
|
880788
880999
|
id: "settings",
|
|
880789
881000
|
label: "Settings",
|
|
@@ -880862,6 +881073,40 @@ var UI_SURFACES = [
|
|
|
880862
881073
|
return opened(surface, { target: "main" });
|
|
880863
881074
|
}
|
|
880864
881075
|
},
|
|
881076
|
+
{
|
|
881077
|
+
id: "tts-provider-picker",
|
|
881078
|
+
label: "TTS Provider Picker",
|
|
881079
|
+
kind: "picker",
|
|
881080
|
+
summary: "Interactive streaming TTS provider picker opened from the Agent settings flow.",
|
|
881081
|
+
command: "/config tts.provider",
|
|
881082
|
+
preferredModelRoute: "Use settings/get_setting/set_setting for tts.provider when a concrete provider id is known; use open_ui_surface only to visibly navigate.",
|
|
881083
|
+
available: (context) => typeof context.openSelection === "function" && Boolean(context.platform.voiceProviderRegistry),
|
|
881084
|
+
open: (context) => {
|
|
881085
|
+
const surface = findSurfaceById("tts-provider-picker");
|
|
881086
|
+
if (!context.openSelection || !context.platform.voiceProviderRegistry)
|
|
881087
|
+
return routeUnavailable(surface);
|
|
881088
|
+
const handled = openTtsProviderPicker(context);
|
|
881089
|
+
return handled ? opened(surface, { target: "tts.provider" }) : routeUnavailable(surface);
|
|
881090
|
+
}
|
|
881091
|
+
},
|
|
881092
|
+
{
|
|
881093
|
+
id: "tts-voice-picker",
|
|
881094
|
+
label: "TTS Voice Picker",
|
|
881095
|
+
kind: "picker",
|
|
881096
|
+
summary: "Interactive TTS voice picker opened from the Agent settings flow for the selected or supplied provider.",
|
|
881097
|
+
command: "/config tts.voice",
|
|
881098
|
+
preferredModelRoute: "Use settings/get_setting/set_setting/reset_setting for tts.voice when a concrete voice id is known; use open_ui_surface only to visibly navigate.",
|
|
881099
|
+
parameters: ["target"],
|
|
881100
|
+
available: (context) => typeof context.openSelection === "function" && Boolean(context.platform.voiceService),
|
|
881101
|
+
open: async (context, args2) => {
|
|
881102
|
+
const surface = findSurfaceById("tts-voice-picker");
|
|
881103
|
+
if (!context.openSelection || !context.platform.voiceService)
|
|
881104
|
+
return routeUnavailable(surface);
|
|
881105
|
+
const providerId = providerTarget(args2);
|
|
881106
|
+
const handled = await openTtsVoicePicker(context, providerId);
|
|
881107
|
+
return handled ? opened(surface, { target: "tts.voice", providerId: providerId ?? "configured-default" }) : routeUnavailable(surface);
|
|
881108
|
+
}
|
|
881109
|
+
},
|
|
880865
881110
|
{
|
|
880866
881111
|
id: "session-picker",
|
|
880867
881112
|
label: "Session Picker",
|
|
@@ -881025,7 +881270,7 @@ function describeHarnessUiSurface(context, args2) {
|
|
|
881025
881270
|
const surface = UI_SURFACES.find((entry) => entry.id === surfaceId || entry.label.toLowerCase() === surfaceId.toLowerCase());
|
|
881026
881271
|
return surface ? describeSurface(context, surface) : null;
|
|
881027
881272
|
}
|
|
881028
|
-
function openHarnessUiSurface(context, args2) {
|
|
881273
|
+
async function openHarnessUiSurface(context, args2) {
|
|
881029
881274
|
const surfaceId = readString56(args2.surfaceId || args2.query);
|
|
881030
881275
|
const surface = UI_SURFACES.find((entry) => entry.id === surfaceId || entry.label.toLowerCase() === surfaceId.toLowerCase());
|
|
881031
881276
|
if (!surface) {
|
|
@@ -881035,8 +881280,9 @@ function openHarnessUiSurface(context, args2) {
|
|
|
881035
881280
|
availableSurfaces: UI_SURFACES.map((entry) => entry.id)
|
|
881036
881281
|
};
|
|
881037
881282
|
}
|
|
881283
|
+
const routed = await surface.open(context, args2);
|
|
881038
881284
|
return {
|
|
881039
|
-
...
|
|
881285
|
+
...routed,
|
|
881040
881286
|
descriptor: describeSurface(context, surface)
|
|
881041
881287
|
};
|
|
881042
881288
|
}
|
|
@@ -881519,7 +881765,7 @@ function createAgentHarnessTool(deps) {
|
|
|
881519
881765
|
const confirmationError2 = requireConfirmedAction(args2, "UI surface routing");
|
|
881520
881766
|
if (confirmationError2)
|
|
881521
881767
|
return error52(confirmationError2);
|
|
881522
|
-
return output7(openHarnessUiSurface(deps.commandContext, args2));
|
|
881768
|
+
return output7(await openHarnessUiSurface(deps.commandContext, args2));
|
|
881523
881769
|
}
|
|
881524
881770
|
if (args2.mode === "shortcuts")
|
|
881525
881771
|
return output7(listHarnessShortcuts(deps.commandContext, args2));
|
|
@@ -883220,7 +883466,7 @@ var invokeContractRoute2 = exports_transport.invokeContractRoute;
|
|
|
883220
883466
|
var openContractRouteStream2 = exports_transport.openContractRouteStream;
|
|
883221
883467
|
var requireContractRoute2 = exports_transport.requireContractRoute;
|
|
883222
883468
|
var isAbortError6 = exports_transport.isAbortError;
|
|
883223
|
-
var
|
|
883469
|
+
var openServerSentEventStream2 = exports_transport.openServerSentEventStream;
|
|
883224
883470
|
var createOperatorRemoteClient2 = exports_transport.createOperatorRemoteClient;
|
|
883225
883471
|
var createPeerRemoteClient2 = exports_transport.createPeerRemoteClient;
|
|
883226
883472
|
var buildEventSourceUrl2 = exports_transport.buildEventSourceUrl;
|
|
@@ -893394,101 +893640,6 @@ function handleOnboardingWizardToken(state4, token) {
|
|
|
893394
893640
|
return true;
|
|
893395
893641
|
}
|
|
893396
893642
|
|
|
893397
|
-
// src/input/tts-settings-actions.ts
|
|
893398
|
-
function getStreamingTtsProviders(ctx) {
|
|
893399
|
-
const registry5 = ctx.platform.voiceProviderRegistry;
|
|
893400
|
-
if (!registry5)
|
|
893401
|
-
return [];
|
|
893402
|
-
return registry5.list().filter((provider5) => provider5.capabilities.includes("tts-stream"));
|
|
893403
|
-
}
|
|
893404
|
-
function setTtsConfigValue(ctx, key, value) {
|
|
893405
|
-
ctx.platform.configManager.setDynamic(key, value);
|
|
893406
|
-
}
|
|
893407
|
-
function openTtsProviderPicker(ctx) {
|
|
893408
|
-
if (!ctx.openSelection)
|
|
893409
|
-
return false;
|
|
893410
|
-
const registry5 = ctx.platform.voiceProviderRegistry;
|
|
893411
|
-
if (!registry5) {
|
|
893412
|
-
ctx.print("Voice provider registry is not available in this runtime.");
|
|
893413
|
-
return true;
|
|
893414
|
-
}
|
|
893415
|
-
const providers2 = getStreamingTtsProviders(ctx);
|
|
893416
|
-
if (providers2.length === 0) {
|
|
893417
|
-
ctx.print("No streaming TTS providers are registered.");
|
|
893418
|
-
return true;
|
|
893419
|
-
}
|
|
893420
|
-
const current = String(ctx.platform.configManager.get("tts.provider") ?? "").trim();
|
|
893421
|
-
const items = providers2.map((provider5) => ({
|
|
893422
|
-
id: provider5.id,
|
|
893423
|
-
label: provider5.label,
|
|
893424
|
-
detail: provider5.id === current ? `${provider5.id} (current)` : provider5.id,
|
|
893425
|
-
category: "streaming TTS providers",
|
|
893426
|
-
primaryAction: "select",
|
|
893427
|
-
actions: "[Enter] set provider"
|
|
893428
|
-
}));
|
|
893429
|
-
ctx.openSelection("Choose TTS Provider", items, { preSelectId: current, allowSearch: true }, (result2) => {
|
|
893430
|
-
if (!result2)
|
|
893431
|
-
return;
|
|
893432
|
-
const previous = String(ctx.platform.configManager.get("tts.provider") ?? "").trim();
|
|
893433
|
-
setTtsConfigValue(ctx, "tts.provider", result2.item.id);
|
|
893434
|
-
if (previous && previous !== result2.item.id) {
|
|
893435
|
-
setTtsConfigValue(ctx, "tts.voice", "");
|
|
893436
|
-
ctx.print(`TTS provider set to ${result2.item.id}. TTS voice was cleared because voices are provider-specific.`);
|
|
893437
|
-
} else {
|
|
893438
|
-
ctx.print(`TTS provider set to ${result2.item.id}.`);
|
|
893439
|
-
}
|
|
893440
|
-
ctx.renderRequest();
|
|
893441
|
-
});
|
|
893442
|
-
return true;
|
|
893443
|
-
}
|
|
893444
|
-
async function openTtsVoicePicker(ctx, providerArg) {
|
|
893445
|
-
if (!ctx.openSelection)
|
|
893446
|
-
return false;
|
|
893447
|
-
const service = ctx.platform.voiceService;
|
|
893448
|
-
if (!service) {
|
|
893449
|
-
ctx.print("Voice service is not available in this runtime.");
|
|
893450
|
-
return true;
|
|
893451
|
-
}
|
|
893452
|
-
const providerId = (providerArg ?? String(ctx.platform.configManager.get("tts.provider") ?? "")).trim() || undefined;
|
|
893453
|
-
try {
|
|
893454
|
-
const voices = await service.listVoices(providerId);
|
|
893455
|
-
if (voices.length === 0) {
|
|
893456
|
-
ctx.print(providerId ? `No voices returned for ${providerId}.` : "No TTS voices returned.");
|
|
893457
|
-
return true;
|
|
893458
|
-
}
|
|
893459
|
-
const current = String(ctx.platform.configManager.get("tts.voice") ?? "").trim();
|
|
893460
|
-
const items = [
|
|
893461
|
-
{
|
|
893462
|
-
id: "__default__",
|
|
893463
|
-
label: "Use provider default voice",
|
|
893464
|
-
detail: current ? "clears tts.voice" : "(current)",
|
|
893465
|
-
category: "voice",
|
|
893466
|
-
primaryAction: "select"
|
|
893467
|
-
},
|
|
893468
|
-
...voices.map((voice) => ({
|
|
893469
|
-
id: voice.id,
|
|
893470
|
-
label: voice.label || voice.id,
|
|
893471
|
-
detail: voice.id === current ? `${voice.id} (current)` : voice.id,
|
|
893472
|
-
category: providerId ?? "voices",
|
|
893473
|
-
primaryAction: "select",
|
|
893474
|
-
actions: "[Enter] set voice"
|
|
893475
|
-
}))
|
|
893476
|
-
];
|
|
893477
|
-
ctx.openSelection(`Choose TTS Voice${providerId ? ` (${providerId})` : ""}`, items, { preSelectId: current || "__default__", allowSearch: true }, (result2) => {
|
|
893478
|
-
if (!result2)
|
|
893479
|
-
return;
|
|
893480
|
-
const nextVoice = result2.item.id === "__default__" ? "" : result2.item.id;
|
|
893481
|
-
setTtsConfigValue(ctx, "tts.voice", nextVoice);
|
|
893482
|
-
ctx.print(nextVoice ? `TTS voice set to ${nextVoice}.` : "TTS voice cleared. The provider default voice will be used.");
|
|
893483
|
-
ctx.renderRequest();
|
|
893484
|
-
});
|
|
893485
|
-
return true;
|
|
893486
|
-
} catch (error53) {
|
|
893487
|
-
ctx.print(`Unable to list TTS voices: ${error53 instanceof Error ? error53.message : String(error53)}`);
|
|
893488
|
-
return true;
|
|
893489
|
-
}
|
|
893490
|
-
}
|
|
893491
|
-
|
|
893492
893643
|
// src/input/handler-modal-routes.ts
|
|
893493
893644
|
function handleSelectionModalToken(state4, token) {
|
|
893494
893645
|
if (!state4.selectionModal.active)
|