aimeat 1.16.0 → 1.17.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/locales/en.json +56 -0
- package/dist/locales/fi.json +56 -0
- package/dist/public/css/views/agents-detail.css +265 -2
- package/dist/public/js/services/agent-tasks.js +14 -1
- package/dist/public/js/services/agents.js +8 -0
- package/dist/public/views/profile/agents/rate-modal.js +87 -0
- package/dist/public/views/profile/agents/tab-quality.js +58 -4
- package/dist/public/views/profile/agents/tab-tasks.js +4 -2
- package/dist/public/views/profile/agents-tasks-subtab.js +232 -28
- package/dist/src/config.d.ts +2 -0
- package/dist/src/config.d.ts.map +1 -1
- package/dist/src/config.js +2 -0
- package/dist/src/config.js.map +1 -1
- package/dist/src/generated/api-types.d.ts +146 -2
- package/dist/src/generated/api-types.d.ts.map +1 -1
- package/dist/src/models/agent-task-schemas.d.ts +6 -0
- package/dist/src/models/agent-task-schemas.d.ts.map +1 -1
- package/dist/src/models/agent-task-schemas.js +6 -0
- package/dist/src/models/agent-task-schemas.js.map +1 -1
- package/dist/src/routes/agent-activity.d.ts +1 -0
- package/dist/src/routes/agent-activity.d.ts.map +1 -1
- package/dist/src/routes/agent-activity.js +6 -3
- 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 +2 -0
- package/dist/src/routes/agent-tasks.d.ts.map +1 -1
- package/dist/src/routes/agent-tasks.js +118 -23
- 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/config-schema.d.ts.map +1 -1
- package/dist/src/services/config-schema.js +3 -0
- package/dist/src/services/config-schema.js.map +1 -1
- package/dist/src/storage/interface.d.ts +9 -0
- package/dist/src/storage/interface.d.ts.map +1 -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,43 @@
|
|
|
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
|
+
},
|
|
429
|
+
"bucket": {
|
|
430
|
+
"recent": "Recent",
|
|
431
|
+
"keep": "Keep",
|
|
432
|
+
"archive": "Archive",
|
|
433
|
+
"empty": {
|
|
434
|
+
"recent": "No recent tasks.",
|
|
435
|
+
"keep": "Nothing kept. Use ★ Keep on a task to pin it here.",
|
|
436
|
+
"archive": "Archive is empty."
|
|
437
|
+
}
|
|
438
|
+
},
|
|
439
|
+
"search": {
|
|
440
|
+
"toggle": "Search",
|
|
441
|
+
"placeholder": "Search tasks…",
|
|
442
|
+
"noResults": "No tasks match your search.",
|
|
443
|
+
"time": { "all": "All", "today": "Today", "7d": "7d", "30d": "30d" }
|
|
444
|
+
},
|
|
445
|
+
"triage": {
|
|
446
|
+
"keep": "Keep",
|
|
447
|
+
"archive": "Archive",
|
|
448
|
+
"restore": "Restore",
|
|
449
|
+
"keepHint": "Pin to the Keep tab (won't auto-archive)",
|
|
450
|
+
"archiveHint": "Move to the Archive tab",
|
|
451
|
+
"kept": "Moved to Keep",
|
|
452
|
+
"archived": "Archived",
|
|
453
|
+
"restored": "Restored to Recent",
|
|
454
|
+
"error": "Failed to update task"
|
|
455
|
+
},
|
|
456
|
+
"memory": {
|
|
457
|
+
"show": "Memory entries",
|
|
458
|
+
"none": "No memory entries linked to this task yet."
|
|
459
|
+
},
|
|
423
460
|
"createTask": "Create Task",
|
|
424
461
|
"cancel": "Cancel",
|
|
425
462
|
"titleLabel": "Title (optional)",
|
|
@@ -458,6 +495,21 @@
|
|
|
458
495
|
"deliverable": "Deliverable",
|
|
459
496
|
"viewDeliverable": "View",
|
|
460
497
|
"deliverableGone": "The deliverable entry no longer exists.",
|
|
498
|
+
"rate": {
|
|
499
|
+
"button": "Rate deliverable",
|
|
500
|
+
"rerate": "Re-rate",
|
|
501
|
+
"title": "Rate this deliverable",
|
|
502
|
+
"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.",
|
|
503
|
+
"context": "Context",
|
|
504
|
+
"grounded": "I checked this against the sources / inputs",
|
|
505
|
+
"commentPlaceholder": "Optional: what was good or wrong?",
|
|
506
|
+
"submit": "Submit rating",
|
|
507
|
+
"submitting": "Saving...",
|
|
508
|
+
"rated": "Rated",
|
|
509
|
+
"needStars": "Pick a star rating first",
|
|
510
|
+
"success": "Rating saved",
|
|
511
|
+
"error": "Failed to save rating"
|
|
512
|
+
},
|
|
461
513
|
"cancel": "Cancel",
|
|
462
514
|
"cancelConfirm": "Cancel this task? Work that hasn't started will be skipped",
|
|
463
515
|
"cancelled": "Task cancelled",
|
|
@@ -663,6 +715,10 @@
|
|
|
663
715
|
"performanceDesc": "How much this agent has done and how fast — computed from its tasks.",
|
|
664
716
|
"reviewsTitle": "Reviews by context",
|
|
665
717
|
"reviewsDesc": "Per-context star ratings of the agent's deliverables. Factual contexts are source-grounded.",
|
|
718
|
+
"pendingTitle": "Rate deliverables",
|
|
719
|
+
"pendingDesc": "Completed tasks you can rate. Your ratings build the per-context quality picture above.",
|
|
720
|
+
"allRated": "All completed deliverables are rated.",
|
|
721
|
+
"unrated": "Not rated",
|
|
666
722
|
"customTitle": "Custom metrics",
|
|
667
723
|
"customDesc": "Metrics the agent publishes about itself.",
|
|
668
724
|
"tasksTotal": "Tasks",
|
package/dist/locales/fi.json
CHANGED
|
@@ -420,6 +420,43 @@
|
|
|
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
|
+
},
|
|
429
|
+
"bucket": {
|
|
430
|
+
"recent": "Viimeaikaiset",
|
|
431
|
+
"keep": "Tarpeelliset",
|
|
432
|
+
"archive": "Arkisto",
|
|
433
|
+
"empty": {
|
|
434
|
+
"recent": "Ei viimeaikaisia tehtäviä.",
|
|
435
|
+
"keep": "Ei talteen nostettuja. Käytä ★ Talteen kiinnittääksesi tehtävän tänne.",
|
|
436
|
+
"archive": "Arkisto on tyhjä."
|
|
437
|
+
}
|
|
438
|
+
},
|
|
439
|
+
"search": {
|
|
440
|
+
"toggle": "Haku",
|
|
441
|
+
"placeholder": "Hae tehtäviä…",
|
|
442
|
+
"noResults": "Mikään tehtävä ei vastaa hakua.",
|
|
443
|
+
"time": { "all": "Kaikki", "today": "Tänään", "7d": "7pv", "30d": "30pv" }
|
|
444
|
+
},
|
|
445
|
+
"triage": {
|
|
446
|
+
"keep": "Talteen",
|
|
447
|
+
"archive": "Arkistoi",
|
|
448
|
+
"restore": "Palauta",
|
|
449
|
+
"keepHint": "Kiinnitä Tarpeelliset-välilehdelle (ei auto-arkistoidu)",
|
|
450
|
+
"archiveHint": "Siirrä Arkisto-välilehdelle",
|
|
451
|
+
"kept": "Siirretty Tarpeellisiin",
|
|
452
|
+
"archived": "Arkistoitu",
|
|
453
|
+
"restored": "Palautettu Viimeaikaisiin",
|
|
454
|
+
"error": "Tehtävän päivitys epäonnistui"
|
|
455
|
+
},
|
|
456
|
+
"memory": {
|
|
457
|
+
"show": "Muistimerkinnät",
|
|
458
|
+
"none": "Tähän tehtävään ei ole vielä linkitetty muistimerkintöjä."
|
|
459
|
+
},
|
|
423
460
|
"createTask": "Luo tehtävä",
|
|
424
461
|
"cancel": "Peruuta",
|
|
425
462
|
"titleLabel": "Otsikko (valinnainen)",
|
|
@@ -458,6 +495,21 @@
|
|
|
458
495
|
"deliverable": "Tuotos",
|
|
459
496
|
"viewDeliverable": "Näytä",
|
|
460
497
|
"deliverableGone": "Tuotosmerkintää ei ole enää olemassa.",
|
|
498
|
+
"rate": {
|
|
499
|
+
"button": "Arvioi tuotos",
|
|
500
|
+
"rerate": "Arvioi uudelleen",
|
|
501
|
+
"title": "Arvioi tämä tuotos",
|
|
502
|
+
"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.",
|
|
503
|
+
"context": "Konteksti",
|
|
504
|
+
"grounded": "Tarkistin tämän lähteitä / syötteitä vasten",
|
|
505
|
+
"commentPlaceholder": "Valinnainen: mikä oli hyvää tai pielessä?",
|
|
506
|
+
"submit": "Tallenna arvio",
|
|
507
|
+
"submitting": "Tallennetaan...",
|
|
508
|
+
"rated": "Arvioitu",
|
|
509
|
+
"needStars": "Valitse ensin tähtiarvio",
|
|
510
|
+
"success": "Arvio tallennettu",
|
|
511
|
+
"error": "Arvion tallennus epäonnistui"
|
|
512
|
+
},
|
|
461
513
|
"cancel": "Peruuta",
|
|
462
514
|
"cancelConfirm": "Peruutetaanko tämä tehtävä? Aloittamaton työ ohitetaan",
|
|
463
515
|
"cancelled": "Tehtävä peruutettu",
|
|
@@ -663,6 +715,10 @@
|
|
|
663
715
|
"performanceDesc": "Kuinka paljon agentti on tehnyt ja kuinka nopeasti — laskettu sen tehtävistä.",
|
|
664
716
|
"reviewsTitle": "Arviot konteksteittain",
|
|
665
717
|
"reviewsDesc": "Agentin tuotosten tähtiarviot konteksteittain. Faktakontekstit ovat lähteisiin perustuvia.",
|
|
718
|
+
"pendingTitle": "Arvioi tuotokset",
|
|
719
|
+
"pendingDesc": "Valmiit tehtävät joita voit arvioida. Arviosi rakentavat yllä olevan kontekstikohtaisen laatukuvan.",
|
|
720
|
+
"allRated": "Kaikki valmiit tuotokset on arvioitu.",
|
|
721
|
+
"unrated": "Ei arvioitu",
|
|
666
722
|
"customTitle": "Omat mittarit",
|
|
667
723
|
"customDesc": "Mittarit, joita agentti julkaisee itsestään.",
|
|
668
724
|
"tasksTotal": "Tehtäviä",
|
|
@@ -24,6 +24,12 @@
|
|
|
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
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
|
|
30
|
+
* v2.15.0 -- 2026-06-01 -- Blur-title eye is now hover-only (revealed on task-row hover/focus) to de-clutter the list; blurred rows keep their eye visible
|
|
31
|
+
* v2.16.0 -- 2026-06-01 -- Add Tasks-tab triage UI styles (bucket segments + counts, search bar, time chips, per-task triage buttons)
|
|
32
|
+
* v2.17.0 -- 2026-06-01 -- Add per-task memory entries list styles (expanded task)
|
|
27
33
|
* 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
|
|
28
34
|
* v2.12.0 -- 2026-05-31 -- Add completed-task deliverable styles (pf-agd-deliverable*) linking a task to its agent-memory output key
|
|
29
35
|
* 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
|
|
@@ -264,7 +270,7 @@
|
|
|
264
270
|
margin-top: 0.15rem;
|
|
265
271
|
}
|
|
266
272
|
.pf .agd-task-actions ,
|
|
267
|
-
.pf .pf-agd-task-actions { display: flex; gap: 0.5rem; margin-top: 0.5rem; }
|
|
273
|
+
.pf .pf-agd-task-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; margin-top: 0.5rem; }
|
|
268
274
|
|
|
269
275
|
.pf .agd-event-log ,
|
|
270
276
|
.pf .pf-agd-event-log { max-height: 200px; overflow-y: auto; margin-top: 0.5rem; }
|
|
@@ -2542,11 +2548,19 @@
|
|
|
2542
2548
|
font-size: 0.95rem;
|
|
2543
2549
|
line-height: 1;
|
|
2544
2550
|
cursor: pointer;
|
|
2545
|
-
|
|
2551
|
+
/* Hidden by default to keep the task list uncluttered; revealed when the row
|
|
2552
|
+
is hovered or the button is focused. opacity (not display) so the title
|
|
2553
|
+
never shifts when the eye appears. A row whose title is currently hidden
|
|
2554
|
+
keeps its eye visible (see --on) so the hidden state stays discoverable. */
|
|
2555
|
+
opacity: 0;
|
|
2546
2556
|
transition: opacity 0.15s ease;
|
|
2547
2557
|
}
|
|
2558
|
+
.pf .pf-agd-task-item:hover .pf-agd-blur-toggle { opacity: 0.55; }
|
|
2548
2559
|
.pf .pf-agd-blur-toggle:hover { opacity: 0.9; }
|
|
2560
|
+
.pf .pf-agd-blur-toggle:focus-visible { opacity: 0.9; }
|
|
2561
|
+
/* A blurred (hidden-title) row shows its 🙈 at all times, hover or not. */
|
|
2549
2562
|
.pf .pf-agd-blur-toggle--on { opacity: 0.85; }
|
|
2563
|
+
.pf .pf-agd-task-item:hover .pf-agd-blur-toggle--on { opacity: 0.95; }
|
|
2550
2564
|
|
|
2551
2565
|
.pf .pf-agd-task-title--blurred {
|
|
2552
2566
|
filter: blur(5px);
|
|
@@ -2790,3 +2804,252 @@
|
|
|
2790
2804
|
text-align: right;
|
|
2791
2805
|
word-break: break-word;
|
|
2792
2806
|
}
|
|
2807
|
+
|
|
2808
|
+
/* ── Deliverable rating (Tasks tab) ── */
|
|
2809
|
+
|
|
2810
|
+
/* Current rating + rate/re-rate button row under a done task's deliverable */
|
|
2811
|
+
.pf .pf-agd-rate-row {
|
|
2812
|
+
display: flex;
|
|
2813
|
+
align-items: center;
|
|
2814
|
+
flex-wrap: wrap;
|
|
2815
|
+
gap: 0.5rem;
|
|
2816
|
+
margin: 0.5rem 0;
|
|
2817
|
+
}
|
|
2818
|
+
.pf .pf-agd-rate-current {
|
|
2819
|
+
display: inline-flex;
|
|
2820
|
+
align-items: center;
|
|
2821
|
+
flex-wrap: wrap;
|
|
2822
|
+
gap: 0.5rem;
|
|
2823
|
+
font-size: 0.85rem;
|
|
2824
|
+
}
|
|
2825
|
+
.pf .pf-agd-rate-current-stars {
|
|
2826
|
+
color: var(--accent, #E8564A);
|
|
2827
|
+
letter-spacing: 1px;
|
|
2828
|
+
}
|
|
2829
|
+
.pf .pf-agd-rate-current-ctx {
|
|
2830
|
+
color: var(--text-dim, #6B7280);
|
|
2831
|
+
font-weight: 600;
|
|
2832
|
+
}
|
|
2833
|
+
.pf .pf-agd-rate-current-comment {
|
|
2834
|
+
color: var(--text-muted, #9CA3AF);
|
|
2835
|
+
font-style: italic;
|
|
2836
|
+
}
|
|
2837
|
+
|
|
2838
|
+
/* Star picker inside the rate modal */
|
|
2839
|
+
.pf .pf-agd-rate-stars {
|
|
2840
|
+
display: flex;
|
|
2841
|
+
gap: 0.15rem;
|
|
2842
|
+
margin: 0.5rem 0 0.75rem;
|
|
2843
|
+
}
|
|
2844
|
+
.pf .pf-agd-rate-star {
|
|
2845
|
+
background: none;
|
|
2846
|
+
border: none;
|
|
2847
|
+
cursor: pointer;
|
|
2848
|
+
font-size: 1.6rem;
|
|
2849
|
+
line-height: 1;
|
|
2850
|
+
color: var(--border, #E5E7EB);
|
|
2851
|
+
padding: 0;
|
|
2852
|
+
transition: color 0.12s;
|
|
2853
|
+
}
|
|
2854
|
+
.pf .pf-agd-rate-star:hover {
|
|
2855
|
+
color: var(--accent, #E8564A);
|
|
2856
|
+
}
|
|
2857
|
+
.pf .pf-agd-rate-star--on {
|
|
2858
|
+
color: var(--accent, #E8564A);
|
|
2859
|
+
}
|
|
2860
|
+
|
|
2861
|
+
/* Context select + grounded checkbox rows in the rate modal */
|
|
2862
|
+
.pf .pf-agd-rate-field {
|
|
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-dim, #6B7280);
|
|
2869
|
+
}
|
|
2870
|
+
.pf .pf-agd-rate-field select {
|
|
2871
|
+
flex: 1;
|
|
2872
|
+
}
|
|
2873
|
+
.pf .pf-agd-rate-check {
|
|
2874
|
+
display: flex;
|
|
2875
|
+
align-items: center;
|
|
2876
|
+
gap: 0.5rem;
|
|
2877
|
+
margin-bottom: 0.6rem;
|
|
2878
|
+
font-size: 0.85rem;
|
|
2879
|
+
color: var(--text, #1A1A2E);
|
|
2880
|
+
cursor: pointer;
|
|
2881
|
+
}
|
|
2882
|
+
|
|
2883
|
+
/* Quality tab "Rate deliverables" pending list */
|
|
2884
|
+
.pf .pf-agd-quality-pending {
|
|
2885
|
+
display: flex;
|
|
2886
|
+
flex-direction: column;
|
|
2887
|
+
gap: 0.4rem;
|
|
2888
|
+
}
|
|
2889
|
+
.pf .pf-agd-quality-pending-row {
|
|
2890
|
+
display: flex;
|
|
2891
|
+
align-items: center;
|
|
2892
|
+
gap: 0.5rem;
|
|
2893
|
+
padding: 0.4rem 0.5rem;
|
|
2894
|
+
border: 1px solid var(--border, #E5E7EB);
|
|
2895
|
+
border-radius: 8px;
|
|
2896
|
+
background: var(--card-bg, #FFFFFF);
|
|
2897
|
+
}
|
|
2898
|
+
.pf .pf-agd-quality-pending-title {
|
|
2899
|
+
flex: 1;
|
|
2900
|
+
min-width: 0;
|
|
2901
|
+
overflow: hidden;
|
|
2902
|
+
text-overflow: ellipsis;
|
|
2903
|
+
white-space: nowrap;
|
|
2904
|
+
font-size: 0.85rem;
|
|
2905
|
+
color: var(--text, #1A1A2E);
|
|
2906
|
+
}
|
|
2907
|
+
.pf .pf-agd-quality-pending-rated {
|
|
2908
|
+
font-size: 0.8rem;
|
|
2909
|
+
color: var(--accent, #E8564A);
|
|
2910
|
+
letter-spacing: 0.5px;
|
|
2911
|
+
white-space: nowrap;
|
|
2912
|
+
}
|
|
2913
|
+
.pf .pf-agd-quality-pending-unrated {
|
|
2914
|
+
font-size: 0.72rem;
|
|
2915
|
+
color: var(--text-muted, #9CA3AF);
|
|
2916
|
+
border: 1px solid var(--border, #E5E7EB);
|
|
2917
|
+
border-radius: 6px;
|
|
2918
|
+
padding: 0.05rem 0.4rem;
|
|
2919
|
+
white-space: nowrap;
|
|
2920
|
+
}
|
|
2921
|
+
|
|
2922
|
+
/* Tasks tab — max concurrent tasks runner config */
|
|
2923
|
+
.pf .pf-agd-concurrency {
|
|
2924
|
+
display: flex;
|
|
2925
|
+
align-items: center;
|
|
2926
|
+
flex-wrap: wrap;
|
|
2927
|
+
gap: 0.5rem;
|
|
2928
|
+
margin: 0.25rem 0 0.75rem;
|
|
2929
|
+
font-size: 0.85rem;
|
|
2930
|
+
}
|
|
2931
|
+
.pf .pf-agd-concurrency-label {
|
|
2932
|
+
color: var(--text-dim, #6B7280);
|
|
2933
|
+
font-weight: 600;
|
|
2934
|
+
}
|
|
2935
|
+
.pf .pf-agd-concurrency-input {
|
|
2936
|
+
width: 4rem;
|
|
2937
|
+
padding: 0.25rem 0.4rem;
|
|
2938
|
+
border: 1px solid var(--border, #E5E7EB);
|
|
2939
|
+
border-radius: 6px;
|
|
2940
|
+
background: var(--card-bg, #FFFFFF);
|
|
2941
|
+
color: var(--text, #1A1A2E);
|
|
2942
|
+
font-size: 0.85rem;
|
|
2943
|
+
}
|
|
2944
|
+
.pf .pf-agd-concurrency-hint {
|
|
2945
|
+
color: var(--text-muted, #9CA3AF);
|
|
2946
|
+
font-size: 0.75rem;
|
|
2947
|
+
}
|
|
2948
|
+
|
|
2949
|
+
/* ── Tasks-tab triage: bucket segments + search + time chips ── */
|
|
2950
|
+
.pf .pf-agd-bucket-bar {
|
|
2951
|
+
display: flex;
|
|
2952
|
+
align-items: center;
|
|
2953
|
+
gap: 0.25rem;
|
|
2954
|
+
border-bottom: 1px solid var(--border, #E5E7EB);
|
|
2955
|
+
margin: 0.25rem 0 0.75rem;
|
|
2956
|
+
}
|
|
2957
|
+
.pf .pf-agd-bucket {
|
|
2958
|
+
background: none;
|
|
2959
|
+
border: none;
|
|
2960
|
+
border-bottom: 2px solid transparent;
|
|
2961
|
+
padding: 0.35rem 0.75rem;
|
|
2962
|
+
font-size: 0.85rem;
|
|
2963
|
+
color: var(--text-dim, #6B7280);
|
|
2964
|
+
cursor: pointer;
|
|
2965
|
+
transition: color 0.15s, border-color 0.15s;
|
|
2966
|
+
}
|
|
2967
|
+
.pf .pf-agd-bucket:hover { color: var(--text, #1A1A2E); }
|
|
2968
|
+
.pf .pf-agd-bucket--active {
|
|
2969
|
+
color: var(--accent, #E8564A);
|
|
2970
|
+
border-bottom-color: var(--accent, #E8564A);
|
|
2971
|
+
font-weight: 600;
|
|
2972
|
+
}
|
|
2973
|
+
.pf .pf-agd-bucket-count {
|
|
2974
|
+
display: inline-block;
|
|
2975
|
+
min-width: 1.1rem;
|
|
2976
|
+
font-size: 0.7rem;
|
|
2977
|
+
color: var(--text-muted, #9CA3AF);
|
|
2978
|
+
}
|
|
2979
|
+
.pf .pf-agd-bucket--active .pf-agd-bucket-count { color: var(--accent, #E8564A); }
|
|
2980
|
+
.pf .pf-agd-bucket-spacer { flex: 1; }
|
|
2981
|
+
.pf .pf-agd-search-toggle {
|
|
2982
|
+
background: none;
|
|
2983
|
+
border: none;
|
|
2984
|
+
cursor: pointer;
|
|
2985
|
+
font-size: 0.95rem;
|
|
2986
|
+
padding: 0.25rem 0.4rem;
|
|
2987
|
+
opacity: 0.6;
|
|
2988
|
+
border-radius: 6px;
|
|
2989
|
+
}
|
|
2990
|
+
.pf .pf-agd-search-toggle:hover { opacity: 1; }
|
|
2991
|
+
.pf .pf-agd-search-toggle--on { opacity: 1; background: var(--bg-dim, #F3F4F6); }
|
|
2992
|
+
|
|
2993
|
+
.pf .pf-agd-search-bar {
|
|
2994
|
+
display: flex;
|
|
2995
|
+
align-items: center;
|
|
2996
|
+
flex-wrap: wrap;
|
|
2997
|
+
gap: 0.5rem;
|
|
2998
|
+
margin-bottom: 0.75rem;
|
|
2999
|
+
}
|
|
3000
|
+
.pf .pf-agd-search-input {
|
|
3001
|
+
flex: 1;
|
|
3002
|
+
min-width: 12rem;
|
|
3003
|
+
padding: 0.35rem 0.6rem;
|
|
3004
|
+
border: 1px solid var(--border, #E5E7EB);
|
|
3005
|
+
border-radius: 8px;
|
|
3006
|
+
background: var(--card-bg, #FFFFFF);
|
|
3007
|
+
color: var(--text, #1A1A2E);
|
|
3008
|
+
font-size: 0.85rem;
|
|
3009
|
+
}
|
|
3010
|
+
.pf .pf-agd-time-chips { display: flex; gap: 0.25rem; }
|
|
3011
|
+
.pf .pf-agd-time-chip {
|
|
3012
|
+
background: var(--bg-dim, #F3F4F6);
|
|
3013
|
+
border: 1px solid var(--border, #E5E7EB);
|
|
3014
|
+
border-radius: 999px;
|
|
3015
|
+
padding: 0.15rem 0.6rem;
|
|
3016
|
+
font-size: 0.75rem;
|
|
3017
|
+
color: var(--text-dim, #6B7280);
|
|
3018
|
+
cursor: pointer;
|
|
3019
|
+
}
|
|
3020
|
+
.pf .pf-agd-time-chip--on {
|
|
3021
|
+
background: var(--accent, #E8564A);
|
|
3022
|
+
border-color: var(--accent, #E8564A);
|
|
3023
|
+
color: #fff;
|
|
3024
|
+
}
|
|
3025
|
+
|
|
3026
|
+
/* Triage buttons pushed to the right of the task action row */
|
|
3027
|
+
.pf .pf-agd-task-actions-spacer { flex: 1; }
|
|
3028
|
+
|
|
3029
|
+
/* Per-task memory entries (expanded task) */
|
|
3030
|
+
.pf .pf-agd-task-memory { margin: 0.5rem 0; }
|
|
3031
|
+
.pf .pf-agd-task-memory-list {
|
|
3032
|
+
display: flex;
|
|
3033
|
+
flex-direction: column;
|
|
3034
|
+
gap: 0.25rem;
|
|
3035
|
+
margin-top: 0.4rem;
|
|
3036
|
+
}
|
|
3037
|
+
.pf .pf-agd-task-memory-row {
|
|
3038
|
+
display: flex;
|
|
3039
|
+
gap: 0.5rem;
|
|
3040
|
+
align-items: baseline;
|
|
3041
|
+
font-size: 0.78rem;
|
|
3042
|
+
padding: 0.2rem 0;
|
|
3043
|
+
border-bottom: 1px solid var(--border, #E5E7EB);
|
|
3044
|
+
}
|
|
3045
|
+
.pf .pf-agd-task-memory-key {
|
|
3046
|
+
color: var(--text-dim, #6B7280);
|
|
3047
|
+
font-family: var(--font-mono, monospace);
|
|
3048
|
+
white-space: nowrap;
|
|
3049
|
+
}
|
|
3050
|
+
.pf .pf-agd-task-memory-val {
|
|
3051
|
+
color: var(--text-muted, #9CA3AF);
|
|
3052
|
+
overflow: hidden;
|
|
3053
|
+
text-overflow: ellipsis;
|
|
3054
|
+
white-space: nowrap;
|
|
3055
|
+
}
|
|
@@ -7,18 +7,31 @@
|
|
|
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
9
|
* v1.2.0 -- 2026-05-31 -- Add rateTask() and getAgentStatistics() for the Quality tab.
|
|
10
|
+
* v1.3.0 -- 2026-06-01 -- listTasks() gains bucket/q/updated_after/before params; add setTaskTriage() for the Recent/Keep/Archive buckets.
|
|
10
11
|
*/
|
|
11
|
-
import { apiGet, apiPost, apiDelete } from '/js/api.js';
|
|
12
|
+
import { apiGet, apiPost, apiDelete, api } from '/js/api.js';
|
|
12
13
|
|
|
13
14
|
export async function listTasks(agentName, opts = {}) {
|
|
14
15
|
const params = new URLSearchParams();
|
|
15
16
|
if (opts.status) params.set('status', opts.status);
|
|
17
|
+
if (opts.bucket) params.set('bucket', opts.bucket); // recent | keep | archive
|
|
18
|
+
if (opts.q) params.set('q', opts.q); // title/description search
|
|
19
|
+
if (opts.updated_after) params.set('updated_after', opts.updated_after);
|
|
20
|
+
if (opts.updated_before) params.set('updated_before', opts.updated_before);
|
|
16
21
|
if (opts.page) params.set('page', String(opts.page));
|
|
17
22
|
if (opts.per_page) params.set('per_page', String(opts.per_page));
|
|
18
23
|
const qs = params.toString();
|
|
19
24
|
return apiGet(`/v1/agents/${encodeURIComponent(agentName)}/tasks${qs ? '?' + qs : ''}`);
|
|
20
25
|
}
|
|
21
26
|
|
|
27
|
+
/** Move a task between Tasks-tab buckets. triage: 'kept' | 'archived' | null (restore). */
|
|
28
|
+
export async function setTaskTriage(agentName, taskId, triage) {
|
|
29
|
+
return api(`/v1/agents/${encodeURIComponent(agentName)}/tasks/${encodeURIComponent(taskId)}/triage`, {
|
|
30
|
+
method: 'PATCH',
|
|
31
|
+
body: JSON.stringify({ triage }),
|
|
32
|
+
});
|
|
33
|
+
}
|
|
34
|
+
|
|
22
35
|
export async function getTask(agentName, taskId) {
|
|
23
36
|
return apiGet(`/v1/agents/${encodeURIComponent(agentName)}/tasks/${encodeURIComponent(taskId)}`);
|
|
24
37
|
}
|
|
@@ -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`);
|
|
@@ -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
|
+
}
|