@f5-sales-demo/xcsh 19.52.0 → 19.53.1

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "type": "module",
3
3
  "name": "@f5-sales-demo/xcsh",
4
- "version": "19.52.0",
4
+ "version": "19.53.1",
5
5
  "description": "Coding agent CLI with read, bash, edit, write tools and session management",
6
6
  "homepage": "https://github.com/f5-sales-demo/xcsh",
7
7
  "author": "Can Boluk",
@@ -55,13 +55,13 @@
55
55
  "dependencies": {
56
56
  "@agentclientprotocol/sdk": "0.16.1",
57
57
  "@mozilla/readability": "^0.6",
58
- "@f5-sales-demo/xcsh-stats": "19.52.0",
59
- "@f5-sales-demo/pi-agent-core": "19.52.0",
60
- "@f5-sales-demo/pi-ai": "19.52.0",
61
- "@f5-sales-demo/pi-natives": "19.52.0",
62
- "@f5-sales-demo/pi-resource-management": "19.52.0",
63
- "@f5-sales-demo/pi-tui": "19.52.0",
64
- "@f5-sales-demo/pi-utils": "19.52.0",
58
+ "@f5-sales-demo/xcsh-stats": "19.53.1",
59
+ "@f5-sales-demo/pi-agent-core": "19.53.1",
60
+ "@f5-sales-demo/pi-ai": "19.53.1",
61
+ "@f5-sales-demo/pi-natives": "19.53.1",
62
+ "@f5-sales-demo/pi-resource-management": "19.53.1",
63
+ "@f5-sales-demo/pi-tui": "19.53.1",
64
+ "@f5-sales-demo/pi-utils": "19.53.1",
65
65
  "@sinclair/typebox": "^0.34",
66
66
  "@xterm/headless": "^6.0",
67
67
  "ajv": "^8.20",
@@ -25,7 +25,7 @@ export interface ExtensionCapabilities {
25
25
 
26
26
  export const EXTENSION_CAPABILITIES: ExtensionCapabilities = {
27
27
  "version": "0.1.0",
28
- "contractVersion": "1.0.0",
28
+ "contractVersion": "1.2.0",
29
29
  "protocol": "tool_request/result",
30
30
  "tools": [
31
31
  {
@@ -584,6 +584,18 @@ export const EXTENSION_CAPABILITIES: ExtensionCapabilities = {
584
584
  "readOnly": true
585
585
  }
586
586
  },
587
+ {
588
+ "name": "get_page_context",
589
+ "summary": "Return a snapshot of the active console page (url, AX tree, captured XC API body) for chat grounding.",
590
+ "category": "read",
591
+ "params": {
592
+ "type": "object",
593
+ "properties": {}
594
+ },
595
+ "flags": {
596
+ "readOnly": true
597
+ }
598
+ },
587
599
  {
588
600
  "name": "javascript_tool",
589
601
  "summary": "Evaluate arbitrary JS in the page (length-capped).",
@@ -706,10 +718,30 @@ export const EXTENSION_CAPABILITIES: ExtensionCapabilities = {
706
718
  "viewport": {
707
719
  "tool": "resize_window",
708
720
  "description": "Control the browser window size."
721
+ },
722
+ "chat": {
723
+ "contextTool": "get_page_context",
724
+ "transport": "websocket-bridge",
725
+ "modes": [
726
+ "educational",
727
+ "presentation",
728
+ "configuration",
729
+ "screenshot",
730
+ "annotation"
731
+ ],
732
+ "messages": [
733
+ "chat_request",
734
+ "chat_delta",
735
+ "chat_done",
736
+ "chat_error",
737
+ "chat_stop",
738
+ "chat_tool_notice"
739
+ ],
740
+ "description": "User ↔ xcsh chat over the bridge. The extension side panel sends chat_request (with mode and page-context snapshot); xcsh streams chat_delta tokens then a terminal chat_done (with reference links) or chat_error. Chat ids are prefixed \"c-\". Tool calls during a turn use the normal tool_request flow. chat_stop halts a streaming response. chat_tool_notice is emitted by the EXTENSION (the service worker) to the panel as a best-effort UI signal when a tool runs during a turn — it is NOT sent by xcsh; xcsh must not produce it to avoid double-rendering in the panel."
709
741
  }
710
742
  }
711
743
  };
712
744
 
713
- export const EXTENSION_CONTRACT_VERSION = "1.0.0";
745
+ export const EXTENSION_CONTRACT_VERSION = "1.2.0";
714
746
 
715
- export const EXTENSION_TOOL_NAMES: readonly string[] = ["ping","capabilities","reload","debug_exec","detach","navigate","login","scroll_to","resize_window","tabs_list","tabs_create","tabs_close","click","click_element","click_xy","type_text","form_input","key_press","select_option","label_select","file_upload","read_ax","get_page_text","find","wait_for","assert_text","screenshot","read_console","read_network","wait_for_api_response","javascript_tool","browser_batch","set_explain_mode","annotate"];
747
+ export const EXTENSION_TOOL_NAMES: readonly string[] = ["ping","capabilities","reload","debug_exec","detach","navigate","login","scroll_to","resize_window","tabs_list","tabs_create","tabs_close","click","click_element","click_xy","type_text","form_input","key_press","select_option","label_select","file_upload","read_ax","get_page_text","find","wait_for","assert_text","screenshot","read_console","read_network","wait_for_api_response","get_page_context","javascript_tool","browser_batch","set_explain_mode","annotate"];
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "version": "0.1.0",
3
- "contractVersion": "1.0.0",
3
+ "contractVersion": "1.2.0",
4
4
  "protocol": "tool_request/result",
5
5
  "tools": [
6
6
  {
@@ -69,9 +69,7 @@
69
69
  "category": "navigation",
70
70
  "params": {
71
71
  "type": "object",
72
- "required": [
73
- "url"
74
- ],
72
+ "required": ["url"],
75
73
  "properties": {
76
74
  "url": {
77
75
  "type": "string"
@@ -88,11 +86,7 @@
88
86
  "category": "navigation",
89
87
  "params": {
90
88
  "type": "object",
91
- "required": [
92
- "email",
93
- "password",
94
- "consoleUrl"
95
- ],
89
+ "required": ["email", "password", "consoleUrl"],
96
90
  "properties": {
97
91
  "email": {
98
92
  "type": "string"
@@ -115,9 +109,7 @@
115
109
  "category": "navigation",
116
110
  "params": {
117
111
  "type": "object",
118
- "required": [
119
- "ref"
120
- ],
112
+ "required": ["ref"],
121
113
  "properties": {
122
114
  "ref": {
123
115
  "type": "string"
@@ -134,10 +126,7 @@
134
126
  "category": "navigation",
135
127
  "params": {
136
128
  "type": "object",
137
- "required": [
138
- "width",
139
- "height"
140
- ],
129
+ "required": ["width", "height"],
141
130
  "properties": {
142
131
  "width": {
143
132
  "type": "number"
@@ -167,9 +156,7 @@
167
156
  "category": "navigation",
168
157
  "params": {
169
158
  "type": "object",
170
- "required": [
171
- "url"
172
- ],
159
+ "required": ["url"],
173
160
  "properties": {
174
161
  "url": {
175
162
  "type": "string"
@@ -186,9 +173,7 @@
186
173
  "category": "navigation",
187
174
  "params": {
188
175
  "type": "object",
189
- "required": [
190
- "tabId"
191
- ],
176
+ "required": ["tabId"],
192
177
  "properties": {
193
178
  "tabId": {
194
179
  "type": "number"
@@ -205,9 +190,7 @@
205
190
  "category": "interaction",
206
191
  "params": {
207
192
  "type": "object",
208
- "required": [
209
- "ref"
210
- ],
193
+ "required": ["ref"],
211
194
  "properties": {
212
195
  "ref": {
213
196
  "type": "string"
@@ -224,9 +207,7 @@
224
207
  "category": "interaction",
225
208
  "params": {
226
209
  "type": "object",
227
- "required": [
228
- "js"
229
- ],
210
+ "required": ["js"],
230
211
  "properties": {
231
212
  "js": {
232
213
  "type": "string"
@@ -246,10 +227,7 @@
246
227
  "category": "interaction",
247
228
  "params": {
248
229
  "type": "object",
249
- "required": [
250
- "x",
251
- "y"
252
- ],
230
+ "required": ["x", "y"],
253
231
  "properties": {
254
232
  "x": {
255
233
  "type": "number"
@@ -269,9 +247,7 @@
269
247
  "category": "interaction",
270
248
  "params": {
271
249
  "type": "object",
272
- "required": [
273
- "text"
274
- ],
250
+ "required": ["text"],
275
251
  "properties": {
276
252
  "text": {
277
253
  "type": "string"
@@ -288,10 +264,7 @@
288
264
  "category": "interaction",
289
265
  "params": {
290
266
  "type": "object",
291
- "required": [
292
- "ref",
293
- "value"
294
- ],
267
+ "required": ["ref", "value"],
295
268
  "properties": {
296
269
  "ref": {
297
270
  "type": "string"
@@ -311,9 +284,7 @@
311
284
  "category": "interaction",
312
285
  "params": {
313
286
  "type": "object",
314
- "required": [
315
- "key"
316
- ],
287
+ "required": ["key"],
317
288
  "properties": {
318
289
  "key": {
319
290
  "type": "string"
@@ -330,10 +301,7 @@
330
301
  "category": "interaction",
331
302
  "params": {
332
303
  "type": "object",
333
- "required": [
334
- "ref",
335
- "value"
336
- ],
304
+ "required": ["ref", "value"],
337
305
  "properties": {
338
306
  "ref": {
339
307
  "type": "string"
@@ -353,10 +321,7 @@
353
321
  "category": "interaction",
354
322
  "params": {
355
323
  "type": "object",
356
- "required": [
357
- "selector",
358
- "value"
359
- ],
324
+ "required": ["selector", "value"],
360
325
  "properties": {
361
326
  "selector": {
362
327
  "type": "string"
@@ -382,10 +347,7 @@
382
347
  "category": "interaction",
383
348
  "params": {
384
349
  "type": "object",
385
- "required": [
386
- "ref",
387
- "files"
388
- ],
350
+ "required": ["ref", "files"],
389
351
  "properties": {
390
352
  "ref": {
391
353
  "type": "string"
@@ -432,9 +394,7 @@
432
394
  "category": "read",
433
395
  "params": {
434
396
  "type": "object",
435
- "required": [
436
- "selector"
437
- ],
397
+ "required": ["selector"],
438
398
  "properties": {
439
399
  "selector": {
440
400
  "type": "string"
@@ -451,9 +411,7 @@
451
411
  "category": "read",
452
412
  "params": {
453
413
  "type": "object",
454
- "required": [
455
- "selector"
456
- ],
414
+ "required": ["selector"],
457
415
  "properties": {
458
416
  "selector": {
459
417
  "type": "string"
@@ -476,10 +434,7 @@
476
434
  "category": "read",
477
435
  "params": {
478
436
  "type": "object",
479
- "required": [
480
- "selector",
481
- "expected"
482
- ],
437
+ "required": ["selector", "expected"],
483
438
  "properties": {
484
439
  "selector": {
485
440
  "type": "string"
@@ -559,15 +514,25 @@
559
514
  "readOnly": true
560
515
  }
561
516
  },
517
+ {
518
+ "name": "get_page_context",
519
+ "summary": "Return a snapshot of the active console page (url, AX tree, captured XC API body) for chat grounding.",
520
+ "category": "read",
521
+ "params": {
522
+ "type": "object",
523
+ "properties": {}
524
+ },
525
+ "flags": {
526
+ "readOnly": true
527
+ }
528
+ },
562
529
  {
563
530
  "name": "javascript_tool",
564
531
  "summary": "Evaluate arbitrary JS in the page (length-capped).",
565
532
  "category": "script",
566
533
  "params": {
567
534
  "type": "object",
568
- "required": [
569
- "code"
570
- ],
535
+ "required": ["code"],
571
536
  "properties": {
572
537
  "code": {
573
538
  "type": "string"
@@ -584,17 +549,13 @@
584
549
  "category": "script",
585
550
  "params": {
586
551
  "type": "object",
587
- "required": [
588
- "actions"
589
- ],
552
+ "required": ["actions"],
590
553
  "properties": {
591
554
  "actions": {
592
555
  "type": "array",
593
556
  "items": {
594
557
  "type": "object",
595
- "required": [
596
- "tool"
597
- ],
558
+ "required": ["tool"],
598
559
  "properties": {
599
560
  "tool": {
600
561
  "type": "string"
@@ -629,9 +590,7 @@
629
590
  "category": "annotation",
630
591
  "params": {
631
592
  "type": "object",
632
- "required": [
633
- "kind"
634
- ],
593
+ "required": ["kind"],
635
594
  "properties": {
636
595
  "kind": {
637
596
  "type": "string"
@@ -668,10 +627,7 @@
668
627
  "tool": "annotate",
669
628
  "requiresExplainMode": true,
670
629
  "autoFingerprintOnClick": true,
671
- "kinds": [
672
- "fingerprint",
673
- "highlight"
674
- ],
630
+ "kinds": ["fingerprint", "highlight"],
675
631
  "description": "Transient annotation overlays. In explain mode, clicks auto-draw a fingerprint; `annotate` draws a named overlay by ref or coordinates."
676
632
  },
677
633
  "capture": {
@@ -681,6 +637,13 @@
681
637
  "viewport": {
682
638
  "tool": "resize_window",
683
639
  "description": "Control the browser window size."
640
+ },
641
+ "chat": {
642
+ "contextTool": "get_page_context",
643
+ "transport": "websocket-bridge",
644
+ "modes": ["educational", "presentation", "configuration", "screenshot", "annotation"],
645
+ "messages": ["chat_request", "chat_delta", "chat_done", "chat_error", "chat_stop", "chat_tool_notice"],
646
+ "description": "User ↔ xcsh chat over the bridge. The extension side panel sends chat_request (with mode and page-context snapshot); xcsh streams chat_delta tokens then a terminal chat_done (with reference links) or chat_error. Chat ids are prefixed \"c-\". Tool calls during a turn use the normal tool_request flow. chat_stop halts a streaming response. chat_tool_notice is emitted by the EXTENSION (the service worker) to the panel as a best-effort UI signal when a tool runs during a turn — it is NOT sent by xcsh; xcsh must not produce it to avoid double-rendering in the panel."
684
647
  }
685
648
  }
686
649
  }