aimeat 1.15.1 → 1.16.2
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/locales/en.json +60 -1
- package/dist/locales/fi.json +60 -1
- package/dist/public/css/views/agents-detail.css +279 -0
- package/dist/public/js/services/agent-tasks.js +11 -0
- package/dist/public/js/services/agents.js +8 -0
- package/dist/public/views/profile/agents/agent-card.js +5 -1
- package/dist/public/views/profile/agents/rate-modal.js +87 -0
- package/dist/public/views/profile/agents/tab-quality.js +213 -0
- package/dist/public/views/profile/agents/tab-tasks.js +4 -2
- package/dist/public/views/profile/agents-tasks-subtab.js +134 -3
- package/dist/src/generated/api-types.d.ts +238 -3
- package/dist/src/generated/api-types.d.ts.map +1 -1
- package/dist/src/models/agent-task-schemas.d.ts +28 -0
- package/dist/src/models/agent-task-schemas.d.ts.map +1 -1
- package/dist/src/models/agent-task-schemas.js +21 -0
- package/dist/src/models/agent-task-schemas.js.map +1 -1
- package/dist/src/routes/agent-activity.d.ts +3 -0
- package/dist/src/routes/agent-activity.d.ts.map +1 -1
- package/dist/src/routes/agent-activity.js +44 -0
- package/dist/src/routes/agent-activity.js.map +1 -1
- package/dist/src/routes/agent-integration.d.ts.map +1 -1
- package/dist/src/routes/agent-integration.js +4 -0
- package/dist/src/routes/agent-integration.js.map +1 -1
- package/dist/src/routes/agent-tasks.d.ts +3 -0
- package/dist/src/routes/agent-tasks.d.ts.map +1 -1
- package/dist/src/routes/agent-tasks.js +91 -1
- package/dist/src/routes/agent-tasks.js.map +1 -1
- package/dist/src/routes/agents.d.ts.map +1 -1
- package/dist/src/routes/agents.js +35 -0
- package/dist/src/routes/agents.js.map +1 -1
- package/dist/src/services/agent-statistics.d.ts +80 -0
- package/dist/src/services/agent-statistics.d.ts.map +1 -0
- package/dist/src/services/agent-statistics.js +180 -0
- package/dist/src/services/agent-statistics.js.map +1 -0
- package/dist/src/storage/interface.d.ts +43 -1
- package/dist/src/storage/interface.d.ts.map +1 -1
- package/dist/src/storage/interface.js +2 -1
- package/dist/src/storage/interface.js.map +1 -1
- package/dist/src/storage/providers/mongodb/index.d.ts.map +1 -1
- package/dist/src/storage/providers/mongodb/index.js +5 -1
- package/dist/src/storage/providers/mongodb/index.js.map +1 -1
- package/dist/src/storage/providers/sqlite/index.d.ts.map +1 -1
- package/dist/src/storage/providers/sqlite/index.js +6 -4
- package/dist/src/storage/providers/sqlite/index.js.map +1 -1
- package/dist/src/storage/providers/sqlite/repos/agent-task.d.ts.map +1 -1
- package/dist/src/storage/providers/sqlite/repos/agent-task.js +6 -4
- package/dist/src/storage/providers/sqlite/repos/agent-task.js.map +1 -1
- package/dist/src/storage/providers/sqlite/schema.d.ts.map +1 -1
- package/dist/src/storage/providers/sqlite/schema.js +9 -1
- package/dist/src/storage/providers/sqlite/schema.js.map +1 -1
- package/package.json +1 -1
- package/prisma/schema.prisma +2 -0
package/dist/locales/en.json
CHANGED
|
@@ -420,6 +420,12 @@
|
|
|
420
420
|
"title": "Task Queue",
|
|
421
421
|
"empty": "No tasks yet",
|
|
422
422
|
"newTask": "New Task",
|
|
423
|
+
"concurrency": {
|
|
424
|
+
"label": "Max concurrent tasks",
|
|
425
|
+
"hint": "1 = serial. Higher needs a concurrency-capable runner (e.g. a CrewAI daemon).",
|
|
426
|
+
"saved": "Concurrency updated",
|
|
427
|
+
"error": "Failed to update concurrency"
|
|
428
|
+
},
|
|
423
429
|
"createTask": "Create Task",
|
|
424
430
|
"cancel": "Cancel",
|
|
425
431
|
"titleLabel": "Title (optional)",
|
|
@@ -458,6 +464,21 @@
|
|
|
458
464
|
"deliverable": "Deliverable",
|
|
459
465
|
"viewDeliverable": "View",
|
|
460
466
|
"deliverableGone": "The deliverable entry no longer exists.",
|
|
467
|
+
"rate": {
|
|
468
|
+
"button": "Rate deliverable",
|
|
469
|
+
"rerate": "Re-rate",
|
|
470
|
+
"title": "Rate this deliverable",
|
|
471
|
+
"help": "Give the deliverable 1–5 stars and pick the context it should be judged in. Factual contexts should be checked against the sources, not rated on looks alone.",
|
|
472
|
+
"context": "Context",
|
|
473
|
+
"grounded": "I checked this against the sources / inputs",
|
|
474
|
+
"commentPlaceholder": "Optional: what was good or wrong?",
|
|
475
|
+
"submit": "Submit rating",
|
|
476
|
+
"submitting": "Saving...",
|
|
477
|
+
"rated": "Rated",
|
|
478
|
+
"needStars": "Pick a star rating first",
|
|
479
|
+
"success": "Rating saved",
|
|
480
|
+
"error": "Failed to save rating"
|
|
481
|
+
},
|
|
461
482
|
"cancel": "Cancel",
|
|
462
483
|
"cancelConfirm": "Cancel this task? Work that hasn't started will be skipped",
|
|
463
484
|
"cancelled": "Task cancelled",
|
|
@@ -473,6 +494,8 @@
|
|
|
473
494
|
"requestChangesError": "Failed to send change request",
|
|
474
495
|
"revisionWaiting": "Waiting for the agent to propose a revised plan.",
|
|
475
496
|
"outdatedTodos": "Previously proposed (outdated)",
|
|
497
|
+
"blurTitle": "Hide title (blur for screen recording)",
|
|
498
|
+
"unblurTitle": "Show title",
|
|
476
499
|
"builder": {
|
|
477
500
|
"title": "New Task",
|
|
478
501
|
"placeholder": "What should the agent do? Describe in plain language or technical detail.",
|
|
@@ -653,7 +676,43 @@
|
|
|
653
676
|
"directives": "Directives",
|
|
654
677
|
"agent_config": "Agent Config",
|
|
655
678
|
"activity": "Activity",
|
|
656
|
-
"services": "Services"
|
|
679
|
+
"services": "Services",
|
|
680
|
+
"quality": "Quality"
|
|
681
|
+
},
|
|
682
|
+
"quality": {
|
|
683
|
+
"performanceTitle": "Performance",
|
|
684
|
+
"performanceDesc": "How much this agent has done and how fast — computed from its tasks.",
|
|
685
|
+
"reviewsTitle": "Reviews by context",
|
|
686
|
+
"reviewsDesc": "Per-context star ratings of the agent's deliverables. Factual contexts are source-grounded.",
|
|
687
|
+
"pendingTitle": "Rate deliverables",
|
|
688
|
+
"pendingDesc": "Completed tasks you can rate. Your ratings build the per-context quality picture above.",
|
|
689
|
+
"allRated": "All completed deliverables are rated.",
|
|
690
|
+
"unrated": "Not rated",
|
|
691
|
+
"customTitle": "Custom metrics",
|
|
692
|
+
"customDesc": "Metrics the agent publishes about itself.",
|
|
693
|
+
"tasksTotal": "Tasks",
|
|
694
|
+
"tasksCompleted": "Completed",
|
|
695
|
+
"tasksFailed": "Failed",
|
|
696
|
+
"successRate": "Success rate",
|
|
697
|
+
"avgTime": "Avg make-time",
|
|
698
|
+
"events": "Events",
|
|
699
|
+
"overall": "Overall",
|
|
700
|
+
"ratings": "{count} ratings",
|
|
701
|
+
"lowConfidence": "Low confidence (small sample)",
|
|
702
|
+
"noReviews": "No reviews yet. Rate a completed task to start building quality stats.",
|
|
703
|
+
"noCustom": "No custom metrics published.",
|
|
704
|
+
"grounded": "{count} source-grounded",
|
|
705
|
+
"seconds": "s",
|
|
706
|
+
"contexts": {
|
|
707
|
+
"factual": "Factual",
|
|
708
|
+
"creative": "Creative",
|
|
709
|
+
"code": "Code",
|
|
710
|
+
"planning": "Planning",
|
|
711
|
+
"summarization": "Summarization",
|
|
712
|
+
"research": "Research",
|
|
713
|
+
"communication": "Communication",
|
|
714
|
+
"other": "Other"
|
|
715
|
+
}
|
|
657
716
|
},
|
|
658
717
|
"state": {
|
|
659
718
|
"new": "New",
|
package/dist/locales/fi.json
CHANGED
|
@@ -420,6 +420,12 @@
|
|
|
420
420
|
"title": "Tehtäväjono",
|
|
421
421
|
"empty": "Ei tehtäviä vielä",
|
|
422
422
|
"newTask": "Uusi tehtävä",
|
|
423
|
+
"concurrency": {
|
|
424
|
+
"label": "Tehtäviä rinnakkain enintään",
|
|
425
|
+
"hint": "1 = sarjallinen. Suurempi vaatii rinnakkaisuutta tukevan ajurin (esim. CrewAI-daemon).",
|
|
426
|
+
"saved": "Rinnakkaisuus päivitetty",
|
|
427
|
+
"error": "Rinnakkaisuuden päivitys epäonnistui"
|
|
428
|
+
},
|
|
423
429
|
"createTask": "Luo tehtävä",
|
|
424
430
|
"cancel": "Peruuta",
|
|
425
431
|
"titleLabel": "Otsikko (valinnainen)",
|
|
@@ -458,6 +464,21 @@
|
|
|
458
464
|
"deliverable": "Tuotos",
|
|
459
465
|
"viewDeliverable": "Näytä",
|
|
460
466
|
"deliverableGone": "Tuotosmerkintää ei ole enää olemassa.",
|
|
467
|
+
"rate": {
|
|
468
|
+
"button": "Arvioi tuotos",
|
|
469
|
+
"rerate": "Arvioi uudelleen",
|
|
470
|
+
"title": "Arvioi tämä tuotos",
|
|
471
|
+
"help": "Anna tuotokselle 1–5 tähteä ja valitse konteksti jossa sitä arvioidaan. Faktakontekstit tulisi tarkistaa lähteitä vasten, ei arvioida pelkän ulkoasun perusteella.",
|
|
472
|
+
"context": "Konteksti",
|
|
473
|
+
"grounded": "Tarkistin tämän lähteitä / syötteitä vasten",
|
|
474
|
+
"commentPlaceholder": "Valinnainen: mikä oli hyvää tai pielessä?",
|
|
475
|
+
"submit": "Tallenna arvio",
|
|
476
|
+
"submitting": "Tallennetaan...",
|
|
477
|
+
"rated": "Arvioitu",
|
|
478
|
+
"needStars": "Valitse ensin tähtiarvio",
|
|
479
|
+
"success": "Arvio tallennettu",
|
|
480
|
+
"error": "Arvion tallennus epäonnistui"
|
|
481
|
+
},
|
|
461
482
|
"cancel": "Peruuta",
|
|
462
483
|
"cancelConfirm": "Peruutetaanko tämä tehtävä? Aloittamaton työ ohitetaan",
|
|
463
484
|
"cancelled": "Tehtävä peruutettu",
|
|
@@ -473,6 +494,8 @@
|
|
|
473
494
|
"requestChangesError": "Muutospyynnön lähetys epäonnistui",
|
|
474
495
|
"revisionWaiting": "Odotetaan agentin korjattua ehdotusta.",
|
|
475
496
|
"outdatedTodos": "Aiemmin ehdotetut (vanhentuneet)",
|
|
497
|
+
"blurTitle": "Piilota otsikko (sumenna ruutunauhoitusta varten)",
|
|
498
|
+
"unblurTitle": "Näytä otsikko",
|
|
476
499
|
"builder": {
|
|
477
500
|
"title": "Uusi tehtävä",
|
|
478
501
|
"placeholder": "Mitä agentin pitäisi tehdä? Kuvaile selkokielellä tai teknisesti.",
|
|
@@ -653,7 +676,43 @@
|
|
|
653
676
|
"directives": "Ohjeistukset",
|
|
654
677
|
"agent_config": "Agenttiasetukset",
|
|
655
678
|
"activity": "Toiminta",
|
|
656
|
-
"services": "Palvelut"
|
|
679
|
+
"services": "Palvelut",
|
|
680
|
+
"quality": "Laatu"
|
|
681
|
+
},
|
|
682
|
+
"quality": {
|
|
683
|
+
"performanceTitle": "Suorituskyky",
|
|
684
|
+
"performanceDesc": "Kuinka paljon agentti on tehnyt ja kuinka nopeasti — laskettu sen tehtävistä.",
|
|
685
|
+
"reviewsTitle": "Arviot konteksteittain",
|
|
686
|
+
"reviewsDesc": "Agentin tuotosten tähtiarviot konteksteittain. Faktakontekstit ovat lähteisiin perustuvia.",
|
|
687
|
+
"pendingTitle": "Arvioi tuotokset",
|
|
688
|
+
"pendingDesc": "Valmiit tehtävät joita voit arvioida. Arviosi rakentavat yllä olevan kontekstikohtaisen laatukuvan.",
|
|
689
|
+
"allRated": "Kaikki valmiit tuotokset on arvioitu.",
|
|
690
|
+
"unrated": "Ei arvioitu",
|
|
691
|
+
"customTitle": "Omat mittarit",
|
|
692
|
+
"customDesc": "Mittarit, joita agentti julkaisee itsestään.",
|
|
693
|
+
"tasksTotal": "Tehtäviä",
|
|
694
|
+
"tasksCompleted": "Valmiit",
|
|
695
|
+
"tasksFailed": "Epäonnistuneet",
|
|
696
|
+
"successRate": "Onnistumisaste",
|
|
697
|
+
"avgTime": "Keskim. tekoaika",
|
|
698
|
+
"events": "Tapahtumia",
|
|
699
|
+
"overall": "Kokonaisuus",
|
|
700
|
+
"ratings": "{count} arviota",
|
|
701
|
+
"lowConfidence": "Matala luottamus (pieni otos)",
|
|
702
|
+
"noReviews": "Ei vielä arvioita. Arvioi valmis tehtävä aloittaaksesi laatutilastojen kerryttämisen.",
|
|
703
|
+
"noCustom": "Ei julkaistuja omia mittareita.",
|
|
704
|
+
"grounded": "{count} lähteistettyä",
|
|
705
|
+
"seconds": "s",
|
|
706
|
+
"contexts": {
|
|
707
|
+
"factual": "Faktatieto",
|
|
708
|
+
"creative": "Luova",
|
|
709
|
+
"code": "Koodi",
|
|
710
|
+
"planning": "Suunnittelu",
|
|
711
|
+
"summarization": "Tiivistäminen",
|
|
712
|
+
"research": "Tutkimus",
|
|
713
|
+
"communication": "Viestintä",
|
|
714
|
+
"other": "Muu"
|
|
715
|
+
}
|
|
657
716
|
},
|
|
658
717
|
"state": {
|
|
659
718
|
"new": "Uusi",
|
|
@@ -23,8 +23,13 @@
|
|
|
23
23
|
* v2.8.0 -- 2026-05-31 -- Add pop-out button (pf-agd-popout-btn), drag-to-reorder rows (pf-agd-dnd-*), and solo pop-out window layout (pf-agd-solo*)
|
|
24
24
|
* v2.9.0 -- 2026-05-31 -- Collapsed bar two-row layout (pf-agd-collapsed-main + pf-agd-collapsed-meta divider) to stop status overflow; move drag grip into the left margin so the card border stays flush
|
|
25
25
|
* v2.10.0 -- 2026-05-31 -- Extend the drag-row drop target left over the grip gutter (padding-left + negative margin-left) so dropping on/near the handle registers; card border stays aligned
|
|
26
|
+
* v2.11.0 -- 2026-05-31 -- Add Quality tab styles (per-context review rows, duration chips, custom-metric rows)
|
|
27
|
+
* v2.12.0 -- 2026-05-31 -- Add deliverable rating control styles (star picker, current-rating row, rate modal fields)
|
|
28
|
+
* v2.13.0 -- 2026-05-31 -- Add Quality-tab "Rate deliverables" pending-list row styles
|
|
29
|
+
* v2.14.0 -- 2026-06-01 -- Add Tasks-tab max-concurrent-tasks config row styles
|
|
26
30
|
* v2.11.0 -- 2026-05-31 -- Widen the solo pop-out window (and pf-agd-solo max-width) so the agent card matches the list-view width and the full tab bar fits
|
|
27
31
|
* v2.12.0 -- 2026-05-31 -- Add completed-task deliverable styles (pf-agd-deliverable*) linking a task to its agent-memory output key
|
|
32
|
+
* v2.13.0 -- 2026-05-31 -- Add per-task blur-title toggle styles (pf-agd-blur-toggle, pf-agd-task-title--blurred) for hiding sensitive titles in screen recordings
|
|
28
33
|
*/
|
|
29
34
|
|
|
30
35
|
/* Header row: title left, connect button right */
|
|
@@ -2528,6 +2533,29 @@
|
|
|
2528
2533
|
align-items: center;
|
|
2529
2534
|
gap: 0.5rem;
|
|
2530
2535
|
}
|
|
2536
|
+
|
|
2537
|
+
/* Per-task "hide title" toggle (eye icon) -- used to blur sensitive titles for
|
|
2538
|
+
screen recordings. Preference is browser-only (localStorage). */
|
|
2539
|
+
.pf .pf-agd-blur-toggle {
|
|
2540
|
+
flex-shrink: 0;
|
|
2541
|
+
background: transparent;
|
|
2542
|
+
border: none;
|
|
2543
|
+
padding: 0;
|
|
2544
|
+
margin: 0;
|
|
2545
|
+
font-size: 0.95rem;
|
|
2546
|
+
line-height: 1;
|
|
2547
|
+
cursor: pointer;
|
|
2548
|
+
opacity: 0.45;
|
|
2549
|
+
transition: opacity 0.15s ease;
|
|
2550
|
+
}
|
|
2551
|
+
.pf .pf-agd-blur-toggle:hover { opacity: 0.9; }
|
|
2552
|
+
.pf .pf-agd-blur-toggle--on { opacity: 0.85; }
|
|
2553
|
+
|
|
2554
|
+
.pf .pf-agd-task-title--blurred {
|
|
2555
|
+
filter: blur(5px);
|
|
2556
|
+
user-select: none;
|
|
2557
|
+
cursor: pointer;
|
|
2558
|
+
}
|
|
2531
2559
|
.pf .agd-task-group-title ,
|
|
2532
2560
|
.pf .pf-agd-task-group-title {
|
|
2533
2561
|
margin-top: 0.5rem;
|
|
@@ -2655,3 +2683,254 @@
|
|
|
2655
2683
|
border-left: 2px solid var(--info, #3B82F6);
|
|
2656
2684
|
padding-left: 0.5rem;
|
|
2657
2685
|
}
|
|
2686
|
+
|
|
2687
|
+
/* ── Quality tab ── */
|
|
2688
|
+
|
|
2689
|
+
.pf .pf-agd-quality-desc {
|
|
2690
|
+
font-size: 0.8rem;
|
|
2691
|
+
color: var(--text-dim, #6B7280);
|
|
2692
|
+
margin: 0.25rem 0 0.75rem;
|
|
2693
|
+
line-height: 1.45;
|
|
2694
|
+
}
|
|
2695
|
+
|
|
2696
|
+
.pf .pf-agd-quality .pf-agd-section-title {
|
|
2697
|
+
margin-top: 1.25rem;
|
|
2698
|
+
}
|
|
2699
|
+
|
|
2700
|
+
/* Duration-by-context chips under the performance cards */
|
|
2701
|
+
.pf .pf-agd-quality-durations {
|
|
2702
|
+
display: flex;
|
|
2703
|
+
flex-wrap: wrap;
|
|
2704
|
+
gap: 0.4rem;
|
|
2705
|
+
margin-bottom: 0.5rem;
|
|
2706
|
+
}
|
|
2707
|
+
.pf .pf-agd-quality-dur-chip {
|
|
2708
|
+
font-size: 0.75rem;
|
|
2709
|
+
color: var(--text-dim, #6B7280);
|
|
2710
|
+
background: var(--bg-dim, #F3F4F6);
|
|
2711
|
+
border: 1px solid var(--border, #E5E7EB);
|
|
2712
|
+
border-radius: 6px;
|
|
2713
|
+
padding: 0.15rem 0.5rem;
|
|
2714
|
+
}
|
|
2715
|
+
|
|
2716
|
+
/* Per-context review rows */
|
|
2717
|
+
.pf .pf-agd-quality-reviews {
|
|
2718
|
+
display: flex;
|
|
2719
|
+
flex-direction: column;
|
|
2720
|
+
gap: 0.5rem;
|
|
2721
|
+
}
|
|
2722
|
+
.pf .pf-agd-quality-review-row {
|
|
2723
|
+
border: 1px solid var(--border, #E5E7EB);
|
|
2724
|
+
border-radius: 8px;
|
|
2725
|
+
padding: 0.6rem 0.75rem;
|
|
2726
|
+
background: var(--card-bg, #FFFFFF);
|
|
2727
|
+
}
|
|
2728
|
+
.pf .pf-agd-quality-review-head {
|
|
2729
|
+
display: flex;
|
|
2730
|
+
align-items: center;
|
|
2731
|
+
flex-wrap: wrap;
|
|
2732
|
+
gap: 0.5rem;
|
|
2733
|
+
}
|
|
2734
|
+
.pf .pf-agd-quality-ctx {
|
|
2735
|
+
font-weight: 600;
|
|
2736
|
+
color: var(--text, #1A1A2E);
|
|
2737
|
+
min-width: 7rem;
|
|
2738
|
+
}
|
|
2739
|
+
.pf .pf-agd-quality-stars {
|
|
2740
|
+
color: var(--accent, #E8564A);
|
|
2741
|
+
letter-spacing: 1px;
|
|
2742
|
+
}
|
|
2743
|
+
.pf .pf-agd-quality-avg {
|
|
2744
|
+
font-weight: 600;
|
|
2745
|
+
color: var(--text, #1A1A2E);
|
|
2746
|
+
}
|
|
2747
|
+
.pf .pf-agd-quality-n {
|
|
2748
|
+
font-size: 0.75rem;
|
|
2749
|
+
color: var(--text-muted, #9CA3AF);
|
|
2750
|
+
}
|
|
2751
|
+
.pf .pf-agd-quality-lowconf {
|
|
2752
|
+
font-size: 0.7rem;
|
|
2753
|
+
color: var(--warning, #D97706);
|
|
2754
|
+
border: 1px solid var(--warning, #D97706);
|
|
2755
|
+
border-radius: 6px;
|
|
2756
|
+
padding: 0.05rem 0.4rem;
|
|
2757
|
+
}
|
|
2758
|
+
.pf .pf-agd-quality-review-meta {
|
|
2759
|
+
font-size: 0.72rem;
|
|
2760
|
+
color: var(--text-muted, #9CA3AF);
|
|
2761
|
+
margin-top: 0.3rem;
|
|
2762
|
+
}
|
|
2763
|
+
.pf .pf-agd-quality-overall {
|
|
2764
|
+
margin-top: 0.4rem;
|
|
2765
|
+
font-size: 0.85rem;
|
|
2766
|
+
color: var(--text-dim, #6B7280);
|
|
2767
|
+
}
|
|
2768
|
+
.pf .pf-agd-quality-overall .pf-agd-quality-stars,
|
|
2769
|
+
.pf .pf-agd-quality-overall {
|
|
2770
|
+
letter-spacing: 0.5px;
|
|
2771
|
+
}
|
|
2772
|
+
|
|
2773
|
+
/* Custom metric rows */
|
|
2774
|
+
.pf .pf-agd-quality-custom {
|
|
2775
|
+
display: flex;
|
|
2776
|
+
flex-direction: column;
|
|
2777
|
+
gap: 0.3rem;
|
|
2778
|
+
}
|
|
2779
|
+
.pf .pf-agd-quality-custom-row {
|
|
2780
|
+
display: flex;
|
|
2781
|
+
justify-content: space-between;
|
|
2782
|
+
gap: 1rem;
|
|
2783
|
+
font-size: 0.8rem;
|
|
2784
|
+
padding: 0.3rem 0;
|
|
2785
|
+
border-bottom: 1px solid var(--border, #E5E7EB);
|
|
2786
|
+
}
|
|
2787
|
+
.pf .pf-agd-quality-custom-key {
|
|
2788
|
+
color: var(--text-dim, #6B7280);
|
|
2789
|
+
font-family: var(--font-mono, monospace);
|
|
2790
|
+
}
|
|
2791
|
+
.pf .pf-agd-quality-custom-val {
|
|
2792
|
+
color: var(--text, #1A1A2E);
|
|
2793
|
+
text-align: right;
|
|
2794
|
+
word-break: break-word;
|
|
2795
|
+
}
|
|
2796
|
+
|
|
2797
|
+
/* ── Deliverable rating (Tasks tab) ── */
|
|
2798
|
+
|
|
2799
|
+
/* Current rating + rate/re-rate button row under a done task's deliverable */
|
|
2800
|
+
.pf .pf-agd-rate-row {
|
|
2801
|
+
display: flex;
|
|
2802
|
+
align-items: center;
|
|
2803
|
+
flex-wrap: wrap;
|
|
2804
|
+
gap: 0.5rem;
|
|
2805
|
+
margin: 0.5rem 0;
|
|
2806
|
+
}
|
|
2807
|
+
.pf .pf-agd-rate-current {
|
|
2808
|
+
display: inline-flex;
|
|
2809
|
+
align-items: center;
|
|
2810
|
+
flex-wrap: wrap;
|
|
2811
|
+
gap: 0.5rem;
|
|
2812
|
+
font-size: 0.85rem;
|
|
2813
|
+
}
|
|
2814
|
+
.pf .pf-agd-rate-current-stars {
|
|
2815
|
+
color: var(--accent, #E8564A);
|
|
2816
|
+
letter-spacing: 1px;
|
|
2817
|
+
}
|
|
2818
|
+
.pf .pf-agd-rate-current-ctx {
|
|
2819
|
+
color: var(--text-dim, #6B7280);
|
|
2820
|
+
font-weight: 600;
|
|
2821
|
+
}
|
|
2822
|
+
.pf .pf-agd-rate-current-comment {
|
|
2823
|
+
color: var(--text-muted, #9CA3AF);
|
|
2824
|
+
font-style: italic;
|
|
2825
|
+
}
|
|
2826
|
+
|
|
2827
|
+
/* Star picker inside the rate modal */
|
|
2828
|
+
.pf .pf-agd-rate-stars {
|
|
2829
|
+
display: flex;
|
|
2830
|
+
gap: 0.15rem;
|
|
2831
|
+
margin: 0.5rem 0 0.75rem;
|
|
2832
|
+
}
|
|
2833
|
+
.pf .pf-agd-rate-star {
|
|
2834
|
+
background: none;
|
|
2835
|
+
border: none;
|
|
2836
|
+
cursor: pointer;
|
|
2837
|
+
font-size: 1.6rem;
|
|
2838
|
+
line-height: 1;
|
|
2839
|
+
color: var(--border, #E5E7EB);
|
|
2840
|
+
padding: 0;
|
|
2841
|
+
transition: color 0.12s;
|
|
2842
|
+
}
|
|
2843
|
+
.pf .pf-agd-rate-star:hover {
|
|
2844
|
+
color: var(--accent, #E8564A);
|
|
2845
|
+
}
|
|
2846
|
+
.pf .pf-agd-rate-star--on {
|
|
2847
|
+
color: var(--accent, #E8564A);
|
|
2848
|
+
}
|
|
2849
|
+
|
|
2850
|
+
/* Context select + grounded checkbox rows in the rate modal */
|
|
2851
|
+
.pf .pf-agd-rate-field {
|
|
2852
|
+
display: flex;
|
|
2853
|
+
align-items: center;
|
|
2854
|
+
gap: 0.5rem;
|
|
2855
|
+
margin-bottom: 0.6rem;
|
|
2856
|
+
font-size: 0.85rem;
|
|
2857
|
+
color: var(--text-dim, #6B7280);
|
|
2858
|
+
}
|
|
2859
|
+
.pf .pf-agd-rate-field select {
|
|
2860
|
+
flex: 1;
|
|
2861
|
+
}
|
|
2862
|
+
.pf .pf-agd-rate-check {
|
|
2863
|
+
display: flex;
|
|
2864
|
+
align-items: center;
|
|
2865
|
+
gap: 0.5rem;
|
|
2866
|
+
margin-bottom: 0.6rem;
|
|
2867
|
+
font-size: 0.85rem;
|
|
2868
|
+
color: var(--text, #1A1A2E);
|
|
2869
|
+
cursor: pointer;
|
|
2870
|
+
}
|
|
2871
|
+
|
|
2872
|
+
/* Quality tab "Rate deliverables" pending list */
|
|
2873
|
+
.pf .pf-agd-quality-pending {
|
|
2874
|
+
display: flex;
|
|
2875
|
+
flex-direction: column;
|
|
2876
|
+
gap: 0.4rem;
|
|
2877
|
+
}
|
|
2878
|
+
.pf .pf-agd-quality-pending-row {
|
|
2879
|
+
display: flex;
|
|
2880
|
+
align-items: center;
|
|
2881
|
+
gap: 0.5rem;
|
|
2882
|
+
padding: 0.4rem 0.5rem;
|
|
2883
|
+
border: 1px solid var(--border, #E5E7EB);
|
|
2884
|
+
border-radius: 8px;
|
|
2885
|
+
background: var(--card-bg, #FFFFFF);
|
|
2886
|
+
}
|
|
2887
|
+
.pf .pf-agd-quality-pending-title {
|
|
2888
|
+
flex: 1;
|
|
2889
|
+
min-width: 0;
|
|
2890
|
+
overflow: hidden;
|
|
2891
|
+
text-overflow: ellipsis;
|
|
2892
|
+
white-space: nowrap;
|
|
2893
|
+
font-size: 0.85rem;
|
|
2894
|
+
color: var(--text, #1A1A2E);
|
|
2895
|
+
}
|
|
2896
|
+
.pf .pf-agd-quality-pending-rated {
|
|
2897
|
+
font-size: 0.8rem;
|
|
2898
|
+
color: var(--accent, #E8564A);
|
|
2899
|
+
letter-spacing: 0.5px;
|
|
2900
|
+
white-space: nowrap;
|
|
2901
|
+
}
|
|
2902
|
+
.pf .pf-agd-quality-pending-unrated {
|
|
2903
|
+
font-size: 0.72rem;
|
|
2904
|
+
color: var(--text-muted, #9CA3AF);
|
|
2905
|
+
border: 1px solid var(--border, #E5E7EB);
|
|
2906
|
+
border-radius: 6px;
|
|
2907
|
+
padding: 0.05rem 0.4rem;
|
|
2908
|
+
white-space: nowrap;
|
|
2909
|
+
}
|
|
2910
|
+
|
|
2911
|
+
/* Tasks tab — max concurrent tasks runner config */
|
|
2912
|
+
.pf .pf-agd-concurrency {
|
|
2913
|
+
display: flex;
|
|
2914
|
+
align-items: center;
|
|
2915
|
+
flex-wrap: wrap;
|
|
2916
|
+
gap: 0.5rem;
|
|
2917
|
+
margin: 0.25rem 0 0.75rem;
|
|
2918
|
+
font-size: 0.85rem;
|
|
2919
|
+
}
|
|
2920
|
+
.pf .pf-agd-concurrency-label {
|
|
2921
|
+
color: var(--text-dim, #6B7280);
|
|
2922
|
+
font-weight: 600;
|
|
2923
|
+
}
|
|
2924
|
+
.pf .pf-agd-concurrency-input {
|
|
2925
|
+
width: 4rem;
|
|
2926
|
+
padding: 0.25rem 0.4rem;
|
|
2927
|
+
border: 1px solid var(--border, #E5E7EB);
|
|
2928
|
+
border-radius: 6px;
|
|
2929
|
+
background: var(--card-bg, #FFFFFF);
|
|
2930
|
+
color: var(--text, #1A1A2E);
|
|
2931
|
+
font-size: 0.85rem;
|
|
2932
|
+
}
|
|
2933
|
+
.pf .pf-agd-concurrency-hint {
|
|
2934
|
+
color: var(--text-muted, #9CA3AF);
|
|
2935
|
+
font-size: 0.75rem;
|
|
2936
|
+
}
|
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
* @version-history
|
|
7
7
|
* v1.0.0 -- 2026-05-21 -- Initial creation for Agent Dashboard Phase 1
|
|
8
8
|
* v1.1.0 -- 2026-05-29 -- Add requestChanges() for the owner-asks-agent-to-revise-todos flow.
|
|
9
|
+
* v1.2.0 -- 2026-05-31 -- Add rateTask() and getAgentStatistics() for the Quality tab.
|
|
9
10
|
*/
|
|
10
11
|
import { apiGet, apiPost, apiDelete } from '/js/api.js';
|
|
11
12
|
|
|
@@ -49,3 +50,13 @@ export async function requestChanges(agentName, taskId, message) {
|
|
|
49
50
|
export async function listEvents(agentName, taskId) {
|
|
50
51
|
return apiGet(`/v1/agents/${encodeURIComponent(agentName)}/tasks/${encodeURIComponent(taskId)}/events`);
|
|
51
52
|
}
|
|
53
|
+
|
|
54
|
+
/** Review a completed task's deliverable. body: { stars, context, comment?, source_grounded?, unsupported?, evaluated_model? } */
|
|
55
|
+
export async function rateTask(agentName, taskId, body) {
|
|
56
|
+
return apiPost(`/v1/agents/${encodeURIComponent(agentName)}/tasks/${encodeURIComponent(taskId)}/rate`, body);
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
/** Quality tab: recomputed performance + per-context review rollups + custom metrics. */
|
|
60
|
+
export async function getAgentStatistics(agentName) {
|
|
61
|
+
return apiGet(`/v1/agents/${encodeURIComponent(agentName)}/statistics`);
|
|
62
|
+
}
|
|
@@ -30,6 +30,14 @@ export async function updateAgentScopes(name, scopes) {
|
|
|
30
30
|
});
|
|
31
31
|
}
|
|
32
32
|
|
|
33
|
+
/** Set how many tasks the agent's runner may process concurrently (1–20). */
|
|
34
|
+
export async function setMaxConcurrentTasks(name, max) {
|
|
35
|
+
return api(`/v1/agents/${encodeURIComponent(name)}/max-concurrent-tasks`, {
|
|
36
|
+
method: 'PATCH',
|
|
37
|
+
body: JSON.stringify({ max_concurrent_tasks: max }),
|
|
38
|
+
});
|
|
39
|
+
}
|
|
40
|
+
|
|
33
41
|
/** Get agent CORS origins. */
|
|
34
42
|
export async function getAgentCors(name) {
|
|
35
43
|
const data = await apiGet(`/v1/agents/${encodeURIComponent(name)}/cors`);
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* @file agent-card.js
|
|
3
3
|
* @description Agent card component with collapsed/expanded states,
|
|
4
|
-
* Two-Zone Header (identity + state-dependent status), and
|
|
4
|
+
* Two-Zone Header (identity + state-dependent status), and tab bar.
|
|
5
5
|
* @version-history
|
|
6
|
+
* v1.8.0 -- 2026-05-31 -- Add Quality tab (per-context reviews + performance + custom stats)
|
|
6
7
|
* v1.0.0 -- 2026-05-24 -- Initial creation for Agent Detail Tab-View
|
|
7
8
|
* v1.1.0 -- 2026-05-24 -- Fix C6: remove GAII from Zone 1, M1: add Next prefix, C1: production stats, C2: problem action buttons
|
|
8
9
|
* v1.3.0 -- 2026-05-24 -- Audit fix: use proper down arrow glyph for collapse icon
|
|
@@ -36,6 +37,7 @@ import TabDataAccess from './tab-data-access.js';
|
|
|
36
37
|
import TabDirectives from './tab-directives.js';
|
|
37
38
|
import TabAgentConfig from './tab-agent-config.js';
|
|
38
39
|
import TabActivity from './tab-activity.js';
|
|
40
|
+
import TabQuality from './tab-quality.js';
|
|
39
41
|
import TabServices from './tab-services.js';
|
|
40
42
|
|
|
41
43
|
const html = htm.bind(h);
|
|
@@ -50,6 +52,7 @@ const TABS = [
|
|
|
50
52
|
{ id: 'directives', key: 'profile.agents.detail.tabs.directives' },
|
|
51
53
|
{ id: 'agent-config', key: 'profile.agents.detail.tabs.agent_config' },
|
|
52
54
|
{ id: 'activity', key: 'profile.agents.detail.tabs.activity' },
|
|
55
|
+
{ id: 'quality', key: 'profile.agents.detail.tabs.quality' },
|
|
53
56
|
{ id: 'services', key: 'profile.agents.detail.tabs.services' },
|
|
54
57
|
];
|
|
55
58
|
|
|
@@ -488,6 +491,7 @@ function renderTabContent(activeTab, agent, onboarding, session, showToast, allA
|
|
|
488
491
|
case 'directives': return html`<${TabDirectives} ...${props} />`;
|
|
489
492
|
case 'agent-config': return html`<${TabAgentConfig} ...${props} />`;
|
|
490
493
|
case 'activity': return html`<${TabActivity} ...${props} />`;
|
|
494
|
+
case 'quality': return html`<${TabQuality} ...${props} />`;
|
|
491
495
|
case 'services': return html`<${TabServices} ...${props} />`;
|
|
492
496
|
default: return null;
|
|
493
497
|
}
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @file rate-modal.js
|
|
3
|
+
* @description Shared "rate a deliverable" modal — 1–5 stars, quality context,
|
|
4
|
+
* an optional "checked against sources" flag, and a comment. Submits the
|
|
5
|
+
* POST /v1/agents/:name/tasks/:id/rate body shape. Used by both the Tasks
|
|
6
|
+
* sub-tab (rate from the task row) and the Quality tab (rate from the
|
|
7
|
+
* pending-deliverables list). Pre-fills from an existing rating so the same
|
|
8
|
+
* modal also does re-rate.
|
|
9
|
+
* @structure
|
|
10
|
+
* - RATE_CONTEXTS -- the RatingContext enum (mirrors src/storage/interface.ts)
|
|
11
|
+
* - RateModal (default export) -- the modal component
|
|
12
|
+
* @usage
|
|
13
|
+
* import RateModal, { RATE_CONTEXTS } from './rate-modal.js';
|
|
14
|
+
* <RateModal open onClose onSubmit submitting existing=${task.rating} />
|
|
15
|
+
* @version-history
|
|
16
|
+
* v1.0.0 -- 2026-05-31 -- Extracted from agents-tasks-subtab.js so the Quality
|
|
17
|
+
* tab can reuse the same rating modal.
|
|
18
|
+
*/
|
|
19
|
+
import { h } from 'preact';
|
|
20
|
+
import { useState, useEffect } from 'preact/hooks';
|
|
21
|
+
import htm from 'htm';
|
|
22
|
+
import { t } from '/js/i18n.js';
|
|
23
|
+
import { Modal } from '/components/Modal.js';
|
|
24
|
+
|
|
25
|
+
const html = htm.bind(h);
|
|
26
|
+
|
|
27
|
+
// Quality contexts an owner can pick when rating a deliverable. Mirrors the
|
|
28
|
+
// RatingContext enum in src/storage/interface.ts; labels come from the shared
|
|
29
|
+
// profile.agents.detail.quality.contexts.* i18n block.
|
|
30
|
+
export const RATE_CONTEXTS = ['factual', 'creative', 'code', 'planning', 'summarization', 'research', 'communication', 'other'];
|
|
31
|
+
|
|
32
|
+
export default function RateModal({ open, onClose, onSubmit, submitting, existing }) {
|
|
33
|
+
const [stars, setStars] = useState(existing?.stars || 0);
|
|
34
|
+
const [context, setContext] = useState(existing?.context || 'creative');
|
|
35
|
+
const [grounded, setGrounded] = useState(existing?.sourceGrounded || false);
|
|
36
|
+
const [comment, setComment] = useState(existing?.comment || '');
|
|
37
|
+
useEffect(() => {
|
|
38
|
+
if (open) {
|
|
39
|
+
setStars(existing?.stars || 0);
|
|
40
|
+
setContext(existing?.context || 'creative');
|
|
41
|
+
setGrounded(existing?.sourceGrounded || false);
|
|
42
|
+
setComment(existing?.comment || '');
|
|
43
|
+
}
|
|
44
|
+
}, [open]);
|
|
45
|
+
function handleSend() {
|
|
46
|
+
if (!stars) return;
|
|
47
|
+
const body = { stars, context, source_grounded: grounded };
|
|
48
|
+
const c = comment.trim();
|
|
49
|
+
if (c) body.comment = c;
|
|
50
|
+
onSubmit(body);
|
|
51
|
+
}
|
|
52
|
+
return html`<${Modal} open=${open} onClose=${onClose} title=${t('profile.agents.tasks.rate.title')}>
|
|
53
|
+
<p class="pf-agd-modal-help">${t('profile.agents.tasks.rate.help')}</p>
|
|
54
|
+
<div class="pf-agd-rate-stars" role="radiogroup">
|
|
55
|
+
${[1, 2, 3, 4, 5].map(n => html`
|
|
56
|
+
<button key=${n}
|
|
57
|
+
class=${`pf-agd-rate-star ${n <= stars ? 'pf-agd-rate-star--on' : ''}`}
|
|
58
|
+
onClick=${() => setStars(n)}
|
|
59
|
+
aria-label=${String(n)}
|
|
60
|
+
aria-pressed=${n <= stars}>★</button>
|
|
61
|
+
`)}
|
|
62
|
+
</div>
|
|
63
|
+
<label class="pf-agd-rate-field">
|
|
64
|
+
<span>${t('profile.agents.tasks.rate.context')}</span>
|
|
65
|
+
<select value=${context} onChange=${e => setContext(e.target.value)}>
|
|
66
|
+
${RATE_CONTEXTS.map(c => html`<option key=${c} value=${c}>${t(`profile.agents.detail.quality.contexts.${c}`)}</option>`)}
|
|
67
|
+
</select>
|
|
68
|
+
</label>
|
|
69
|
+
<label class="pf-agd-rate-check">
|
|
70
|
+
<input type="checkbox" checked=${grounded} onChange=${e => setGrounded(e.target.checked)} />
|
|
71
|
+
<span>${t('profile.agents.tasks.rate.grounded')}</span>
|
|
72
|
+
</label>
|
|
73
|
+
<textarea
|
|
74
|
+
class="pf-agd-revision-textarea"
|
|
75
|
+
placeholder=${t('profile.agents.tasks.rate.commentPlaceholder')}
|
|
76
|
+
value=${comment}
|
|
77
|
+
onInput=${e => setComment(e.target.value)}
|
|
78
|
+
rows=${3}
|
|
79
|
+
></textarea>
|
|
80
|
+
<div class="modal-footer">
|
|
81
|
+
<button class="btn-ghost" onClick=${onClose} disabled=${submitting}>${t('common.cancel') || 'Cancel'}</button>
|
|
82
|
+
<button class="btn-primary" onClick=${handleSend} disabled=${submitting || !stars}>
|
|
83
|
+
${submitting ? t('profile.agents.tasks.rate.submitting') : t('profile.agents.tasks.rate.submit')}
|
|
84
|
+
</button>
|
|
85
|
+
</div>
|
|
86
|
+
<//>`;
|
|
87
|
+
}
|