Repository navigation
Improve the Control Center dashboard and add Chat with this dashboard - #1713
Merged
Paul Lizer (paullizer) merged 6 commits intoOct 8, 2026
Conversation
Dashboard: - Move the dashboard aggregation into functions_control_center_dashboard.py and make the summary and insights routes thin wrappers with split activity/token caches. - Show names instead of IDs in token and activity rankings, with deleted entities labeled. - Reorganize the V2 dashboard into Directory, Sign-ins, Conversations and documents, Token usage and Most active, with plain-language definitions for DAU, WAU and MAU. - Put the token-only filters inside Token usage, next to the figures they change. - Split sign-ins from conversations, drill into the clicked stacked segment, keep token filters on drill-through, and show links only for sections the viewer can open. Chat with this dashboard: - Add a read-only, global-only Control Center action that answers only for Control Center dashboard viewers and refuses runs without a signed-in session. - Gate action discovery and manifest resolution on the caller's roles. - Add GET /api/v2/control-center/dashboard/chat-readiness and a requirements checklist that links administrators to each missing setting; when ready, open a new orchestrated chat with the prompt ready to send. - Retire the broken /api/admin/control-center/activity-trends/chat endpoint and the classic page's unreachable chat modal. Tests and docs for the dashboard, action, readiness and UI; version 0.261.294. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Move this branch's version to 0.261.297, above the base's 0.261.296, keep both sides of the Control Center route imports, and scan the shared dashboard module for reserved Cosmos keywords now that its queries left the route file. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Move this branch to 0.261.300, above the base's 0.261.299, and keep both sides of the release notes. Draw the reorganized dashboard with the shared dashboard parts the base introduced for the Approvals and Review center dashboards, and give the shared ChartPanel an optional heading level so the dashboard's chart panels nest under their section headings. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Moving the dashboard aggregation out of route_backend_control_center.py left Counter, defaultdict and json unused there, and two token helpers were imported without being used. Drop them, and the unused imports in the rewritten dashboard test. The action test still loads Semantic Kernel before any test patches sys.modules, now through importlib so the preload is explicit rather than an import that reads as unused. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
The base now uses 0.261.300 for the SharePoint and OneDrive action fix, so this branch moves to 0.261.301. Release notes keep the base's 0.261.300 section and put this branch's entries in a new 0.261.301 section above it. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Paul Lizer (paullizer)
merged commit Oct 8, 2026
fa3422d
into
paullizer-react-v2-ui
11 checks passed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
An admin review of the V2 Control Center Dashboard found four problems: rankings showed GUIDs, DAU/WAU/MAU were labelled only "unique users", the token filters sat at the top of the page so they looked page-wide but changed only the token charts, and Chat with these trends failed with HTTP 401 for every admin.
Design notes for review
functions_control_center_dashboard.py(standard library only) now holds the dashboard aggregation used by both the V2 summary/insights routes, which become thin wrappers, and the action. The 90-second cache is split into an activity half keyed by date range and a token half keyed by date range plus token filters, so changing a token filter recomputes only token figures. Names come from cached point reads, and every query passes the Cosmos query guard.control_centertype is global-only (ensure_action_type_accessrefuses it in personal and group scope).functions_action_catalog.pylists and resolves it only when the caller's roles grantcan_view_dashboard. Each function re-checks capabilities from the signed-in session, so scheduled runs fail closed. Orchestration call sites now pass the caller's captured roles explicitly (functions_orchestration_*,route_backend_orchestration.py); that threading deserves a careful look.GET /api/v2/control-center/dashboard/chat-readiness(login plus Control Center dashboard access) reports requirement states, never setting values, returns settings links only to admins, and is sent withCache-Control: no-store. The browser renders only allowlisted/admin/settings/<section>and/admin/actionspaths.composerDraftHandoff.ts) and is applied once, so a URL cannot prefill anyone's composer and a reload does not reapply it.POST /api/admin/control-center/activity-trends/chatand the classic page's chat modal and script are gone. The route readsession['user_id'], which is never set (hence the 401), wrote a malformed conversation, and V2 linked to a non-existent/chat/<id>; the classic modal had no button that opened it. The classic activity-trends GET and CSV export are unchanged./admin/settings/:sectionIddeep links and a one-shot?type=preselect in the action editor, used by the checklist links.Linked issue
N/A (no issue was filed for this work)
Release Notes & Latest Features
Is this visible to end users?
Only Control Center admins and dashboard readers see the dashboard, the chat button and the action.
Is this admin-facing (Admin Settings, governance, deployment, config)?
Should this become a Latest Feature card?
Screenshot needed for the card?
Version bump
application/single_app/config.pyVERSIONthird segment bumped, or not needed because this is docs-onlydeployers/version.txtbumped, or not needed becausedeployers/was not changedVERSIONis 0.261.297; the base branch is at 0.261.296.deployers/is unchanged.Testing / validation
All run on the final branch, after merging the latest
paullizer-react-v2-ui, with the V2 SPA rebuilt for the UI tests.python -m pytest -q -p no:cacheprovider --continue-on-collection-errors functional_tests/test_v2_control_center_dashboard.py functional_tests/test_v2_control_center_action.py functional_tests/test_orchestration_action_catalog.py functional_tests/test_v2_control_center_cosmos_query_compatibility.py functional_tests/test_control_center_token_filters.py functional_tests/test_v2_api_security.py functional_tests/route_tests/test_route_blueprint_policy_inventory.py functional_tests/route_tests/test_route_unauthenticated_policy_contract.py functional_tests/route_tests/test_route_policy_test_coverage.py functional_tests/test_docs_app_surface_coverage.py functional_tests/test_docs_site_quality.py: 154 passed, 1 failed. The failure,test_config_version_bumped_for_token_filters, asserts the exact version0.239.164and fails on the base branch too.python functional_tests/test_v2_control_center_action.py: 18/18 passed.python -O -m pytest -q functional_tests/test_v2_control_center_action.py: 18 passed.python -m pytest -q -p no:cacheprovider functional_tests/test_workspace_authoring_backend.py: 58 passed, 80 failed. The same 80 tests fail on the current base (f34094ae5) in this environment, all with the route's generic HTTP 503.npm --prefix application/v2_ui run typecheckandnpm --prefix application/v2_ui run build: passed.python -m pytest -q -m ui ui_tests/test_v2_control_center_dashboard.py: 6 passed (sections and definitions, names, token filter scope, capability-aware links, sign-in and stacked-segment drill-through, requirements checklist and Check again, prompt hand-off into an orchestrated chat that a reload does not reapply).python -m pytest -q -m uion the other 16ui_tests/*control_center*.pyfiles (V2 and classic): 35 passed, 11 skipped (live-environment tests).python -m pytest -q -m ui ui_tests/test_v2_admin_global_agents_actions.py ui_tests/test_v2_admin_governance_settings.py ui_tests/test_v2_admin_settings_rail_collapse.py ui_tests/test_v2_admin_settings_wide_layout.py ui_tests/test_v2_orchestration_composer.py ui_tests/test_v2_orchestration_actions.py ui_tests/test_v2_workspace_authoring.py ui_tests/test_v2_group_actions.py: 177 passed, 12 failed. The 12 are MCP/OpenAPI action-editor tests intest_v2_workspace_authoring.pyandtest_v2_group_actions.py; the same 12 fail on a build of the base branch (49a52bb5c) without this branch's changes.python -m pytest -q -m ui ui_tests/test_v2_prompt_composer_experience.py: 56 passed.python scripts/check_xss_sinks.py --base-sha origin/paullizer-react-v2-ui --head-sha HEAD <changed UI files>,python scripts/check_broken_access_control.py --full-file <changed Python files>andpython scripts/check_swagger_routes.py application/single_app/route_backend_control_center.py: passed.python scripts/build_docs_inventory.py: regenerateddocs/_data/app_surface.yml.functional_tests/test_logging_tag_standardization.pyfails on the base branch too, for unrelated tags; the new[CONTROL_CENTER_ACTION]tag is documented indocs/reference/logging-tags.md.Documentation
New:
docs/explanation/features/CONTROL_CENTER_ACTION.md,docs/explanation/fixes/V2_CONTROL_CENTER_DASHBOARD_USABILITY_FIX.md,docs/reference/actions/control-center.md. Updated:V2_CONTROL_CENTER.md,docs/guides/v2-control-center.md,docs/admin/agents-actions.md,docs/admin/orchestration.md, the actions index, logging tags and release notes (0.261.297).Security checklist
@swagger_route(security=get_auth_security())sanitize_settings_for_user()The readiness route sends derived requirement states and labels, not settings values. The new action runs fixed, parameterized, bounded reads, writes nothing, and maps storage errors to a generic message.