@aibolabs/plugin-protocol 0.1.8 → 0.1.11
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/dist/capability.d.ts
CHANGED
|
@@ -24,10 +24,12 @@ export type CapabilityResult = {
|
|
|
24
24
|
generationId: string;
|
|
25
25
|
output: JsonValue;
|
|
26
26
|
};
|
|
27
|
+
/** Native host display metadata is optional; runtime dependency replies retain their protocol shape. */
|
|
27
28
|
export type CapabilityFailure = {
|
|
28
29
|
code: string;
|
|
29
30
|
message: string;
|
|
30
31
|
invocationId: string | null;
|
|
32
|
+
localized?: JsonValue;
|
|
31
33
|
};
|
|
32
34
|
export type CapabilityOperation = {
|
|
33
35
|
capability: string;
|
package/dist/index.d.ts
CHANGED
|
@@ -14,3 +14,5 @@ export type { PresentationInspector, PresentationInspectorAction, PresentationAr
|
|
|
14
14
|
export type { PresentationCapabilityWorkbench, PresentationCapabilityView, PresentationCapabilityAction, PresentationCapabilityContribution, PresentationCapabilityScope } from './presentation-capability.js';
|
|
15
15
|
export type { PresentationLayout, PresentationLayoutAction } from './presentation-layout.js';
|
|
16
16
|
export type { AgentSettingValue, AgentSettingField, AgentSettingsDescriptor, AgentSettingsTarget, AgentSettingsSnapshot, AgentSettingsSave, AgentSettingsContext } from './settings.js';
|
|
17
|
+
export type { SidebarTarget, SidebarTab, SidebarPane, SidebarLayout, SidebarOperation, PresentationSidebar, PresentationSidebarAction } from './presentation-layout.js';
|
|
18
|
+
export type { ToolViewContribution, ToolViewBackendRequest, ToolViewBackendResponse, ToolViewInitialize, ToolViewStatus } from './tool-view.js';
|
|
@@ -117,6 +117,8 @@ interface ContextAttachment {
|
|
|
117
117
|
sessionId: string;
|
|
118
118
|
turnId: string | null;
|
|
119
119
|
path: string;
|
|
120
|
+
/** Optional host-formatted name; path and identity retain their original values. */
|
|
121
|
+
displayName?: string;
|
|
120
122
|
contentHash: string | null;
|
|
121
123
|
size: number | null;
|
|
122
124
|
mediaType: string;
|
|
@@ -231,6 +233,15 @@ export type PresentationConversation = {
|
|
|
231
233
|
id: string;
|
|
232
234
|
label: string | null;
|
|
233
235
|
usedPercent: number;
|
|
236
|
+
observedAt?: number;
|
|
237
|
+
windowMinutes: number | null;
|
|
238
|
+
resetsAt: number | null;
|
|
239
|
+
}[];
|
|
240
|
+
/** Expired observations, separate so older renderers never coerce unknown to 100% remaining. */
|
|
241
|
+
unknownLimits?: {
|
|
242
|
+
id: string;
|
|
243
|
+
label: string | null;
|
|
244
|
+
observedAt?: number;
|
|
234
245
|
windowMinutes: number | null;
|
|
235
246
|
resetsAt: number | null;
|
|
236
247
|
}[];
|
|
@@ -19,3 +19,73 @@ export type PresentationLayoutAction = {
|
|
|
19
19
|
event: 'input' | 'click';
|
|
20
20
|
args: readonly ('navigation' | 'auxiliary' | 'standard' | 'focus' | 'review')[];
|
|
21
21
|
};
|
|
22
|
+
/** Serializable layout only; plugin leases and file data never enter storage. */
|
|
23
|
+
export type SidebarTarget = {
|
|
24
|
+
kind: 'git' | 'context';
|
|
25
|
+
} | {
|
|
26
|
+
kind: 'plugin';
|
|
27
|
+
installationId: string;
|
|
28
|
+
contributionId: string;
|
|
29
|
+
};
|
|
30
|
+
export type SidebarTab = {
|
|
31
|
+
id: string;
|
|
32
|
+
target: SidebarTarget;
|
|
33
|
+
};
|
|
34
|
+
export type SidebarPane = {
|
|
35
|
+
id: string;
|
|
36
|
+
tabs: string[];
|
|
37
|
+
active: string | null;
|
|
38
|
+
floating: boolean;
|
|
39
|
+
x: number;
|
|
40
|
+
y: number;
|
|
41
|
+
width: number;
|
|
42
|
+
height: number;
|
|
43
|
+
};
|
|
44
|
+
export type SidebarLayout = {
|
|
45
|
+
tabs: SidebarTab[];
|
|
46
|
+
panes: SidebarPane[];
|
|
47
|
+
activePane: string;
|
|
48
|
+
};
|
|
49
|
+
export type SidebarOperation = {
|
|
50
|
+
kind: 'open';
|
|
51
|
+
target: SidebarTarget;
|
|
52
|
+
paneId?: string;
|
|
53
|
+
} | {
|
|
54
|
+
kind: 'focus' | 'close';
|
|
55
|
+
tabId: string;
|
|
56
|
+
} | {
|
|
57
|
+
kind: 'reorder';
|
|
58
|
+
tabId: string;
|
|
59
|
+
before?: string;
|
|
60
|
+
} | {
|
|
61
|
+
kind: 'move';
|
|
62
|
+
tabId: string;
|
|
63
|
+
paneId: string;
|
|
64
|
+
before?: string;
|
|
65
|
+
} | {
|
|
66
|
+
kind: 'split' | 'float' | 'dock';
|
|
67
|
+
tabId: string;
|
|
68
|
+
} | {
|
|
69
|
+
kind: 'bounds';
|
|
70
|
+
paneId: string;
|
|
71
|
+
x: number;
|
|
72
|
+
y: number;
|
|
73
|
+
width: number;
|
|
74
|
+
height: number;
|
|
75
|
+
};
|
|
76
|
+
export type PresentationSidebar = {
|
|
77
|
+
layout: SidebarLayout;
|
|
78
|
+
titles: Record<string, string>;
|
|
79
|
+
entries: {
|
|
80
|
+
label: string;
|
|
81
|
+
value: string;
|
|
82
|
+
disabled?: boolean;
|
|
83
|
+
}[];
|
|
84
|
+
views: Record<string, import('./presentation-capability.js').PresentationCapabilityView>;
|
|
85
|
+
};
|
|
86
|
+
export type PresentationSidebarAction = {
|
|
87
|
+
token: string;
|
|
88
|
+
operation: 'layout' | 'reload' | 'reading' | 'semantic';
|
|
89
|
+
event: 'click';
|
|
90
|
+
args: readonly (string | null)[];
|
|
91
|
+
};
|
|
@@ -45,6 +45,8 @@ export type PresentationContext = {
|
|
|
45
45
|
revision: number;
|
|
46
46
|
};
|
|
47
47
|
export type PresentationInput = {
|
|
48
|
+
/** Display language only; absent in legacy hosts (Chinese). Does not grant authority. */
|
|
49
|
+
locale?: 'zh-CN' | 'en';
|
|
48
50
|
surface: 'controls' | 'semantic' | 'workbench';
|
|
49
51
|
context: PresentationContext;
|
|
50
52
|
data: JsonValue;
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/** Independent tool applications; not a Presentation Worker or Agent capability. */
|
|
2
|
+
export type ToolViewContribution = {
|
|
3
|
+
kind: 'toolView';
|
|
4
|
+
id: string;
|
|
5
|
+
scope: 'workspace';
|
|
6
|
+
required: true;
|
|
7
|
+
title: string;
|
|
8
|
+
contractVersion: '1.0.0';
|
|
9
|
+
frontend: string;
|
|
10
|
+
backend: string;
|
|
11
|
+
permissions: ['local.process'];
|
|
12
|
+
};
|
|
13
|
+
export type ToolViewBackendRequest = {
|
|
14
|
+
protocol: 'aibo.tool-view/1';
|
|
15
|
+
method: 'initialize' | 'request' | 'status' | 'shutdown';
|
|
16
|
+
params: unknown;
|
|
17
|
+
};
|
|
18
|
+
export type ToolViewBackendResponse = {
|
|
19
|
+
protocol: 'aibo.tool-view/1';
|
|
20
|
+
} & ({
|
|
21
|
+
result: unknown;
|
|
22
|
+
} | {
|
|
23
|
+
error: string;
|
|
24
|
+
});
|
|
25
|
+
export type ToolViewInitialize = {
|
|
26
|
+
workspacePath: string;
|
|
27
|
+
workspaceId: string;
|
|
28
|
+
windowId: string;
|
|
29
|
+
};
|
|
30
|
+
export type ToolViewStatus = {
|
|
31
|
+
active: number;
|
|
32
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|