{
  "date": "2026-06-20",
  "timezone": "Asia/Shanghai",
  "window_start": "2026-06-20T00:00:00+08:00",
  "window_end": "2026-06-21T00:00:00+08:00",
  "granularity": "daily",
  "data_status": "complete",
  "source": {
    "kind": "grafana_prometheus_and_prod_sqlite",
    "grafana_datasource": "DevOps-prometheus",
    "grafana_datasource_id": 80,
    "prometheus_labels": {
      "cluster": "prod-devops",
      "namespace": "investibook",
      "job": "backend",
      "prometheus": "monitoring/o11y-vmagent"
    },
    "prod_backend_sqlite": "/data/db/investibook.db",
    "notes": [
      "Cost comes from prod SQLite interaction_token_usage with runtime-aware accounting: OpenCode ses_* rows use cumulative session deltas; PI UUID and image-parse rows use per-row increments.",
      "workspace_count in summary is cost-derived distinct positive-cost workspaces.",
      "Prometheus is used for ACP interaction counts only; investigatory PI sessions made investibook_acp_session_cost unsuitable as the cost source for mixed-runtime weekly reporting.",
      "message categories are rule-based user-message classifications.",
      "scenario labels are added to split daily workspace_changes rows."
    ]
  },
  "summary": {
    "total_cost": 10.0842,
    "total_acp_interactions": 6,
    "active_users": 6,
    "workspace_count": 9,
    "created_workspace_count": 6,
    "new_workspace_count": 12,
    "updated_existing_workspace_count": 5,
    "changed_workspace_count": 17,
    "message_count": 28,
    "user_message_count": 13,
    "assistant_message_count": 14,
    "unknown_user_count": 0,
    "unknown_cost": 0.0
  },
  "teams": [
    {
      "team_path": "Engineering Group / Global Support Intelligence / Intelligent Support Enablement",
      "team": "Intelligent Support Enablement",
      "cost": 4.686,
      "acp_interactions": 1,
      "workspace_count": 3,
      "active_users": 2,
      "message_count": 24,
      "user_message_count": 10,
      "cost_per_ws": 1.562,
      "cost_per_acp": 4.686,
      "acp_per_ws": 0.3333,
      "message_per_ws": 8.0,
      "message_per_acp": 24.0,
      "correction_message_ratio": null
    },
    {
      "team_path": "Engineering Group / Storage Service Engineering / KV Service",
      "team": "KV Service",
      "cost": 3.4681,
      "acp_interactions": 2,
      "workspace_count": 2,
      "active_users": 1,
      "message_count": 12,
      "user_message_count": 6,
      "cost_per_ws": 1.7341,
      "cost_per_acp": 1.7341,
      "acp_per_ws": 1.0,
      "message_per_ws": 6.0,
      "message_per_acp": 6.0,
      "correction_message_ratio": null
    },
    {
      "team_path": "Engineering Group / Database Service Engineering / TiDB Scalability Service",
      "team": "TiDB Scalability Service",
      "cost": 1.0334,
      "acp_interactions": 2,
      "workspace_count": 2,
      "active_users": 1,
      "message_count": 16,
      "user_message_count": 8,
      "cost_per_ws": 0.5167,
      "cost_per_acp": 0.5167,
      "acp_per_ws": 1.0,
      "message_per_ws": 8.0,
      "message_per_acp": 8.0,
      "correction_message_ratio": null
    },
    {
      "team_path": "Engineering Group / Database Service Engineering / Observability & Diagnostics Service",
      "team": "Observability & Diagnostics Service",
      "cost": 0.7333,
      "acp_interactions": 1,
      "workspace_count": 1,
      "active_users": 1,
      "message_count": 2,
      "user_message_count": 1,
      "cost_per_ws": 0.7333,
      "cost_per_acp": 0.7333,
      "acp_per_ws": 1.0,
      "message_per_ws": 2.0,
      "message_per_acp": 2.0,
      "correction_message_ratio": null
    },
    {
      "team_path": "Engineering Group / Global Support Intelligence / Intelligent Support",
      "team": "Intelligent Support",
      "cost": 0.1562,
      "acp_interactions": 0,
      "workspace_count": 1,
      "active_users": 1,
      "message_count": 0,
      "user_message_count": 0,
      "cost_per_ws": 0.1562,
      "cost_per_acp": null,
      "acp_per_ws": 0.0,
      "message_per_ws": 0.0,
      "message_per_acp": null,
      "correction_message_ratio": null
    },
    {
      "team_path": "(unknown)",
      "team": "(unknown)",
      "cost": 0.0,
      "acp_interactions": 0,
      "workspace_count": 1,
      "active_users": 0,
      "message_count": 0,
      "user_message_count": 0,
      "cost_per_ws": 0.0,
      "cost_per_acp": null,
      "acp_per_ws": 0.0,
      "message_per_ws": 0.0,
      "message_per_acp": null,
      "correction_message_ratio": null
    }
  ],
  "users": [
    {
      "user_email": "chensiyu@pingcap.com",
      "name": "陈思雨",
      "en_name": "Siyu Chen",
      "team_path": "Engineering Group / Global Support Intelligence / Intelligent Support Enablement",
      "team": "Intelligent Support Enablement",
      "mapping_source": "investibook-usage-team-overrides.csv",
      "cost": 4.2015,
      "acp_interactions": 0,
      "workspace_count": 2,
      "message_count": 8,
      "user_message_count": 3,
      "channel_breakdown": {},
      "frequency_bucket": "高频",
      "depth_bucket": "低轮次",
      "behavior_mode": "高频低轮次",
      "avg_acp_per_ws": 0.0
    },
    {
      "user_email": "yuping@pingcap.com",
      "name": "俞平",
      "en_name": "Ping Yu",
      "team_path": "Engineering Group / Storage Service Engineering / KV Service",
      "team": "KV Service",
      "mapping_source": "investibook-usage-team-overrides.csv",
      "cost": 3.4681,
      "acp_interactions": 2,
      "workspace_count": 2,
      "message_count": 6,
      "user_message_count": 3,
      "channel_breakdown": {
        "web": 2
      },
      "frequency_bucket": "高频",
      "depth_bucket": "低轮次",
      "behavior_mode": "高频低轮次",
      "avg_acp_per_ws": 1.0
    },
    {
      "user_email": "wenxuan.zhang@pingcap.com",
      "name": "张文轩",
      "en_name": "Wenxuan",
      "team_path": "Engineering Group / Database Service Engineering / TiDB Scalability Service",
      "team": "TiDB Scalability Service",
      "mapping_source": "investibook-usage-team-overrides.csv",
      "cost": 1.0334,
      "acp_interactions": 2,
      "workspace_count": 2,
      "message_count": 8,
      "user_message_count": 4,
      "channel_breakdown": {
        "web": 2
      },
      "frequency_bucket": "高频",
      "depth_bucket": "低轮次",
      "behavior_mode": "高频低轮次",
      "avg_acp_per_ws": 1.0
    },
    {
      "user_email": "lingtao.li@pingcap.com",
      "name": "李凌涛",
      "en_name": "Lingtao Li",
      "team_path": "Engineering Group / Database Service Engineering / Observability & Diagnostics Service",
      "team": "Observability & Diagnostics Service",
      "mapping_source": "pingcap_members_by_team.csv",
      "cost": 0.7333,
      "acp_interactions": 1,
      "workspace_count": 1,
      "message_count": 2,
      "user_message_count": 1,
      "channel_breakdown": {
        "cli": 1
      },
      "frequency_bucket": "低频",
      "depth_bucket": "低轮次",
      "behavior_mode": "低频低轮次",
      "avg_acp_per_ws": 1.0
    },
    {
      "user_email": "charles.m@pingcap.com",
      "name": "Charles Zhu",
      "en_name": "",
      "team_path": "Engineering Group / Global Support Intelligence / Intelligent Support Enablement",
      "team": "Intelligent Support Enablement",
      "mapping_source": "investibook-usage-team-overrides.csv",
      "cost": 0.4845,
      "acp_interactions": 1,
      "workspace_count": 1,
      "message_count": 4,
      "user_message_count": 2,
      "channel_breakdown": {
        "cli": 1
      },
      "frequency_bucket": "低频",
      "depth_bucket": "低轮次",
      "behavior_mode": "低频低轮次",
      "avg_acp_per_ws": 1.0
    },
    {
      "user_email": "wai.ho@pingcap.com",
      "name": "Chun Wai Ho",
      "en_name": "Wai Ho",
      "team_path": "Engineering Group / Global Support Intelligence / Intelligent Support",
      "team": "Intelligent Support",
      "mapping_source": "pingcap_members_by_team.csv",
      "cost": 0.1562,
      "acp_interactions": 0,
      "workspace_count": 1,
      "message_count": 0,
      "user_message_count": 0,
      "channel_breakdown": {},
      "frequency_bucket": "低频",
      "depth_bucket": "低轮次",
      "behavior_mode": "低频低轮次",
      "avg_acp_per_ws": 0.0
    }
  ],
  "message_categories": [
    {
      "category": "产出物迭代",
      "user_message_count": 2,
      "share": 0.153846,
      "estimated_cost_by_turn": 1.5514,
      "estimated_cost_by_output_weight": null,
      "avg_user_chars": 527.0,
      "avg_next_assistant_chars": null,
      "classification_method": "rule_based_keywords_v2"
    },
    {
      "category": "Ad hoc 查询",
      "user_message_count": 7,
      "share": 0.538462,
      "estimated_cost_by_turn": 5.43,
      "estimated_cost_by_output_weight": null,
      "avg_user_chars": 175.57,
      "avg_next_assistant_chars": null,
      "classification_method": "rule_based_keywords_v2"
    },
    {
      "category": "诊断启动",
      "user_message_count": 2,
      "share": 0.153846,
      "estimated_cost_by_turn": 1.5514,
      "estimated_cost_by_output_weight": null,
      "avg_user_chars": 14.5,
      "avg_next_assistant_chars": null,
      "classification_method": "rule_based_keywords_v2"
    },
    {
      "category": "流程控制/确认",
      "user_message_count": 2,
      "share": 0.153846,
      "estimated_cost_by_turn": 1.5514,
      "estimated_cost_by_output_weight": null,
      "avg_user_chars": 84.0,
      "avg_next_assistant_chars": null,
      "classification_method": "rule_based_keywords_v2"
    }
  ],
  "unmatched_users": [],
  "top_changed_workspaces": [
    {
      "workspace_id": "ws-1781952916968-e2daa511b",
      "title": "O11Y-2594263",
      "workspace_lifecycle": "new",
      "user_email": "chensiyu@pingcap.com",
      "team_path": "Engineering Group / Global Support Intelligence / Intelligent Support Enablement",
      "scenario_group": "diagnosis",
      "scenario_category": "component_failure_or_bug",
      "cost": 3.2581,
      "message_count": 5,
      "user_message_count": 2
    },
    {
      "workspace_id": "ws-1781936379540-0846a3df8",
      "title": "未命名工作空间",
      "workspace_lifecycle": "new",
      "user_email": "yuping@pingcap.com",
      "team_path": "Engineering Group / Storage Service Engineering / KV Service",
      "scenario_group": "diagnosis",
      "scenario_category": "storage_or_io_bottleneck",
      "cost": 2.9994,
      "message_count": 4,
      "user_message_count": 2
    },
    {
      "workspace_id": "lark-ws-23172274-cc2f-4af4-825e-181472ed0d16",
      "title": "Lark chat",
      "workspace_lifecycle": "new",
      "user_email": "chensiyu@pingcap.com",
      "team_path": "Engineering Group / Global Support Intelligence / Intelligent Support Enablement",
      "scenario_group": "diagnosis",
      "scenario_category": "sql_plan_or_query",
      "cost": 0.8752,
      "message_count": 3,
      "user_message_count": 1
    },
    {
      "workspace_id": "ws-1781598701127-da28e5bfa",
      "title": "tikv自动巡检",
      "workspace_lifecycle": "updated_existing",
      "user_email": "lingtao.li@pingcap.com",
      "team_path": "Engineering Group / Database Service Engineering / Observability & Diagnostics Service",
      "scenario_group": "non_diagnosis",
      "scenario_category": "inspection_or_report_generation",
      "cost": 0.7333,
      "message_count": 2,
      "user_message_count": 1
    },
    {
      "workspace_id": "ws-1781962254752-8c7e3f595",
      "title": "O11Y-2594350",
      "workspace_lifecycle": "new",
      "user_email": "wenxuan.zhang@pingcap.com",
      "team_path": "Engineering Group / Database Service Engineering / TiDB Scalability Service",
      "scenario_group": "diagnosis",
      "scenario_category": "backup_or_restore",
      "cost": 0.6881,
      "message_count": 4,
      "user_message_count": 2
    },
    {
      "workspace_id": "ws-1781952743474-2bd52bd16",
      "title": "O11Y-2594263 investigation",
      "workspace_lifecycle": "new",
      "user_email": "charles.m@pingcap.com",
      "team_path": "Engineering Group / Global Support Intelligence / Intelligent Support Enablement",
      "scenario_group": "diagnosis",
      "scenario_category": "storage_or_io_bottleneck",
      "cost": 0.4832,
      "message_count": 4,
      "user_message_count": 2
    },
    {
      "workspace_id": "ws-1781935792960-49617f7e6",
      "title": "未命名工作空间",
      "workspace_lifecycle": "new",
      "user_email": "yuping@pingcap.com",
      "team_path": "Engineering Group / Storage Service Engineering / KV Service",
      "scenario_group": "diagnosis",
      "scenario_category": "tikv_hotspot_or_coprocessor",
      "cost": 0.4447,
      "message_count": 2,
      "user_message_count": 1
    },
    {
      "workspace_id": "ws-1781877240964-5900764e9",
      "title": "未命名工作空间",
      "workspace_lifecycle": "updated_existing",
      "user_email": "wenxuan.zhang@pingcap.com",
      "team_path": "Engineering Group / Database Service Engineering / TiDB Scalability Service",
      "scenario_group": "diagnosis",
      "scenario_category": "backup_or_restore",
      "cost": 0.2856,
      "message_count": 4,
      "user_message_count": 2
    },
    {
      "workspace_id": "ws-1781887334195-7bc879003",
      "title": "",
      "workspace_lifecycle": "updated_existing",
      "user_email": "wai.ho@pingcap.com",
      "team_path": "Engineering Group / Global Support Intelligence / Intelligent Support",
      "scenario_group": "unknown",
      "scenario_category": null,
      "cost": 0.1562,
      "message_count": 0,
      "user_message_count": 0
    },
    {
      "workspace_id": "ws-1781952916968-e2daa511b",
      "title": "O11Y-2594263",
      "workspace_lifecycle": "new",
      "user_email": "chensiyu@pingcap.com",
      "team_path": "Engineering Group / Global Support Intelligence / Intelligent Support Enablement",
      "scenario_group": "diagnosis",
      "scenario_category": "component_failure_or_bug",
      "cost": 0.0478,
      "message_count": 5,
      "user_message_count": 2
    },
    {
      "workspace_id": "ws-1781962254752-8c7e3f595",
      "title": "O11Y-2594350",
      "workspace_lifecycle": "new",
      "user_email": "wenxuan.zhang@pingcap.com",
      "team_path": "Engineering Group / Database Service Engineering / TiDB Scalability Service",
      "scenario_group": "diagnosis",
      "scenario_category": "backup_or_restore",
      "cost": 0.0446,
      "message_count": 4,
      "user_message_count": 2
    },
    {
      "workspace_id": "ws-1781936379540-0846a3df8",
      "title": "未命名工作空间",
      "workspace_lifecycle": "new",
      "user_email": "yuping@pingcap.com",
      "team_path": "Engineering Group / Storage Service Engineering / KV Service",
      "scenario_group": "diagnosis",
      "scenario_category": "storage_or_io_bottleneck",
      "cost": 0.0225,
      "message_count": 4,
      "user_message_count": 2
    },
    {
      "workspace_id": "lark-ws-23172274-cc2f-4af4-825e-181472ed0d16",
      "title": "Lark chat",
      "workspace_lifecycle": "new",
      "user_email": "chensiyu@pingcap.com",
      "team_path": "Engineering Group / Global Support Intelligence / Intelligent Support Enablement",
      "scenario_group": "diagnosis",
      "scenario_category": "sql_plan_or_query",
      "cost": 0.0203,
      "message_count": 3,
      "user_message_count": 1
    },
    {
      "workspace_id": "ws-1781877240964-5900764e9",
      "title": "未命名工作空间",
      "workspace_lifecycle": "updated_existing",
      "user_email": "wenxuan.zhang@pingcap.com",
      "team_path": "Engineering Group / Database Service Engineering / TiDB Scalability Service",
      "scenario_group": "diagnosis",
      "scenario_category": "backup_or_restore",
      "cost": 0.0151,
      "message_count": 4,
      "user_message_count": 2
    },
    {
      "workspace_id": "ws-1781887334195-7bc879003",
      "title": "",
      "workspace_lifecycle": "updated_existing",
      "user_email": "",
      "team_path": "",
      "scenario_group": "unknown",
      "scenario_category": null,
      "cost": 0.0072,
      "message_count": 0,
      "user_message_count": 0
    },
    {
      "workspace_id": "ws-1781935792960-49617f7e6",
      "title": "未命名工作空间",
      "workspace_lifecycle": "new",
      "user_email": "yuping@pingcap.com",
      "team_path": "Engineering Group / Storage Service Engineering / KV Service",
      "scenario_group": "diagnosis",
      "scenario_category": "tikv_hotspot_or_coprocessor",
      "cost": 0.0016,
      "message_count": 2,
      "user_message_count": 1
    },
    {
      "workspace_id": "ws-1781952743474-2bd52bd16",
      "title": "O11Y-2594263 investigation",
      "workspace_lifecycle": "new",
      "user_email": "charles.m@pingcap.com",
      "team_path": "Engineering Group / Global Support Intelligence / Intelligent Support Enablement",
      "scenario_group": "diagnosis",
      "scenario_category": "storage_or_io_bottleneck",
      "cost": 0.0013,
      "message_count": 4,
      "user_message_count": 2
    }
  ],
  "charts": {
    "daily_cost_acp": [
      {
        "date": "2026-06-20",
        "cost": 10.0842,
        "acp_interactions": 6,
        "workspace_count": 9,
        "active_users": 6
      }
    ],
    "team_cost_bar": [
      {
        "team": "Intelligent Support Enablement",
        "team_path": "Engineering Group / Global Support Intelligence / Intelligent Support Enablement",
        "cost": 4.686,
        "acp_interactions": 1,
        "workspace_count": 3,
        "active_users": 2
      },
      {
        "team": "KV Service",
        "team_path": "Engineering Group / Storage Service Engineering / KV Service",
        "cost": 3.4681,
        "acp_interactions": 2,
        "workspace_count": 2,
        "active_users": 1
      },
      {
        "team": "TiDB Scalability Service",
        "team_path": "Engineering Group / Database Service Engineering / TiDB Scalability Service",
        "cost": 1.0334,
        "acp_interactions": 2,
        "workspace_count": 2,
        "active_users": 1
      },
      {
        "team": "Observability & Diagnostics Service",
        "team_path": "Engineering Group / Database Service Engineering / Observability & Diagnostics Service",
        "cost": 0.7333,
        "acp_interactions": 1,
        "workspace_count": 1,
        "active_users": 1
      },
      {
        "team": "Intelligent Support",
        "team_path": "Engineering Group / Global Support Intelligence / Intelligent Support",
        "cost": 0.1562,
        "acp_interactions": 0,
        "workspace_count": 1,
        "active_users": 1
      },
      {
        "team": "(unknown)",
        "team_path": "(unknown)",
        "cost": 0.0,
        "acp_interactions": 0,
        "workspace_count": 1,
        "active_users": 0
      }
    ],
    "team_ratio_scatter": [
      {
        "team": "Intelligent Support Enablement",
        "team_path": "Engineering Group / Global Support Intelligence / Intelligent Support Enablement",
        "x": 0.3333,
        "y": 4.686,
        "size": 3,
        "cost": 4.686
      },
      {
        "team": "KV Service",
        "team_path": "Engineering Group / Storage Service Engineering / KV Service",
        "x": 1.0,
        "y": 1.7341,
        "size": 2,
        "cost": 3.4681
      },
      {
        "team": "TiDB Scalability Service",
        "team_path": "Engineering Group / Database Service Engineering / TiDB Scalability Service",
        "x": 1.0,
        "y": 0.5167,
        "size": 2,
        "cost": 1.0334
      },
      {
        "team": "Observability & Diagnostics Service",
        "team_path": "Engineering Group / Database Service Engineering / Observability & Diagnostics Service",
        "x": 1.0,
        "y": 0.7333,
        "size": 1,
        "cost": 0.7333
      },
      {
        "team": "Intelligent Support",
        "team_path": "Engineering Group / Global Support Intelligence / Intelligent Support",
        "x": 0.0,
        "y": null,
        "size": 1,
        "cost": 0.1562
      },
      {
        "team": "(unknown)",
        "team_path": "(unknown)",
        "x": 0.0,
        "y": null,
        "size": 1,
        "cost": 0.0
      }
    ],
    "message_category_stack": [
      {
        "team": "Intelligent Support Enablement",
        "category": "Ad hoc 查询",
        "count": 6
      },
      {
        "team": "Intelligent Support Enablement",
        "category": "流程控制/确认",
        "count": 2
      },
      {
        "team": "Intelligent Support Enablement",
        "category": "诊断启动",
        "count": 2
      },
      {
        "team": "KV Service",
        "category": "Ad hoc 查询",
        "count": 6
      },
      {
        "team": "TiDB Scalability Service",
        "category": "Ad hoc 查询",
        "count": 2
      },
      {
        "team": "TiDB Scalability Service",
        "category": "产出物迭代",
        "count": 2
      },
      {
        "team": "TiDB Scalability Service",
        "category": "流程控制/确认",
        "count": 2
      },
      {
        "team": "TiDB Scalability Service",
        "category": "诊断启动",
        "count": 2
      },
      {
        "team": "Observability & Diagnostics Service",
        "category": "产出物迭代",
        "count": 1
      }
    ],
    "user_behavior_quadrant": [
      {
        "user_email": "charles.m@pingcap.com",
        "x": 1,
        "y": 1.0,
        "cost": 0.4845,
        "mode": "低频低轮次"
      },
      {
        "user_email": "chensiyu@pingcap.com",
        "x": 2,
        "y": 0.0,
        "cost": 4.2015,
        "mode": "高频低轮次"
      },
      {
        "user_email": "lingtao.li@pingcap.com",
        "x": 1,
        "y": 1.0,
        "cost": 0.7333,
        "mode": "低频低轮次"
      },
      {
        "user_email": "wai.ho@pingcap.com",
        "x": 1,
        "y": 0.0,
        "cost": 0.1562,
        "mode": "低频低轮次"
      },
      {
        "user_email": "wenxuan.zhang@pingcap.com",
        "x": 2,
        "y": 1.0,
        "cost": 1.0334,
        "mode": "高频低轮次"
      },
      {
        "user_email": "yuping@pingcap.com",
        "x": 2,
        "y": 1.0,
        "cost": 3.4681,
        "mode": "高频低轮次"
      }
    ]
  },
  "workspace_changes_ref": "workspace_changes.json"
}
