Export & filtering
- Replace /api/admin/agents/export/csv with /api/admin/agents/export/xlsx
(openpyxl). Multi-line system prompts stay inside one cell instead of
fragmenting into thousands of rows when opened in Excel.
- Accept filter query params on export: status, discipline, audit,
business_entity, agent_classification, autonomy_level, risks_only, search.
- Move Export/Import CSV/Delete by CSV buttons into the Agents Management
tab, drop the duplicate links from the top nav, and rebuild the cramped
filter row as a wrappable two-row layout.
- Add a Discipline dropdown to the Agents Management filter row to match
the Prompt Audit tab.
Completion-reminder emails (fix for the broken Complete-button links)
- Add h:Reply-To header to every Mailgun send so users can reply to a real
mailbox instead of noreply@. Default Nick.Viljoen@oliver.agency, overridable
via NOTIFICATION_REPLY_TO env var.
- send_completion_reminders now skips with an error log when
AGENTHUB_PUBLIC_URL is unset instead of mailing relative links email
clients can't follow.
UI polish
- Restrict the 5-second alert auto-hide to .alert-dismissible so the
load-bearing 'unresolved owner' banner stays visible until acted on.
- Move the orange brand gradient to a fixed body::before pseudo-element so
it can't be covered by the white content card or scrolled out of view.
- Lock the navbar to viewport top (position: fixed) and reserve body
padding-top so content doesn't sit beneath it.
Audit polish (carried over from previous WIP)
- Add batch-state tracking to audit_analyzer for in-flight progress visibility.
- Update PLAN-prompt-audit.md to match the shipped behaviour.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Rebuilds the agent registration form into 7 governance sections (Identity,
Classification, Autonomy, IP, Tech Stack, Data Safety, Performance, Declarations)
and introduces a completion flow for agents that come in via the LibreChat
collector without the new required fields.
- New form fields: business_entity, client_scope, agent_classification,
autonomy_level, ip_ownership, foundation_model, validated_by/date, evals_method,
plus nested safety / pii / declarations objects and a registration_complete flag.
- registration_complete defaults to true for form-submitted agents and false for
collector-created ones; existing agents are grandfathered via a startup migration.
- Owner-by-email lookup so LibreChat-synced agents surface in the user's "My Agents"
view with an Incomplete badge and Complete CTA. Submitting the completion form
reassigns created_by from the collector marker to the user.
- Daily APScheduler job sends a digest reminder email per owner with a 7-day
cooldown and 4-nudge cap (configurable). Manual trigger via
POST /api/admin/completion-reminders/send.
- Admin banner + modal for collector agents whose contact email doesn't match an
active user, with one-click reassignment.
- Gemini audit extended to also return agent_classification and an autonomy hint;
applied to agents on next batch run alongside discipline/department.
- New filter dimensions on agent management + admin dashboard: Business Entity,
Agent Type, Autonomy, plus a Compliance Risks quick toggle.
- CSV export/import gains 21 columns covering all governance fields.
- Discipline 'Optimization' renamed to 'Optimisation' with idempotent startup
migration; Gemini system prompt and template dropdowns updated.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
The default admin@agenthub.com account is not a real email address,
causing delivery failures when notifications are sent. Filter it out
from both threshold alerts and weekly digest recipient queries.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- High token usage notification now sums usage_timeline tokens over last 7 days instead of checking lifetime total
- Daily agent digest converted to weekly digest, scheduled for Monday mornings
- Email subjects and templates updated to reflect weekly timeframes
- Env var DAILY_DIGEST_HOUR renamed to WEEKLY_DIGEST_HOUR
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Three-tier role system: user, admin, readonly_admin with dashboard gating
- Client field (Yes/No) on registration with conditional Client Name and Studio Name
- Auto-tag client agents as "needs_verification" with Verification tab on admin dashboard
- Client agent email notification via Mailgun to configured recipients
- Daily agent digest email scheduled via APScheduler (configurable hour)
- Manual digest trigger endpoint: POST /api/admin/digest/send
- Role dropdown replaces is_admin checkbox in user edit modal
- Registration form reordered: Name, Description, Purpose, Client, Client Name, Studio, Tool
- Stat card CSS fix for text truncation on admin dashboard
- Updated CLAUDE.md documentation and PLAN file
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Add audit status filter (Audited/Not Audited) to agent management and admin dashboard
- Add token usage tracking: token_count per timeline entry, total_tokens on agents
- Token badge on agent cards, Total Tokens stat in usage modal, dual-axis chart
- Sort by Total Tokens option, total_tokens in CSV export
- Mailgun email notifications for high token usage (optional, non-blocking)
- Cooldown-based notification tracking in MongoDB token_notifications collection
- Add promote_admin.py utility script for user promotion
- Update CLAUDE.md documentation for all new features
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>