agentviz
Provides a Gradio-based panel that also serves as an MCP server, enabling human users to view trial ledger tables, heatmaps, and provide layer-specific feedback and decisions via a web interface.
Provides an adapter to ingest Kaggle cross-validation results (per-fold scores and LB score) into the trial ledger, treating folds as cases and LB as a metric.
Integrates with the KnowledgeBase vault as the canonical store for finalized decisions, linking decision points to vault references for authoritative records.
Uses MLflow as the backbone for trial logging and storage, allowing agents to log trial records, metrics, and artifacts (self-contained HTML reports) and enabling humans to review via MLflow UI.
Generates self-contained HTML reports with Plotly for interactive visualizations (e.g., graphs, heatmaps, scatter plots) to facilitate visual communication between humans and agents.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@agentvizList unresolved feedback and open decision points"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
agent-viz
A living asset that extends communication between humans and AI agents from chat to visuals (graphs, tree diagrams, heatmaps, flowcharts). Shared across Kaggle / AtCoder Heuristic / trading model development.
Design policy (based on 2026-08-24 research)
Backbone of records = MLflow (local file store). Agents write, humans view via
mlflow uiCustom figures = self-contained HTML (Plotly). Rendered inline in MLflow's artifact view
What we maintain ourselves is only a thin layer: "common trial ledger schema", "report components", and "domain adapters"
Source of research: KnowledgeBase 00_Inbox/人間とAIエージェントのビジュアル意思疎通ツール 調査メモ
Related MCP server: Querytree MCP Server
Phase 0 (implemented)
agentviz.schema— common trial ledger schema. 1 trial = TrialRecord, case = seed / fold / periodagentviz.ledger— TrialLedger. log_trial / fetch_trials to MLflowagentviz.report— build_report. Self-contained HTML with trial ledger table + metric trends + per-case × per-trial relative score heatmap
Usage
# セットアップ
.venv\Scripts\python.exe -m pip install -e .[dev]
# テスト
.venv\Scripts\python.exe -m pytest
# デモ(合成AHCデータで台帳→レポート→MLflow記録)
.venv\Scripts\python.exe demo\generate_demo.py
# UI(共有ストアを表示)
.venv\Scripts\python.exe -m mlflow ui --backend-store-uri "<store path>"Default store is %AGENTVIZ_STORE%, or ~\dev\Projects\agent-viz\store if unset.
Phase 1 (implemented)
agentviz.adapters.ahc— ingestion of our own AHC runner measurement format.from_results_json(results/*.json) andfrom_experiments_jsonl(1 line = 1 experiment. Broken lines are returned as errors and processing continues; lines with empty metrics are rescued by recomputing from per-seed results; absolute paths from other machines are resolved by file name viaresults_dir)agentviz.adapters.kaggle—from_cv(fold_scores, lb_score=...). Case = fold, LB islb_scoremetric. For competitions where the metric is defined as the average of per-label scores, such as macro AUC / macro F1, it hasfrom_per_label(label_scores, label_meta=..., metric_name="macro_auc")(case = label). The primary metric is not calledcv_meanto avoid confusing the variance between folds (measurement noise) with the gap between labels (difference in true ability). Only the latter can be acted upon.label_metagoes into the case's meta and becomes material for stratification by label density or positive count.agentviz.adapters.trade—from_walkforward(windows, ...). Case = walk-forward window. OOS isoos_scoremetric, tear sheet HTML is attached vialog_trial(artifact_paths=...)agentviz.report— added generalization gap scatter plot (auto-displayed when there are 2+ trials withlb_score/oos_score. Treats CV vs LB = IS vs OOS as the same shape)agentviz.replay—build_replay(frames, infos, events). Self-contained HTML that generalizes the skeleton of the ahc069 custom replay (seek bar, play, frame advance, ←→ keys, event click jump) to be domain-independent
Confirmed with real data: 1133 trials ingested from AtCoder\ahc\ahc069\experiments.jsonl (1191 lines), per-seed case resolution for 1130 trials (examples/ingest_ahc069.py).
Phase 2 (implemented) — bidirectional
agentviz.feedback— canonical store for stratified feedback (append-only JSONL,store/feedback.jsonl). add / list / resolveagentviz.panel— Gradio panel and MCP server. Humans view the trial ledger and heatmap, post stratified feedback (target trial, target case, instruction, priority); agents read it via MCP tools, act on it, and close it withresolve_feedback
# パネル起動(http://127.0.0.1:7861、ポートは AGENTVIZ_PANEL_PORT で変更)
.venv\Scripts\python.exe -m agentviz.panel# Claude Code への登録(パネル起動中に)
claude mcp add --transport http agentviz http://127.0.0.1:7861/gradio_api/mcp/Even without MCP, you can read/write directly via gradio_client or agentviz.feedback.FeedbackStore. In environments where UI dropdown selections are not reflected, the "Reload" button is a reliable fallback.
Phase 3 (implemented) — decision points
While feedback handles a single round-trip of issue → response ("this stratum is weak, fix it"), decisions handles points of contention where you cannot proceed until a choice is made. They are separated because their shapes differ.
agentviz.decisions— store for decision points (append-only JSONL,store/decisions.jsonl). propose / decide / supersedeOptions have a
measuredflag. If unmeasured options cannot be displayed alongside measured ones, "best among measured" is misread as "best"Dependencies between decisions are held via
blocks.ready()returns only those whose dependencies have been resolvedEach option points to ledger trials via
evidence_trials
Division of canonical sources: the description of finalized decisions is canonical in the KnowledgeBase Vault. decisions holds only the working surface (options, evidence links, status) and points to the Vault side via vault_ref. The same text is not kept in both.
decide is the mouth for recording human judgment. The agent lays out options (propose_decision), and the human chooses. chosen is limited to registered keys; free-form text is not accepted (because it would become impossible to trace mechanically later). revise_option revises only the state of the evidence (evidence_trials / measured / note) with a reason (the evidence at registration time always remains in history as an event).
Aligning viewpoints (implemented) — agent → human
feedback is human → agent, decisions is the ledger of points. One more direction was missing: a way to align, on the human's screen, which comparison the agent is currently looking at when it speaks.
Even if the agent says "when narrowed to 9 labels, it's 8 wins and 1 loss," the numbers won't match if the human is looking at a different comparison. Re-explaining the conditions in words is a game of telephone, and in this round-trip the ambiguity of "did you exclude them or look at all of them" actually arose.
agentviz.viewstate— store for pointing (append-only JSONL,store/viewstate.jsonl). point / clear / current / historyMCP tool
point_at_comparison— sends the baseline, candidate, and cases excluded from aggregation to the panel, and returns the numbers for that comparison in the same call (fetching them separately can lead to discrepancies).noteis required. A screen change without a reason is, from the human's perspective, nothing more than "it changed on its own"MCP tool
clear_comparison_pointer/ the panel's "Clear pointer" button
It does not rewrite the ledger or decisions. It is not an observation or a judgment, but a pointer to align viewpoints. Not silently overwriting the human's choice is the key design point; when applying, the panel always shows "who specified what, when, and for what purpose," and provides a way to clear it.
Decision views (implemented)
Because "you cannot decide from the average ranking table alone" repeatedly emerged in practice, the skeleton of decision-making was componentized. Everything is provided in two faces: human = figure / agent = JSON.
Paired difference
paired_diff— per-case difference between two trials. Warns when the sign of the mean and the case majority disagree (if they disagree, you cannot claim a ranking. This has fired multiple times on real data).casescan limit the aggregation to a subset. This is the mouth for not mixing cases whose conditions are not the same across both trials into the mean; in RSNA, the differences of the 3 labels without gradients were noise, yet they diluted the mean of 12 labels, and the mean -0.040 vs median -0.104 differed by 3x. Excluded cases always go intoexcluded_casesand remain in the figure in gray rather than being removed (if removed, readers cannot distinguish whether a convenient subset was chosen or cases with different conditions were excluded). The panel also has a selection field for "cases to exclude from aggregation (multiple allowed)"; selecting updates the figure and statistics on the spot (same function ascasesin MCPcompare_trialsand the third element ofpairsinbuild_report)Stratified means
strata_means— shows "the ranking flips in this stratum". The definition of strata (domain knowledge) is held by the callerDecision leverage
decision_leverage— which decision to settle first. Two premises (1 decision = 1 factor, only live options) are always included as premisesPer-case details
case_scores/ dot strip plot — passively brings into view, as sort order, the "absolute difficulty of cases" that disappears in the relative heatmapOracle headroom
headroom— for constraint-relaxation ideas (e.g., scheduled sampling), measure the upper bound with an oracle run before implementation. Include in premises: oracle not adoptable, it is an upper bound, and if below threshold, systematically shelveGeneralization gap scatter plot — auto-displayed when there are 2+ trials with
lb_score/oos_score
Operational components
Trial archive
set_archived/archive_trial— reversibly hides trials that have been settled as phases progress, preserving visualization resolution (does not delete; history remains in MLflow)Dark mode — reports support prefers-color-scheme (Plotly figures follow via relayout)
17 panel MCP tools (13 read + writes are
add_feedbackfamily,decide/archive_trial,point_at_comparison/clear_comparison_pointer. The last two do not change the ledger; they only move the comparison the human's screen is viewing)
Real-world application examples (case studies)
kaggle-store-sales-workflow — time-series validation design. Bookkept 12 decisions as decision points, running split design, baseline, features, and adoption decisions all as "measure then decide". Up to LB transfer analysis of CV improvements
kaggle-house-prices-workflow — nested-CV model selection. First application where the per-case heatmap detected a stratified reversal hidden behind the average ranking
rsna-knee-abnormality-detection— weakly supervised 12-label classification (macro ROC-AUC). First application offrom_per_label. When labels are stratified by label density, the dense 8 labels are 0.751 while the 4 labels with sparse supervision are 0.525, revealing that 1/3 of the metric is effectively unlearned beneath the average of 0.6807. Subsequent comparisons also showed the need to restrict the aggregation of paired differences (across all 12 labels the mean is -0.040, but narrowed to labels with gradients, the effect size is -0.090. If adoption had been decided by the mean alone, it would have been misjudged by more than half)examples/ingest_ahc069.py— ingestion of 1133 trials from the AHC custom runner's measurement logs
Roadmap
Viewing the residual correlation matrix (hand-built for blend diversity decisions; candidate for componentization)
Named stratum store (persisting the human's "pointing")
run alias (referencing the same measurement from multiple decision contexts; from the lesson that trial reuse broke visibility)
pahcer format adapter (to be added when real output becomes available)
Report size optimization (about 4.9MB per report with Plotly embedded; measured to not hinder agent reading)
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceEnables agent settlement, trust verification, and ledger operations for multi-agent workflows, with tools for blueprint management, credit tracking, and provenance recording.1MIT
- AlicenseNot gradedqualityCmaintenanceEnables AI agents to add decision drafts, evidence, and counterarguments to a shared local decision state, while users confirm or reopen decisions in a web console. Prevents unverified agent answers from being silently turned into code.MIT
- AlicenseNot gradedqualityAmaintenanceEnables agents to create and manage persistent task logs, decisions, dead ends, questions, and handoffs, with file staleness detection and activity reporting.12MIT
- AlicenseNot gradedqualityCmaintenanceEnables AI agents to access observability and evaluation data, including run history, span traces, LLM-as-judge evaluation results, and regression reports.MIT
Related MCP Connectors
Preflight, approve, and prove consequential agent actions with signed evidence and x402 tools.
Read-only GitHub bounty, agent harness, Actions failure, flake, and MCP tool-drift decisions.
Runtime permission, approval, and audit layer for AI agent tool execution.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/Yurikada/agent-viz'
If you have feedback or need assistance with the MCP directory API, please join our Discord server