@arcgis/portal-components 6.0.0-next.37 → 6.0.0-next.39
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/cdn/2574FNAZ.js +2 -0
- package/dist/cdn/3DOZPC3W.js +2 -0
- package/dist/cdn/{R5LNWMD4.js → 3HZI6MKD.js} +1 -1
- package/dist/cdn/{ASLKTYLX.js → 3KGSWW6B.js} +1 -1
- package/dist/cdn/{VWV2LCNA.js → 3OL7A2UC.js} +1 -1
- package/dist/cdn/3Q7UJKKN.js +2 -0
- package/dist/cdn/43A74S72.js +2 -0
- package/dist/cdn/46HNNQAD.js +2 -0
- package/dist/cdn/46MYBPSS.js +2 -0
- package/dist/cdn/{H25PBZPU.js → 47DKAGRV.js} +1 -1
- package/dist/cdn/{5VFGR7LA.js → 4CBRO7JP.js} +1 -1
- package/dist/cdn/{NLFBHNSX.js → 5M25PCH2.js} +1 -1
- package/dist/cdn/5MLBK66O.js +2 -0
- package/dist/cdn/5RBH3LGK.js +2 -0
- package/dist/cdn/5ZHNRQOW.js +2 -0
- package/dist/cdn/62TL6V4N.js +2 -0
- package/dist/cdn/{IWQ5I2DD.js → 66VV7NHO.js} +1 -1
- package/dist/cdn/{US37IXWO.js → 6AHPTR2E.js} +1 -1
- package/dist/cdn/{ZQ6SGKLT.js → 6APPSZ7E.js} +1 -1
- package/dist/cdn/{XH6RD5BO.js → 6CUXEL27.js} +1 -1
- package/dist/cdn/{6HNKQNS5.js → 6QI7DAS2.js} +1 -1
- package/dist/cdn/{324F5URQ.js → 6ZJNZZPC.js} +1 -1
- package/dist/cdn/{5CEFJTG4.js → 75CT6IMW.js} +1 -1
- package/dist/cdn/{CJ4S56BE.js → 7J22VLBO.js} +1 -1
- package/dist/cdn/7VPB6Q55.js +63 -0
- package/dist/cdn/7ZU43BL6.js +2 -0
- package/dist/cdn/A5QLPZ57.js +2 -0
- package/dist/cdn/AZTAWZI5.js +2 -0
- package/dist/cdn/{WIUFH5SJ.js → BNWJUQDF.js} +1 -1
- package/dist/cdn/{UBPCKCW2.js → BUYOYUA2.js} +1 -1
- package/dist/cdn/BX7Q3V2Y.js +43 -0
- package/dist/cdn/BXPNB7VJ.js +2 -0
- package/dist/cdn/{4Y73LE7P.js → BZEKNJUA.js} +1 -1
- package/dist/cdn/{WCZJXBW3.js → C6RUWLEJ.js} +1 -1
- package/dist/cdn/C7SNE6YG.js +2 -0
- package/dist/cdn/DENQY4OE.js +2 -0
- package/dist/cdn/DT4HGMLS.js +2 -0
- package/dist/cdn/{NYBLHT3F.js → DTGPLVZF.js} +1 -1
- package/dist/cdn/DU2R3VC4.js +2 -0
- package/dist/cdn/{RJRTGF33.js → E5HCHRAI.js} +1 -1
- package/dist/cdn/{IX4WEZZ2.js → EBL7YSRM.js} +1 -1
- package/dist/cdn/EDGE3T36.js +2 -0
- package/dist/cdn/{HBO7XTIL.js → EFMYI4L2.js} +1 -1
- package/dist/cdn/{XOM3GLYF.js → FFL2L4X5.js} +1 -1
- package/dist/cdn/{PST62OKJ.js → FIAEPK5L.js} +1 -1
- package/dist/cdn/{L25GEXL6.js → FTKSVLDI.js} +1 -1
- package/dist/cdn/{QMIVFHQE.js → G272JPUS.js} +1 -1
- package/dist/cdn/{D52TYBRX.js → GFUKRB6D.js} +1 -1
- package/dist/cdn/{ZGSAH7Z7.js → GG6U75ZA.js} +1 -1
- package/dist/cdn/{O4YFPGD5.js → GZ4ONSFV.js} +1 -1
- package/dist/cdn/{YP7T6NKR.js → HOIZXTOD.js} +1 -1
- package/dist/cdn/{DV57AOBF.js → IAMPUXPT.js} +1 -1
- package/dist/cdn/{AUM2QTBQ.js → IAWL475A.js} +1 -1
- package/dist/cdn/IGLODZPX.js +2 -0
- package/dist/cdn/{KTWSNYYZ.js → IOF72CDU.js} +1 -1
- package/dist/cdn/ITRJGXFV.js +93 -0
- package/dist/cdn/{EDQSL2P3.js → ITWLFQI4.js} +1 -1
- package/dist/cdn/{B343BOVA.js → IYICIRGI.js} +1 -1
- package/dist/cdn/{OVAOMUO3.js → JFGXTJY4.js} +1 -1
- package/dist/cdn/{5E4EL6TF.js → JIU6MBGB.js} +1 -1
- package/dist/cdn/{5Y32T5IJ.js → JTA223NH.js} +1 -1
- package/dist/cdn/KA2MXQTR.js +2 -0
- package/dist/cdn/KAK6CNI7.js +2 -0
- package/dist/cdn/{5S4JV6IY.js → KPZGBBDG.js} +1 -1
- package/dist/cdn/{M664QA6J.js → KRO5XRZ7.js} +1 -1
- package/dist/cdn/KWL2D56D.js +3 -0
- package/dist/cdn/{BRWHEYLW.js → KXVXQYIB.js} +1 -1
- package/dist/cdn/L3YOPSRB.js +135 -0
- package/dist/cdn/{QF626JXP.js → LEESUFWE.js} +1 -1
- package/dist/cdn/{CMNTOT5D.js → LGKI24ZT.js} +1 -1
- package/dist/cdn/LTD5KLLE.js +2 -0
- package/dist/cdn/{VFECPSKA.js → MB32XRI5.js} +1 -1
- package/dist/cdn/{3T3QBPC3.js → MSL36HAR.js} +1 -1
- package/dist/cdn/{ARAHDT2O.js → N3WRMPM6.js} +1 -1
- package/dist/cdn/N47MW5HI.js +9 -0
- package/dist/cdn/{G7DJPREL.js → N7XYFVOI.js} +1 -1
- package/dist/cdn/{WZFGZEQI.js → NU4K2AV3.js} +1 -1
- package/dist/cdn/{ESKKH4DE.js → ONRTCGLU.js} +1 -1
- package/dist/cdn/{WSQLSDQY.js → OPI4P6VO.js} +1 -1
- package/dist/cdn/{YYKKXL62.js → OPMM7QH5.js} +1 -1
- package/dist/cdn/{PRBP4AP6.js → OXF2WDSW.js} +1 -1
- package/dist/cdn/P3FFM322.js +2 -0
- package/dist/cdn/QAXFE5DD.js +2 -0
- package/dist/cdn/{6EMK2BU6.js → QKRLO5CJ.js} +1 -1
- package/dist/cdn/{FVHP6PFG.js → R26RBXQW.js} +1 -1
- package/dist/cdn/R6KJVAX3.js +99 -0
- package/dist/cdn/RA2NMLMP.js +2 -0
- package/dist/cdn/{365ICWHN.js → RJXIU4GH.js} +1 -1
- package/dist/cdn/{6FFYU4NI.js → RKHNP3KL.js} +1 -1
- package/dist/cdn/RR56BOTV.js +2 -0
- package/dist/cdn/RTZ2TKM5.js +2 -0
- package/dist/cdn/RX64JXHI.js +170 -0
- package/dist/cdn/{26KZUWNM.js → RXMM6CFK.js} +1 -1
- package/dist/cdn/{JA3GGSJJ.js → S4N5QMSN.js} +1 -1
- package/dist/cdn/{3CXU5CCM.js → SCLYGIHM.js} +1 -1
- package/dist/cdn/{PJZZIITX.js → SLK7PV62.js} +1 -1
- package/dist/cdn/{SUA7ZZUH.js → SUN4MBT3.js} +1 -1
- package/dist/cdn/SYXCSFIA.js +2 -0
- package/dist/cdn/{3QWNGHAK.js → TBSNDRRE.js} +1 -1
- package/dist/cdn/TP7V25GT.js +2 -0
- package/dist/cdn/{FGDSHTJ5.js → UBMZBXT7.js} +1 -1
- package/dist/cdn/UIK6LPA7.js +2 -0
- package/dist/cdn/{7DAB2CEU.js → VQRMXBPQ.js} +1 -1
- package/dist/cdn/{AM3UTQWH.js → VWOBCSD6.js} +1 -1
- package/dist/cdn/{C3F24ZOM.js → W3JJBZYX.js} +1 -1
- package/dist/cdn/W6WVMRGQ.js +2 -0
- package/dist/cdn/{TO666HVV.js → WNXDXB3M.js} +1 -1
- package/dist/cdn/{XEVOU7SJ.js → WOSWA2VI.js} +1 -1
- package/dist/cdn/{DMS3R2W5.js → WTKLB3R6.js} +1 -1
- package/dist/cdn/{LR33CLTB.js → X7W4VJO7.js} +1 -1
- package/dist/cdn/{CIRCDM5E.js → XCOP6QHA.js} +1 -1
- package/dist/cdn/{C4GK263H.js → XVV75AX3.js} +1 -1
- package/dist/cdn/XYHIVGUK.js +2 -0
- package/dist/cdn/{2GZVUHL5.js → Y4JOEFBJ.js} +1 -1
- package/dist/cdn/{CNEJPW3I.js → Y7ZCEONL.js} +1 -1
- package/dist/cdn/YELHAJB3.js +2 -0
- package/dist/cdn/YH2OFXPU.js +2 -0
- package/dist/cdn/{HVQ7FKJ5.js → YYVLFAFT.js} +1 -1
- package/dist/cdn/{BX2LXI3N.js → ZDH4KVAV.js} +1 -1
- package/dist/cdn/{SO3IBFEU.js → ZECUXVTO.js} +1 -1
- package/dist/cdn/ZG7OW456.js +2 -0
- package/dist/cdn/{7BFTXD5J.js → ZLNBCJE4.js} +1 -1
- package/dist/cdn/{GC4BV7IZ.js → ZNNEU5QW.js} +1 -1
- package/dist/cdn/assets/portal-item-status-card/t9n/messages.en.json +1 -0
- package/dist/cdn/assets/portal-review-layer-sharing/t9n/messages.en.json +1 -0
- package/dist/cdn/index.js +1 -1
- package/dist/cdn/main.css +1 -1
- package/dist/chunks/constants.js +7 -0
- package/dist/chunks/contextUsage.js +208 -0
- package/dist/chunks/createPortalTool.js +8 -8
- package/dist/chunks/fieldAddDelete.js +1 -1
- package/dist/chunks/groups2.js +1 -1
- package/dist/chunks/help.js +22 -0
- package/dist/chunks/item.js +29 -25
- package/dist/chunks/item2.js +66 -30
- package/dist/chunks/itemThumbnail.js +1 -1
- package/dist/chunks/items.js +11 -11
- package/dist/chunks/layers.js +1 -1
- package/dist/chunks/portal-item-preview-sublayer.js +1 -1
- package/dist/chunks/portal-item-status-card.js +81 -0
- package/dist/chunks/portal.js +2 -2
- package/dist/chunks/portal2.js +1 -1
- package/dist/chunks/previewSessionController.js +33 -0
- package/dist/chunks/request.js +9 -9
- package/dist/chunks/services.js +1 -1
- package/dist/chunks/user.js +2 -2
- package/dist/chunks/utils2.js +4 -4
- package/dist/components/arcgis-portal-ai-assistant/customElement.js +241 -219
- package/dist/components/arcgis-portal-ai-assistant/index.js +1 -0
- package/dist/components/arcgis-portal-ai-assistant-diagnostics/contextUsage.d.ts +46 -0
- package/dist/components/arcgis-portal-ai-assistant-diagnostics/customElement.d.ts +26 -0
- package/dist/components/arcgis-portal-ai-assistant-diagnostics/customElement.js +46 -0
- package/dist/components/arcgis-portal-ai-assistant-diagnostics/index.d.ts +1 -0
- package/dist/components/arcgis-portal-ai-assistant-diagnostics/index.js +10 -0
- package/dist/components/arcgis-portal-delete-items/customElement.js +95 -110
- package/dist/components/arcgis-portal-entity-picker/customElement.js +1 -1
- package/dist/components/arcgis-portal-field-delete/customElement.js +1 -1
- package/dist/components/arcgis-portal-group-browser/customElement.js +62 -90
- package/dist/components/arcgis-portal-group-thumbnail/customElement.js +1 -1
- package/dist/components/arcgis-portal-item-share-summary/customElement.js +1 -1
- package/dist/components/arcgis-portal-item-status-card/customElement.d.ts +82 -0
- package/dist/components/arcgis-portal-item-status-card/customElement.js +12 -0
- package/dist/components/arcgis-portal-item-status-card/index.d.ts +1 -0
- package/dist/components/arcgis-portal-item-status-card/index.js +4 -0
- package/dist/components/arcgis-portal-navigation/customElement.js +1 -1
- package/dist/components/arcgis-portal-navigation/index.js +4 -4
- package/dist/components/arcgis-portal-review-layer-sharing/customElement.d.ts +139 -0
- package/dist/components/arcgis-portal-review-layer-sharing/customElement.js +593 -0
- package/dist/components/arcgis-portal-review-layer-sharing/index.d.ts +1 -0
- package/dist/components/arcgis-portal-review-layer-sharing/index.js +10 -0
- package/dist/components/arcgis-portal-review-layer-sharing/types.d.ts +27 -0
- package/dist/components/arcgis-portal-user-popup/customElement.js +1 -1
- package/dist/docs/api.json +1 -1
- package/dist/docs/docs.json +1 -1
- package/dist/docs/vscode.html-custom-data.json +1 -1
- package/dist/docs/web-types.json +1 -1
- package/dist/index.d.ts +24 -0
- package/dist/index.js +1 -1
- package/dist/loader.js +3 -0
- package/dist/types/item.d.ts +2 -0
- package/dist/types/lumina.d.ts +18 -0
- package/dist/types/preact.d.ts +21 -0
- package/dist/types/react.d.ts +24 -0
- package/dist/types/stencil.d.ts +18 -0
- package/package.json +10 -10
- package/dist/cdn/234TH32X.js +0 -106
- package/dist/cdn/25K5D5HL.js +0 -2
- package/dist/cdn/4KTRAA2J.js +0 -2
- package/dist/cdn/4X4EYM3Q.js +0 -2
- package/dist/cdn/4YJGTINX.js +0 -2
- package/dist/cdn/A3OUZJ44.js +0 -2
- package/dist/cdn/ASID6YW7.js +0 -135
- package/dist/cdn/AYESDOK5.js +0 -2
- package/dist/cdn/BOEGDK4D.js +0 -2
- package/dist/cdn/CBFFZMX4.js +0 -2
- package/dist/cdn/FACH2JTF.js +0 -2
- package/dist/cdn/FGRMURKX.js +0 -2
- package/dist/cdn/GBG25IJ2.js +0 -2
- package/dist/cdn/H6MGSC3Y.js +0 -2
- package/dist/cdn/IKRGN33H.js +0 -93
- package/dist/cdn/K3GAZFRI.js +0 -63
- package/dist/cdn/LBW47BJG.js +0 -2
- package/dist/cdn/LRL2RJID.js +0 -2
- package/dist/cdn/MHQ5BATZ.js +0 -2
- package/dist/cdn/NJB24AIV.js +0 -2
- package/dist/cdn/NQ2IAQKL.js +0 -41
- package/dist/cdn/OEG4XCKY.js +0 -2
- package/dist/cdn/OHAQPQAP.js +0 -2
- package/dist/cdn/OYTK2VF2.js +0 -2
- package/dist/cdn/QPBWKASC.js +0 -2
- package/dist/cdn/RJ3SU3EV.js +0 -2
- package/dist/cdn/U2HTYOBB.js +0 -150
- package/dist/cdn/VLD3MVSG.js +0 -2
- package/dist/cdn/WMKG3CBK.js +0 -2
- package/dist/cdn/X4R2NVDQ.js +0 -2
- package/dist/cdn/X7C4PAJY.js +0 -2
- package/dist/cdn/YGZICQBT.js +0 -2
- package/dist/cdn/YNGFN7AY.js +0 -2
|
@@ -7,5 +7,6 @@ import "../arcgis-portal-mentionable-text-area/index.js";
|
|
|
7
7
|
import "../arcgis-portal-voice-input/index.js";
|
|
8
8
|
import "@arcgis/ai-components/components/arcgis-assistant-agent";
|
|
9
9
|
import "@esri/calcite-components/components/calcite-dialog";
|
|
10
|
+
import "../arcgis-portal-ai-assistant-diagnostics/index.js";
|
|
10
11
|
import "@arcgis/ai-components/components/arcgis-assistant-observation-panel";
|
|
11
12
|
export * from "./customElement.js";
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import type { PortalAssistantToolCachePolicy } from "../arcgis-portal-ai-assistant/types/assistantTools.js";
|
|
2
|
+
|
|
3
|
+
/** What the diagnostics window shows about one completed model call. */
|
|
4
|
+
export interface ContextUsage {
|
|
5
|
+
id: string;
|
|
6
|
+
runId: string;
|
|
7
|
+
runNumber: number;
|
|
8
|
+
runName: string;
|
|
9
|
+
number: number;
|
|
10
|
+
/** Input tokens of that one call; undefined when the provider did not report usage. */
|
|
11
|
+
promptSize?: number;
|
|
12
|
+
/** Undefined when the model has no known context window. */
|
|
13
|
+
contextWindow?: number;
|
|
14
|
+
cacheRead?: number;
|
|
15
|
+
cacheWrite?: number;
|
|
16
|
+
/**
|
|
17
|
+
* `cached` is about the provider's prompt cache, and is undefined when the cached part of the
|
|
18
|
+
* prompt cannot be identified. `hasCachedToolResults` marks the message that carries `cachedToolResults`.
|
|
19
|
+
*/
|
|
20
|
+
messages: readonly (ContextMessage & {
|
|
21
|
+
cached?: boolean;
|
|
22
|
+
hasCachedToolResults?: boolean;
|
|
23
|
+
})[];
|
|
24
|
+
/** Earlier tool results the portal assistant kept and sent to the model with this call. */
|
|
25
|
+
cachedToolResults: readonly CachedToolResult[];
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
export interface RegisteredTool {
|
|
29
|
+
name: string;
|
|
30
|
+
description: string;
|
|
31
|
+
schema: string;
|
|
32
|
+
/** Whether the portal assistant keeps this tool's results to reuse in later turns. */
|
|
33
|
+
cachePolicy: PortalAssistantToolCachePolicy;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
export interface ContextMessage {
|
|
37
|
+
role: string;
|
|
38
|
+
text: string;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
/** One tool result from the portal assistant's own result cache, as text for display. */
|
|
42
|
+
export interface CachedToolResult {
|
|
43
|
+
toolName: string;
|
|
44
|
+
input: string;
|
|
45
|
+
output: string;
|
|
46
|
+
}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/// <reference path="../../index.d.ts" />
|
|
2
|
+
import type { PublicLitElement as LitElement } from "@arcgis/lumina";
|
|
3
|
+
import type { ContextUsage, RegisteredTool } from "./contextUsage.js";
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* The content of the Portal assistant's diagnostics window: an action bar that switches between
|
|
7
|
+
* Runs, which is whatever is slotted in (the shared observation panel), and Context, which lists
|
|
8
|
+
* each model call with its input size, cache use, messages, cached tool results and the registered tools.
|
|
9
|
+
*
|
|
10
|
+
* Context observes each model call, not each run. Within the agent loop a run calls the model, the
|
|
11
|
+
* model may request tool calls, and it is called again with their results until it has an answer, so
|
|
12
|
+
* one run has several model calls. The context limit applies to a single call, and the provider reports
|
|
13
|
+
* input tokens and cache reads and writes per call. The prompt also grows from one call to the next
|
|
14
|
+
* within a run, so a per-run total would count the same content more than once. The calls are grouped
|
|
15
|
+
* by run to make that clear.
|
|
16
|
+
*
|
|
17
|
+
* @slot [default] - The Runs view.
|
|
18
|
+
* @internal
|
|
19
|
+
* @see [The agent loop](https://code.claude.com/docs/en/agent-sdk/agent-loop)
|
|
20
|
+
*/
|
|
21
|
+
export abstract class ArcgisPortalAiAssistantDiagnostics extends LitElement {
|
|
22
|
+
/** Each completed model call, oldest first. */
|
|
23
|
+
accessor contextUsages: readonly ContextUsage[];
|
|
24
|
+
/** The tools currently given to the tool agent. */
|
|
25
|
+
accessor registeredTools: readonly RegisteredTool[];
|
|
26
|
+
}
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
/* COPYRIGHT Esri - https://js.arcgis.com/6.0/LICENSE.txt */
|
|
2
|
+
import { c as $ } from "../../chunks/runtime.js";
|
|
3
|
+
import { repeat as h } from "lit/directives/repeat.js";
|
|
4
|
+
import { css as b, html as a } from "lit";
|
|
5
|
+
import { LitElement as u } from "@arcgis/lumina";
|
|
6
|
+
import { createRef as x, ref as f } from "lit/directives/ref.js";
|
|
7
|
+
import { f as v, c as e, a as k, g as w, b as g, d as y, e as s, h as C, i as I, j as d } from "../../chunks/contextUsage.js";
|
|
8
|
+
const R = b`:host{display:block;block-size:100%}.content{display:flex;block-size:100%}calcite-action-bar{border-inline-end:1px solid var(--calcite-color-border-3)}.view{flex:1;min-inline-size:0}.context{display:flex;block-size:100%}.context-calls{flex:none;inline-size:16rem;border-inline-end:1px solid var(--calcite-color-border-3)}.context-run{--calcite-block-content-space: 0}.context-calls-info{margin:var(--calcite-spacing-md);max-inline-size:16rem}.context-details{flex:1;min-inline-size:0}.context[hidden],.runs[hidden]{display:none}.context-empty{margin:0}.context-tool-description{margin-block:0 var(--calcite-spacing-sm)}.context pre{margin:0;white-space:pre-wrap;overflow-wrap:anywhere;font-size:var(--calcite-font-size--2)}.runs{block-size:100%}`;
|
|
9
|
+
class z extends u {
|
|
10
|
+
constructor() {
|
|
11
|
+
super(...arguments), this.callsInfoEl = x(), this.view = "runs", this.contextUsages = [], this.registeredTools = [];
|
|
12
|
+
}
|
|
13
|
+
static {
|
|
14
|
+
this.properties = { view: 16, selectedCallId: 16, contextUsages: 0, registeredTools: 0 };
|
|
15
|
+
}
|
|
16
|
+
static {
|
|
17
|
+
this.styles = R;
|
|
18
|
+
}
|
|
19
|
+
renderContext() {
|
|
20
|
+
const { contextUsages: n, registeredTools: r } = this, l = v(n, this.selectedCallId), m = l?.messages ?? [], p = "calls-info";
|
|
21
|
+
return a`<div class="context" .hidden=${this.view !== "context"}>${l && a`<calcite-panel class="context-calls" .heading=${e.calls} heading-level=3 .description=${k(n)} @keydown=${(t) => {
|
|
22
|
+
const c = this.callsInfoEl.value;
|
|
23
|
+
t.key === "Escape" && c?.open && (t.stopPropagation(), c.open = !1);
|
|
24
|
+
}}><calcite-action slot=header-actions-end id=${p} icon=information .text=${e.callsInfo}></calcite-action><calcite-popover .referenceElement=${p} .label=${e.callsInfo} auto-close overlay-positioning=fixed placement=bottom-start ${f(this.callsInfoEl)}><p class="context-calls-info">${e.callsDescription}</p></calcite-popover><calcite-block-group .label=${e.calls}>${h(w(n), (t) => t.runId, (t) => a`<calcite-block class="context-run" .heading=${g(t)} heading-level=4 .description=${y(t.usages.length)} expandable expanded><calcite-list .label=${g(t)} selection-mode=single-persist selection-appearance=border>${h(t.usages, (c) => c.id, (c) => a`<calcite-list-item .label=${e.call.replace("{number}", c.number.toLocaleString())} .description=${e.callSummary.replace("{used}", s(c.promptSize)).replace("{read}", s(c.cacheRead)).replace("{write}", s(c.cacheWrite))} .selected=${c === l} @calciteListItemSelect=${() => {
|
|
25
|
+
this.selectedCallId = c.id;
|
|
26
|
+
}}></calcite-list-item>`)}</calcite-list></calcite-block>`)}</calcite-block-group></calcite-panel>` || ""}<calcite-panel class="context-details" .heading=${l ? e.call.replace("{number}", l.number.toLocaleString()) : e.heading} heading-level=3 .description=${C(l)}><calcite-block-group .label=${e.heading}>${l && a`<calcite-block .heading=${e.messages} heading-level=4 .description=${`${e.cache.replace("{read}", s(l.cacheRead)).replace("{write}", s(l.cacheWrite))}${I(l) ? ` ${e.cacheUnidentified}` : ""}`} expandable expanded><calcite-block-group slot=children .label=${e.messages} scale=s>${m.map(({ role: t, text: c, cached: i, hasCachedToolResults: o }) => a`<calcite-block .heading=${t} heading-level=5 expandable .description=${[
|
|
27
|
+
d(c),
|
|
28
|
+
...i === void 0 ? [] : [i ? e.cached : e.new],
|
|
29
|
+
...o ? [e.cachedResultsNote] : []
|
|
30
|
+
].join(" | ")}><pre>${c}</pre></calcite-block>`)}</calcite-block-group></calcite-block><calcite-block .heading=${e.cachedResults.replace("{count}", l.cachedToolResults.length.toLocaleString())} heading-level=4 .description=${e.cachedResultsDescription} expandable expanded>${l.cachedToolResults.length ? a`<calcite-block-group slot=children .label=${e.cachedResultsNote} scale=s>${l.cachedToolResults.map(({ toolName: t, input: c, output: i }) => a`<calcite-block .heading=${t} heading-level=5 expandable .description=${[
|
|
31
|
+
e.cachedResultInput.replace("{input}", () => c),
|
|
32
|
+
d(i)
|
|
33
|
+
].join(" | ")}><pre>${i}</pre></calcite-block>`)}</calcite-block-group>` : a`<p class="context-empty">${e.cachedResultsNone}</p>`}</calcite-block>` || ""}<calcite-block .heading=${e.tools.replace("{count}", r.length.toLocaleString())} heading-level=4 expandable expanded><calcite-block-group slot=children .label=${e.tools.replace("{count}", r.length.toLocaleString())} scale=s>${r.map(({ name: t, description: c, schema: i, cachePolicy: o }) => a`<calcite-block .heading=${t} heading-level=5 expandable .description=${d(c + i)}>${o !== "no-cache" && a`<calcite-chip slot=content-end scale=s .label=${e.resultsCached}>${o === "normal" ? e.resultsCached : e.resultsCachedNoInvalidation}</calcite-chip>` || ""}<p class="context-tool-description">${c}</p><pre>${i}</pre></calcite-block>`)}</calcite-block-group></calcite-block></calcite-block-group></calcite-panel></div>`;
|
|
34
|
+
}
|
|
35
|
+
render() {
|
|
36
|
+
return a`<div class="content"><calcite-action-bar><calcite-action icon=list .text=${e.runs} .active=${this.view === "runs"} @click=${() => {
|
|
37
|
+
this.view = "runs";
|
|
38
|
+
}}></calcite-action><calcite-action icon=chart-magnifying-glass .text=${e.heading} .active=${this.view === "context"} @click=${() => {
|
|
39
|
+
this.view = "context";
|
|
40
|
+
}}></calcite-action></calcite-action-bar><div class="view">${this.renderContext()}<div class="runs" .hidden=${this.view !== "runs"}><slot></slot></div></div></div>`;
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
$("arcgis-portal-ai-assistant-diagnostics", z);
|
|
44
|
+
export {
|
|
45
|
+
z as ArcgisPortalAiAssistantDiagnostics
|
|
46
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./customElement.js";
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import "@esri/calcite-components/components/calcite-panel";
|
|
2
|
+
import "@esri/calcite-components/components/calcite-action";
|
|
3
|
+
import "@esri/calcite-components/components/calcite-popover";
|
|
4
|
+
import "@esri/calcite-components/components/calcite-block-group";
|
|
5
|
+
import "@esri/calcite-components/components/calcite-block";
|
|
6
|
+
import "@esri/calcite-components/components/calcite-list";
|
|
7
|
+
import "@esri/calcite-components/components/calcite-list-item";
|
|
8
|
+
import "@esri/calcite-components/components/calcite-chip";
|
|
9
|
+
import "@esri/calcite-components/components/calcite-action-bar";
|
|
10
|
+
export * from "./customElement.js";
|