Repository navigation
Expand file tree
/
Copy pathsolution.html
More file actions
602 lines (567 loc) · 31.4 KB
/
Copy pathsolution.html
File metadata and controls
602 lines (567 loc) · 31.4 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Solution — AIBAST Agents Library</title>
<meta name="description" content="An AIBAST industry solution: what was advertised, and the agent that delivers it.">
<!-- aibast-design:start -->
<style>
/* AIBAST design tokens - generated by tools/design_tokens.py, do not hand-edit.
Stamped before each page's own <style>, so page rules still win. */
:root {
color-scheme: light;
--cp-bg: #f4f4f5;
--cp-bg-elevated: #fafafa;
--cp-surface: #ffffff;
--cp-surface-soft: #eeeeef;
--cp-border: #dcdcde;
--cp-border-strong: #8e8e93;
--cp-text: #18181b;
--cp-text-muted: #52525b;
--cp-text-soft: #6b6b74;
--cp-accent: #b11f4b;
--cp-accent-hover: #9a1a41;
--cp-accent-soft: rgba(177, 31, 75, 0.08);
--cp-accent-fg: #ffffff;
--cp-success: #15803d;
--cp-danger: #c81e1e;
--cp-warning: #b45309;
--cp-link: #0f6cbd;
--cp-shadow: 0 16px 40px rgba(24, 24, 27, 0.10);
--cp-overlay: rgba(24, 24, 27, 0.55);
--cp-panel: rgba(255, 255, 255, 0.86);
--cp-panel-strong: rgba(255, 255, 255, 0.96);
--cp-sheen: rgba(24, 24, 27, 0.04);
--cp-highlight: rgba(177, 31, 75, 0.12);
--cp-focus: #0b5fa5;
--cp-focus-halo: rgba(11, 95, 165, 0.28);
--cp-font: "Segoe UI", -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
--cp-font-mono: ui-monospace, SFMono-Regular, "SF Mono", "Cascadia Mono", "Segoe UI Mono", Menlo, Consolas, monospace;
--cp-text-xs: 0.75rem;
--cp-text-sm: 0.875rem;
--cp-text-base: 1rem;
--cp-text-lg: 1.125rem;
--cp-text-xl: clamp(1.25rem, 1.15rem + 0.4vw, 1.5rem);
--cp-text-2xl: clamp(1.5rem, 1.3rem + 0.9vw, 2rem);
--cp-text-3xl: clamp(1.875rem, 1.5rem + 1.6vw, 2.75rem);
--cp-text-4xl: clamp(2.25rem, 1.6rem + 2.8vw, 3.75rem);
--cp-leading-tight: 1.15;
--cp-leading-snug: 1.35;
--cp-leading: 1.6;
--cp-tracking-tight: -0.02em;
--cp-tracking-label: 0.08em;
--cp-measure: 65ch;
--cp-space-1: 0.25rem;
--cp-space-2: 0.5rem;
--cp-space-3: 0.75rem;
--cp-space-4: 1rem;
--cp-space-5: 1.5rem;
--cp-space-6: 2rem;
--cp-space-7: 3rem;
--cp-space-8: 4rem;
--cp-space-9: 6rem;
--cp-radius-sm: 6px;
--cp-radius: 10px;
--cp-radius-lg: 16px;
--cp-radius-pill: 999px;
--cp-ease: cubic-bezier(0.2, 0, 0, 1);
--cp-duration-fast: 120ms;
--cp-duration: 220ms;
--cp-container: 1200px;
--cp-header-height: 68px;
--cp-z-base: 1;
--cp-z-sticky: 100;
--cp-z-overlay: 200;
--cp-z-modal: 300;
--cp-z-toast: 400;
}
html[data-theme="dark"] {
color-scheme: dark;
--cp-bg: #18181b;
--cp-bg-elevated: #232327;
--cp-surface: #1f1f23;
--cp-surface-soft: #27272b;
--cp-border: #34343a;
--cp-border-strong: #54545c;
--cp-text: #f4f4f5;
--cp-text-muted: #a9a9b2;
--cp-text-soft: #c4c4cc;
--cp-accent: #ff7a9c;
--cp-accent-hover: #ff96b0;
--cp-accent-soft: rgba(255, 122, 156, 0.14);
--cp-accent-fg: #18181b;
--cp-success: #4ade80;
--cp-danger: #fb8a8a;
--cp-warning: #fbbf24;
--cp-link: #66b3ff;
--cp-shadow: 0 16px 40px rgba(0, 0, 0, 0.45);
--cp-overlay: rgba(9, 9, 11, 0.7);
--cp-panel: rgba(31, 31, 35, 0.78);
--cp-panel-strong: rgba(31, 31, 35, 0.96);
--cp-sheen: rgba(255, 255, 255, 0.05);
--cp-highlight: rgba(255, 122, 156, 0.12);
--cp-focus: #7cc4ff;
--cp-focus-halo: rgba(124, 196, 255, 0.34);
}
@media (prefers-color-scheme: dark) {
html:not([data-theme="light"]) {
color-scheme: dark;
--cp-bg: #18181b;
--cp-bg-elevated: #232327;
--cp-surface: #1f1f23;
--cp-surface-soft: #27272b;
--cp-border: #34343a;
--cp-border-strong: #54545c;
--cp-text: #f4f4f5;
--cp-text-muted: #a9a9b2;
--cp-text-soft: #c4c4cc;
--cp-accent: #ff7a9c;
--cp-accent-hover: #ff96b0;
--cp-accent-soft: rgba(255, 122, 156, 0.14);
--cp-accent-fg: #18181b;
--cp-success: #4ade80;
--cp-danger: #fb8a8a;
--cp-warning: #fbbf24;
--cp-link: #66b3ff;
--cp-shadow: 0 16px 40px rgba(0, 0, 0, 0.45);
--cp-overlay: rgba(9, 9, 11, 0.7);
--cp-panel: rgba(31, 31, 35, 0.78);
--cp-panel-strong: rgba(31, 31, 35, 0.96);
--cp-sheen: rgba(255, 255, 255, 0.05);
--cp-highlight: rgba(255, 122, 156, 0.12);
--cp-focus: #7cc4ff;
--cp-focus-halo: rgba(124, 196, 255, 0.34);
}
}
/* Keyboard focus has to be visible on every page, not only the ones that
remembered to style it. Pages that define their own :focus-visible override
this, because their <style> comes after. */
:where(a, button, input, select, textarea, summary, [tabindex]):focus-visible {
outline: 2px solid var(--cp-focus);
outline-offset: 2px;
border-radius: var(--cp-radius-sm);
box-shadow: 0 0 0 4px var(--cp-focus-halo);
}
/* An anchored heading must not land under a sticky header. */
:where([id]) { scroll-margin-top: calc(var(--cp-header-height) + var(--cp-space-4)); }
:where(img, svg, video, canvas) { max-width: 100%; }
:where(p) { text-wrap: pretty; }
::selection { background: var(--cp-accent-soft); color: var(--cp-text); }
/* Opt-in: aligns digits in tables and metric readouts. */
.cp-nums { font-variant-numeric: tabular-nums; }
@media (prefers-reduced-motion: reduce) {
*, *::before, *::after {
animation-duration: 0.01ms !important;
animation-iteration-count: 1 !important;
transition-duration: 0.01ms !important;
scroll-behavior: auto !important;
}
}
</style>
<!-- aibast-design:end -->
<style>
/* The page keeps its own variable names; each one is now an alias for the shared
AIBAST token, so every existing var(--bg)/var(--text)/... reference follows
both themes instead of pinning a dark GitHub palette. */
:root {
--bg: var(--cp-bg); --surface: var(--cp-surface); --surface2: var(--cp-surface-soft); --border: var(--cp-border);
--border-hover: var(--cp-border-strong); --text: var(--cp-text); --text-dim: var(--cp-text-muted); --text-muted: var(--cp-text-soft);
--accent: var(--cp-accent); --green: var(--cp-success); --radius: var(--cp-radius);
}
* { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: var(--cp-font);
background: var(--bg); color: var(--text); min-height: 100vh; line-height: 1.55; }
a { color: var(--cp-link); text-decoration: none; }
.crumb a, p a, li a { text-decoration: underline; text-underline-offset: 2px; }
a:hover { text-decoration: underline; }
code, .mono { font-family: var(--cp-font-mono); }
header { background: var(--surface); border-bottom: 1px solid var(--border); padding: 14px 32px;
display: flex; align-items: center; justify-content: space-between; position: sticky; top: 0; z-index: 50; gap: 16px; flex-wrap: wrap; }
.logo { display: flex; align-items: center; gap: 10px; font-size: 1.1rem; font-weight: 700; }
.logo-mark { background: var(--accent); color: var(--cp-accent-fg);
width: 32px; height: 32px; border-radius: var(--cp-radius-sm); display: flex; align-items: center; justify-content: center; font-size: .72rem; font-weight: 800; }
.nav-link { background: var(--surface2); border: 1px solid var(--border); color: var(--text-dim);
padding: 6px 14px; border-radius: var(--cp-radius-sm); font-size: .78rem; font-weight: 600; cursor: pointer; }
.nav-link:hover { border-color: var(--border-hover); color: var(--text); text-decoration: none; }
.nav-link.primary { background: var(--accent); color: var(--cp-accent-fg); border-color: var(--accent); }
.nav-link.primary:hover { background: var(--cp-accent-hover); border-color: var(--cp-accent-hover); color: var(--cp-accent-fg); }
.header-right { display: flex; gap: 10px; flex-wrap: wrap; }
.container { max-width: 1060px; margin: 0 auto; padding: 30px 24px 90px; }
.crumb { font-size: .78rem; color: var(--text-muted); margin-bottom: 14px; }
.hero { border: 1px solid var(--border); border-radius: var(--cp-radius-lg); padding: 28px 30px;
background: var(--cp-bg-elevated); }
.slot { font-size: .7rem; text-transform: uppercase; letter-spacing: var(--cp-tracking-label); color: var(--accent); font-weight: 800; }
.hero h1 { font-size: 2.1rem; font-weight: 850; letter-spacing: -.025em; margin: 6px 0 10px; }
.hero .summary { font-size: 1.05rem; color: var(--text-dim); max-width: 780px; }
.hero .alias { font-size: .8rem; color: var(--text-muted); margin-top: 10px; }
.chips { display: flex; flex-direction: column; gap: 8px; margin-top: 16px; }
.chip-group { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.chip { font-size: .72rem; background: var(--surface2); border: 1px solid var(--border);
color: var(--text-dim); border-radius: var(--cp-radius-pill); padding: 3px 11px; }
.chip.k { color: var(--text-muted); border-color: transparent; background: transparent; padding-left: 0; font-weight: 700;
text-transform: uppercase; letter-spacing: .07em; font-size: .66rem; }
.assets { display: flex; gap: 8px; margin-top: 18px; flex-wrap: wrap; align-items: center; }
/* Read-only status badges: outlined and quiet. */
.asset { font-size: .72rem; font-weight: 700; border-radius: var(--cp-radius-sm); padding: 4px 10px;
background: var(--surface); color: var(--green); border: 1px solid var(--border); }
/* The one call to action on the page is an <a>, so it gets the solid accent
treatment and reads as a button rather than as another status badge. */
a.asset { background: var(--accent); color: var(--cp-accent-fg); border-color: var(--accent); }
a.asset:hover, a.asset:focus-visible { background: var(--cp-accent-hover); border-color: var(--cp-accent-hover);
color: var(--cp-accent-fg); text-decoration: none; }
.section { margin-top: 38px; }
/* The one thing most visitors came for: centred, one line, one action. */
.section.get { max-width: 640px; margin-inline: auto; text-align: center; background: var(--surface); border: 1px solid var(--border); border-radius: var(--cp-radius-lg, 16px); padding: 28px 24px; }
.section.get h2 { font-size: 1.5rem; }
.section.get .sub { margin-inline: auto; }
.get-ask { margin-top: 18px; font-size: .82rem; font-weight: 650; color: var(--text-muted); }
.get-ais { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-top: 8px; }
.get-ai { min-height: 40px; padding: 8px 14px; border-radius: 999px; border: 1px solid var(--border); background: transparent; color: var(--text); font: inherit; font-size: .86rem; cursor: pointer; }
.get-ai[aria-pressed="true"] { border-color: var(--cp-accent); color: var(--cp-accent); font-weight: 650; }
.get-ai:focus-visible { outline: 2px solid var(--cp-focus); outline-offset: 2px; }
.get-how { margin: 12px auto 12px; font-size: .9rem; color: var(--text-muted); min-height: 2.9em; max-width: 46ch; }
.section.get .cmd { font-size: .86rem; word-break: normal; overflow-wrap: anywhere; }
.get-proof { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 16px; margin-top: 14px; font-size: .8rem; color: var(--text-muted); }
.get-proof span::before { content: "\2713\00a0"; color: var(--green); }
.get-walk { display: inline-block; margin-top: 14px; font-size: .86rem; }
details.more { margin-top: 38px; border-top: 1px solid var(--border); padding-top: 18px; }
details.more > summary { cursor: pointer; font-weight: 650; min-height: 44px; display: flex; align-items: center; gap: 8px; }
details.more > summary:focus-visible { outline: 2px solid var(--cp-focus); outline-offset: 2px; }
.section > h2 { font-size: 1.15rem; font-weight: 780; margin-bottom: 4px; }
.section > .sub { font-size: .82rem; color: var(--text-muted); margin-bottom: 14px; }
.story { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
@media (max-width: 880px) { .story { grid-template-columns: 1fr; } }
.story .col { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px 20px; }
/* One accent: the three column headings each carried a different decorative hue,
which read as competing accents. They are labels, so they take body colour. */
.story h3 { font-size: .72rem; text-transform: uppercase; letter-spacing: .09em; font-weight: 800; margin-bottom: 10px; color: var(--text); }
.story ul { margin: 0 0 0 17px; padding: 0; }
.story li { font-size: .85rem; color: var(--text-dim); margin-bottom: 7px; }
table { width: 100%; border-collapse: collapse; font-size: .84rem; }
th { text-align: left; color: var(--text-muted); font-size: .68rem; text-transform: uppercase;
letter-spacing: .07em; padding: 8px 12px 8px 0; border-bottom: 1px solid var(--border); }
td { padding: 10px 12px 10px 0; border-bottom: 1px solid var(--border); color: var(--text-dim); vertical-align: top; }
td.op { white-space: nowrap; }
.ok { color: var(--green); font-weight: 700; }
.tabs { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 12px; }
.tab { background: var(--surface); border: 1px solid var(--border); color: var(--text-dim);
padding: 6px 13px; border-radius: var(--cp-radius-pill); font-size: .77rem; font-weight: 650; cursor: pointer; }
.tab:hover { border-color: var(--border-hover); color: var(--text); }
/* Selected state: accent tint plus an accent edge, with full-strength label text
so the tab clears 4.5:1 on both themes (accent-on-tint does not, in dark). */
.tab.active { background: var(--cp-accent-soft); border-color: var(--accent); color: var(--text); }
.output { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
padding: 20px 22px; overflow-x: auto; }
.output .label { font-size: .7rem; text-transform: uppercase; letter-spacing: .08em;
color: var(--text-muted); font-weight: 700; margin-bottom: 12px; }
.output h1 { font-size: 1.05rem; margin: 0 0 10px; font-weight: 800; }
.output h2 { font-size: .9rem; margin: 18px 0 8px; font-weight: 750; color: var(--text); }
.output p { font-size: .84rem; color: var(--text-dim); margin-bottom: 8px; }
.output ul { margin: 0 0 10px 18px; }
.output li { font-size: .82rem; color: var(--text-dim); margin-bottom: 4px; }
.output table { font-size: .78rem; margin: 6px 0 12px; }
.output th, .output td { padding: 5px 12px 5px 0; }
.output code { background: var(--surface2); padding: 1px 5px; border-radius: var(--cp-radius-sm); font-size: .78rem; }
.output strong { color: var(--text); }
.cmd { display: block; width: 100%; min-height: 44px; text-align: left; line-height: 1.45; background: var(--surface); border: 1px solid var(--border); border-radius: var(--cp-radius-sm);
padding: 12px 64px 12px 15px; font-family: var(--cp-font-mono);
font-size: .79rem; color: var(--text); cursor: pointer; position: relative; word-break: break-all; }
.cmd:hover { border-color: var(--border-hover); }
.cmd:focus-visible { outline: 2px solid var(--cp-focus); outline-offset: 2px; }
.cmd code { font: inherit; color: inherit; background: none; }
.cmd .cmd-label { position: absolute; right: 11px; top: 11px; font-family: var(--cp-font); font-size: .72rem; font-weight: 650; color: var(--text-muted); }
.cmd.copied .cmd-label { color: var(--green); }
.note { font-size: .79rem; color: var(--text-muted); line-height: 1.65; }
.kv { display: grid; grid-template-columns: 190px minmax(0, 1fr); gap: 7px 16px; font-size: .83rem; }
.kv dd { min-width: 0; overflow-wrap: anywhere; }
@media (max-width: 520px) { .kv { grid-template-columns: minmax(0, 1fr); gap: 2px; } .kv dd { margin: 0 0 8px; } }
.kv dt { color: var(--text-muted); font-weight: 650; }
.kv dd { color: var(--text-dim); }
footer { margin-top: 54px; padding-top: 20px; border-top: 1px solid var(--border);
color: var(--text-muted); font-size: .78rem; text-align: center; }
.empty { color: var(--text-muted); padding: 60px 0; text-align: center; }
/* Under the shared header the brand is already shown, so the page's own brand tile is hidden and its links sit on one row. */
body:has(>.site-shell) > header > .logo { display: none; }
</style>
<!-- clarity:start -->
<script data-clarity-project="yeqkj55zbc">
(function (w, d, id) {
if (!id || !/\.github\.io$/i.test(d.location.hostname)) return;
var n = w.navigator || {};
if (n.globalPrivacyControl || n.doNotTrack === "1" || w.doNotTrack === "1") return;
var KEY = "aibast-clarity-consent";
function read() { try { return w.localStorage.getItem(KEY); } catch (e) { return null; } }
function write(v) { try { w.localStorage.setItem(KEY, v); } catch (e) {} }
function load() {
w.clarity = w.clarity || function () { (w.clarity.q = w.clarity.q || []).push(arguments); };
var t = d.createElement("script"); t.async = 1; t.src = "https://www.clarity.ms/tag/" + id;
var y = d.getElementsByTagName("script")[0]; y.parentNode.insertBefore(t, y);
w.clarity("consentv2", { ad_Storage: "denied", analytics_Storage: "granted" });
}
function el(tag, css, text) { var e = d.createElement(tag); e.style.cssText = css; if (text) e.textContent = text; return e; }
function banner() {
if (d.getElementById(KEY)) return;
var bar = el("div", "position:fixed;left:0;right:0;bottom:0;z-index:2147483000;display:flex;flex-wrap:wrap;align-items:center;justify-content:center;gap:10px 16px;padding:12px 16px;background:Canvas;color:CanvasText;border-top:1px solid GrayText;font:14px/1.45 system-ui,-apple-system,'Segoe UI',sans-serif");
bar.id = KEY; bar.setAttribute("role", "region"); bar.setAttribute("aria-label", "Cookie consent");
var text = el("span", "max-width:62ch", "This site uses Microsoft Clarity to understand how visitors use it. Typed text is masked. ");
var link = el("a", "color:LinkText;text-decoration:underline", "Microsoft Privacy Statement");
link.href = "https://go.microsoft.com/fwlink/?LinkId=521839"; link.target = "_blank"; link.rel = "noopener";
text.appendChild(link);
var btn = "cursor:pointer;border-radius:6px;padding:7px 14px;font:inherit;font-weight:600;";
var accept = el("button", btn + "border:1px solid CanvasText;background:CanvasText;color:Canvas", "Accept");
var decline = el("button", btn + "border:1px solid GrayText;background:ButtonFace;color:ButtonText", "Decline");
accept.type = "button"; decline.type = "button";
accept.onclick = function () { write("granted"); bar.remove(); load(); };
decline.onclick = function () { write("denied"); bar.remove(); };
bar.appendChild(text); bar.appendChild(accept); bar.appendChild(decline);
d.body.appendChild(bar);
}
var choice = read();
if (choice === "granted") { load(); return; }
if (choice === "denied") return;
if (d.body) banner(); else d.addEventListener("DOMContentLoaded", banner);
})(window, document, "yeqkj55zbc");
</script>
<!-- clarity:end -->
</head>
<body>
<header>
<div class="logo"><div class="logo-mark">AIB</div> Industry Solution</div>
<div class="header-right">
<a class="nav-link" href="index.html">All solutions</a>
<a class="nav-link" href="index.html">Home</a>
<a class="nav-link primary" id="src-link" href="https://github.com/microsoft/aibast-agents-library" target="_blank" rel="noopener">Source</a>
</div>
</header>
<main class="container" id="root"><div class="empty">Loading…</div></main>
<script>
const OWNER = 'microsoft', REPO = 'aibast-agents-library';
const RAW = `https://raw.githubusercontent.com/${OWNER}/${REPO}/main`;
const SITE = `https://${OWNER}.github.io/${REPO}/`;
const BLOB = `https://github.com/${OWNER}/${REPO}/blob/main`;
const AGENT_DIR = '~/.brainstem/src/rapp_brainstem/agents';
const esc = s => String(s == null ? '' : s).replace(/[&<>"'`]/g, c => ({'&':'&','<':'<','>':'>','"':'"',"'":''','`':'`'}[c]));
const num = n => (n == null || isNaN(n)) ? '—' : Number(n).toLocaleString();
async function getJSON(paths) {
for (const p of paths) {
try { const r = await fetch(p); if (r.ok) return await r.json(); } catch (e) {}
}
return null;
}
/* The agent returns Markdown; render the subset it actually emits so the sample
reads the way it does in the Brainstem chat, not as escaped source. */
function md(src) {
const lines = String(src).split('\n');
let out = '', inTable = false, inList = false;
const inline = t => esc(t)
.replace(/`([^`]+)`/g, '<code>$1</code>')
.replace(/\*\*([^*]+)\*\*/g, '<strong>$1</strong>');
const closeList = () => { if (inList) { out += '</ul>'; inList = false; } };
const closeTable = () => { if (inTable) { out += '</tbody></table>'; inTable = false; } };
for (const raw of lines) {
const l = raw.trim();
if (!l) { closeList(); closeTable(); continue; }
if (/^\|[\s-|:]+\|$/.test(l)) continue; // separator row
if (l.startsWith('|')) {
const cells = l.split('|').slice(1, -1).map(c => c.trim());
if (!inTable) { closeList(); out += '<table><thead><tr>' + cells.map(c => `<th>${inline(c)}</th>`).join('') + '</tr></thead><tbody>'; inTable = true; }
else out += '<tr>' + cells.map(c => `<td>${inline(c)}</td>`).join('') + '</tr>';
continue;
}
closeTable();
if (l.startsWith('## ')) { closeList(); out += `<h2>${inline(l.slice(3))}</h2>`; continue; }
if (l.startsWith('# ')) { closeList(); out += `<h1>${inline(l.slice(2))}</h1>`; continue; }
if (l.startsWith('- ')) { if (!inList) { out += '<ul>'; inList = true; } out += `<li>${inline(l.slice(2))}</li>`; continue; }
closeList();
out += `<p>${inline(l)}</p>`;
}
closeList(); closeTable();
return out;
}
let SAMPLE = null, activeOp = null;
async function init() {
const id = new URLSearchParams(location.search).get('id');
const [solDoc, reg] = await Promise.all([
getJSON(['solutions.json', SITE + 'solutions.json']),
getJSON(['registry.json', SITE + 'registry.json']),
]);
if (!solDoc) { document.getElementById('root').innerHTML = '<div class="empty">Could not load <code>solutions.json</code>.</div>'; return; }
const sols = solDoc.solutions.filter(s => s.is_primary !== false);
// id may be the repo agent, the advertised slot, or the library slug (what the library links use).
let sol = id ? (sols.find(s => s.repo_agent === id) ||
sols.find(s => s.repo_agent.split('/').pop() === id) ||
sols.find(s => String(s.slot) === String(id))) : null;
// The library record's name is the one the meeting-prep skill searches for.
const rec = id && /^[a-z0-9-]+$/.test(id)
? await getJSON(['api/v1/solutions/' + id + '.json', SITE + 'api/v1/solutions/' + id + '.json']) : null;
LIB_NAME = rec?.name || '';
LIB_REC = rec;
if (!sol && rec) sol = sols.find(s => s.repo_agent === rec.id) || null;
if (!sol && id) {
document.getElementById('root').innerHTML = '<div class="empty">No solution called <code>' + id.replace(/[<>&"]/g, '') + '</code>. <a href="index.html#library">Browse all solutions</a>.</div>';
return;
}
sol = sol || sols.find(s => s.sample_output) || sols[0];
const agent = (reg?.agents || []).find(a => a.name === sol.repo_agent);
// samples/ is not part of the Pages artifact; the raw file is the only copy, so it stays the source here.
if (sol.sample_output) SAMPLE = await getJSON([RAW + '/' + sol.sample_output]);
render(sol, agent, sols);
}
// The skill sits beside this page, so the line works on whichever site serves the page.
const PAGES_BASE = /^https?:$/.test(location.protocol)
? new URL('.', location.href.split(/[?#]/)[0]).href
: 'https://microsoft.github.io/aibast-agents-library/';
const PREP_SKILL_PATH = 'skills/aibast-meeting-prep/SKILL.md';
const PREP_SKILL = /^https?:$/.test(location.protocol)
? new URL(PREP_SKILL_PATH, location.href.split(/[?#]/)[0]).href
: 'https://microsoft.github.io/aibast-agents-library/' + PREP_SKILL_PATH;
let LIB_NAME = '';
let LIB_REC = null; // the library record for this agent, when one exists
function prepLine(sol) {
return `Get ${PREP_SKILL} and do it. Use the ${LIB_NAME || sol.advertised_display || sol.advertised_name} example.`;
}
function render(sol, agent, sols) {
const file = agent?._file;
if (file) document.getElementById('src-link').href = `${BLOB}/${encodeURI(file)}`;
document.title = `${sol.advertised_display || sol.advertised_name} — AIBAST Agents Library`;
const ops = SAMPLE?.operations || [];
const capRows = (sol.capability_map || sol.capabilities.map(c => ({ advertised: c, operation: null })));
const chip = (label, arr) => arr && arr.length
? `<div class="chip-group"><span class="chip k">${label}</span>` + arr.map(x => `<span class="chip">${esc(x)}</span>`).join('') + '</div>' : '';
document.getElementById('root').innerHTML = `
<div class="crumb"><a href="index.html">Agent Library</a> › ${esc(sol.industries?.[0] || 'Solution')}</div>
<div class="hero">
<div class="slot">AIBAST Agents Library · advertised solution #${esc(sol.slot)}</div>
<h1>${esc(sol.advertised_display || sol.advertised_name)}</h1>
<p class="summary">${esc(sol.executive_summary)}</p>
${sol.sharepoint_list_name && sol.sharepoint_list_name !== (sol.advertised_display || sol.advertised_name)
? `<div class="alias">Listed on the AIBAST SharePoint as <b>${esc(sol.sharepoint_list_name)}</b>.</div>` : ''}
<div class="chips">
${chip('Industries', sol.industries)}
${chip('Personas', sol.personas)}
${chip('Featured tools', sol.featured_tools)}
</div>
<div class="assets">
${sol.onepager ? '<span class="asset">✓ Published one-pager</span>' : ''}
${sol.demo_video ? '<span class="asset">✓ Demo video filmed</span>' : ''}
${agent ? '<span class="asset">✓ Agent implemented</span>' : ''}
<a class="asset" href="request-info.html">Request the one-pager and demo video →</a>
</div>
</div>
${getBlock(LIB_REC)}
<div class="section" id="prepare-meeting">
<h2>Prepare a meeting with this</h2>
<div class="sub">Paste this line into your own AI. It returns a one-page meeting pack built on this example, using sample data only.</div>
${copyLine(prepLine(sol))}
</div>
<div class="section">
<h2>The scenario the field was shown</h2>
<div class="sub">Straight from the published one-pager.</div>
<div class="story">
<div class="col situation"><h3>Situation</h3><ul>${(sol.customer_scenario || []).map(x => `<li>${esc(x)}</li>`).join('') || '<li>—</li>'}</ul></div>
<div class="col helped"><h3>How the agent helped</h3><ul>${(sol.capabilities || []).map(x => `<li>${esc(x)}</li>`).join('') || '<li>—</li>'}</ul></div>
<div class="col opportunity"><h3>Outcomes</h3><ul>${(sol.outcomes || []).map(x => `<li>${esc(x)}</li>`).join('') || '<li>—</li>'}</ul></div>
</div>
</div>
<details class="more" id="more-built">
<summary>More: how it is built, and running the file yourself</summary>
<div class="section">
<h2>Promise to implementation</h2>
<div class="sub">Every advertised capability, and the agent operation that delivers it.</div>
<table>
<thead><tr><th>Advertised capability</th><th>Agent operation</th><th>Status</th></tr></thead>
<tbody>${capRows.map(r => `<tr>
<td>${esc(r.advertised)}</td>
<td class="op">${r.operation ? `<code>${esc(r.operation)}</code>` : '<span style="color:var(--text-muted)">—</span>'}</td>
<td>${r.operation && ops.some(o => o.operation === r.operation) ? '<span class="ok">delivered</span>' : '<span style="color:var(--text-muted)">not mapped</span>'}</td>
</tr>`).join('')}</tbody>
</table>
</div>
${ops.length ? `<div class="section">
<h2>What it actually returns</h2>
<div class="sub">Real output from the agent, captured ${esc(SAMPLE.captured)}. Not a mockup — this is the string the Brainstem hands back.</div>
<div class="tabs" id="op-tabs">${ops.map((o, i) =>
`<button class="tab${i === 0 ? ' active' : ''}" data-op="${esc(o.operation)}">${esc(o.operation)}</button>`).join('')}</div>
<div class="output" id="op-output"></div>
</div>` : ''}
<div class="section">
<h2>Run it</h2>
<div class="sub">Drop the file into a running Brainstem; agents reload from disk on the next request.</div>
${file ? copyLine(`curl -fsSL ${RAW}/${encodeURI(file)} -o ${AGENT_DIR}/${file.split('/').pop()}`) : ''}
${ops.length > 1 ? `<p class="note" style="margin-top:12px">Then ask it, in the Brainstem chat:
${ops.slice(1, 3).map(o => `<br> · <i>“Run ${esc(o.operation)} on ${esc(agent?.display_name || '')}”</i>`).join('')}</p>` : ''}
</div>
<div class="section">
<h2>Provenance</h2>
<dl class="kv">
<dt>Advertised as</dt><dd>${esc(sol.advertised_display || sol.advertised_name)} · solution #${esc(sol.slot)}</dd>
<dt>SharePoint listing</dt><dd>${esc(sol.sharepoint_list_name || '—')}</dd>
<dt>Repo agent</dt><dd class="mono">${esc(sol.repo_agent)}</dd>
<dt>Source file</dt><dd>${file ? `<a href="${BLOB}/${encodeURI(file)}" target="_blank" rel="noopener">${esc(file)}</a>` : '—'}</dd>
<dt>Version / size</dt><dd>${esc(agent?.version || '—')} · ${num(agent?._lines)} lines</dd>
<dt>Data plane</dt><dd>Static synthetic data shaped to the real sources — no live endpoint required.</dd>
</dl>
</div>
</details>
<footer>
Advertised catalog in <a href="solutions.json">solutions.json</a> ·
<a href="index.html">all ${sols.length} solutions</a> ·
<a href="https://github.com/${OWNER}/${REPO}" target="_blank" rel="noopener">${OWNER}/${REPO}</a>
</footer>`;
if (ops.length) {
activeOp = ops[0].operation;
document.querySelectorAll('#op-tabs .tab').forEach(el => el.onclick = () => {
activeOp = el.dataset.op;
document.querySelectorAll('#op-tabs .tab').forEach(x => x.classList.toggle('active', x.dataset.op === activeOp));
paintOutput(ops);
});
paintOutput(ops);
}
}
function paintOutput(ops) {
const o = ops.find(x => x.operation === activeOp) || ops[0];
document.getElementById('op-output').innerHTML =
`<div class="label">${esc(o.label)}</div>` + md(o.output);
}
// A copy line is a real button: Tab reaches it, Enter or Space copies the command.
// One line for the person's own AI, the same line the library record publishes.
const GET_AIS = [
['GitHub Copilot in Visual Studio Code', 'Open Copilot Chat, choose Agent mode, and paste the line.'],
['GitHub Copilot CLI', 'Start Copilot in a terminal and paste the line.'],
['Another AI', 'Use an AI assistant that can run commands on your computer. A chat-only assistant cannot do the setup.'],
];
function getBlock(rec) {
const prompt = rec?.get?.prompt;
if (!prompt) return '';
const line = prompt.replace('{pages}', PAGES_BASE);
return `<div class="section get" id="get-agent">
<h2>Get this agent running</h2>
<div class="sub">Give this one line to your AI. It sets the agent up in your own Copilot Studio.</div>
<div class="get-ask" id="get-ask-label">Which AI do you use?</div>
<div class="get-ais" role="group" aria-labelledby="get-ask-label">${GET_AIS.map((a, i) =>
`<button type="button" class="get-ai" aria-pressed="${i === 0}" onclick="pickAi(${i})">${esc(a[0])}</button>`).join('')}</div>
<div class="get-how" id="get-how" aria-live="polite">${esc(GET_AIS[0][1])}</div>
${copyLine(line)}
<div class="get-proof"><span>Sample data only</span><span>Asks before it changes anything</span><span>Remove it any time: just ask your AI</span></div>
<a class="get-walk" href="walk.html?solution=${encodeURIComponent(rec.slug || '')}">Prefer to go step by step?</a>
</div>`;
}
function pickAi(i) {
document.querySelectorAll('.get-ai').forEach((b, n) => b.setAttribute('aria-pressed', String(n === i)));
document.getElementById('get-how').textContent = GET_AIS[i][1];
}
function copyLine(text) {
return `<button type="button" class="cmd" onclick="copyCmd(this)"><code>${esc(text)}</code><span class="cmd-label" aria-live="polite">Copy</span></button>`;
}
function copyCmd(el) {
const label = el.querySelector('.cmd-label');
navigator.clipboard.writeText(el.querySelector('code').textContent).then(() => {
el.classList.add('copied'); if (label) label.textContent = 'Copied';
setTimeout(() => { el.classList.remove('copied'); if (label) label.textContent = 'Copy'; }, 1400);
}).catch(() => {});
}
init();
</script>
</body>
</html>