@f5-sales-demo/pi-agent-core 23.6.9 → 23.8.0
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/package.json +3 -3
- package/src/plugin-presentation.ts +18 -3
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"type": "module",
|
|
3
3
|
"name": "@f5-sales-demo/pi-agent-core",
|
|
4
|
-
"version": "23.
|
|
4
|
+
"version": "23.8.0",
|
|
5
5
|
"description": "General-purpose agent with transport abstraction, state management, and attachment support",
|
|
6
6
|
"homepage": "https://github.com/f5-sales-demo/xcsh",
|
|
7
7
|
"author": "Can Boluk",
|
|
@@ -35,8 +35,8 @@
|
|
|
35
35
|
"fmt": "biome format --write ."
|
|
36
36
|
},
|
|
37
37
|
"dependencies": {
|
|
38
|
-
"@f5-sales-demo/pi-ai": "23.
|
|
39
|
-
"@f5-sales-demo/pi-utils": "23.
|
|
38
|
+
"@f5-sales-demo/pi-ai": "23.8.0",
|
|
39
|
+
"@f5-sales-demo/pi-utils": "23.8.0"
|
|
40
40
|
},
|
|
41
41
|
"devDependencies": {
|
|
42
42
|
"@sinclair/typebox": "0.34.52",
|
|
@@ -1,16 +1,28 @@
|
|
|
1
1
|
/** Data-only presentation contract. Plugins do not import a renderer at runtime. */
|
|
2
2
|
export type PluginSection =
|
|
3
|
-
| { kind: "fields"; title?: string; values: Readonly<Record<string, unknown
|
|
3
|
+
| { kind: "fields"; title?: string; values: Readonly<Record<string, unknown>>; previewFields?: number | "all" }
|
|
4
4
|
| {
|
|
5
5
|
kind: "table";
|
|
6
6
|
title?: string;
|
|
7
|
-
columns: readonly {
|
|
7
|
+
columns: readonly {
|
|
8
|
+
key: string;
|
|
9
|
+
label?: string;
|
|
10
|
+
align?: "left" | "right";
|
|
11
|
+
minWidth?: number;
|
|
12
|
+
maxWidth?: number;
|
|
13
|
+
}[];
|
|
8
14
|
rows: readonly Readonly<Record<string, unknown>>[];
|
|
15
|
+
/** Complete rows in the collapsed preview; defaults to three. */
|
|
16
|
+
previewRows?: number;
|
|
9
17
|
}
|
|
10
18
|
| { kind: "markdown"; title?: string; text: string }
|
|
11
|
-
| { kind: "code"; title?: string; text: string; language?: string };
|
|
19
|
+
| { kind: "code"; title?: string; text: string; language?: string; argv?: readonly string[] };
|
|
12
20
|
|
|
13
21
|
export interface PluginView {
|
|
22
|
+
/** Append automatic expanded evidence by default; provided adapters include complete safe evidence. */
|
|
23
|
+
expandedEvidence?: "append" | "provided";
|
|
24
|
+
/** Automatic streaming/pagination warnings by default; provided adapters explain completion. */
|
|
25
|
+
completeness?: "automatic" | "provided";
|
|
14
26
|
summary?: string;
|
|
15
27
|
warnings?: readonly string[];
|
|
16
28
|
sections?: readonly PluginSection[];
|
|
@@ -18,6 +30,9 @@ export interface PluginView {
|
|
|
18
30
|
export interface PluginPresentationOptions {
|
|
19
31
|
readonly expanded: boolean;
|
|
20
32
|
readonly isPartial: boolean;
|
|
33
|
+
/** Available inner columns, resolved on every render. */
|
|
34
|
+
readonly width?: number;
|
|
35
|
+
readonly spinnerFrame?: number;
|
|
21
36
|
}
|
|
22
37
|
export interface PluginPresentation<TArgs = unknown, TResult = unknown> {
|
|
23
38
|
call?: (args: TArgs, options: PluginPresentationOptions) => PluginView | undefined;
|