{
  "date": "2026-07-25",
  "timezone": "Asia/Shanghai",
  "window_start": "2026-07-25T00:00:00+08:00",
  "window_end": "2026-07-26T00: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": 7.7783,
    "total_acp_interactions": 21,
    "active_users": 4,
    "workspace_count": 5,
    "created_workspace_count": 4,
    "new_workspace_count": 8,
    "updated_existing_workspace_count": 1,
    "changed_workspace_count": 9,
    "message_count": 44,
    "user_message_count": 21,
    "assistant_message_count": 23,
    "unknown_user_count": 0,
    "unknown_cost": 0.0
  },
  "teams": [
    {
      "team_path": "Engineering Group / Database Service Engineering / Intelligent Query Processing Service / SQL Optimization & Execution",
      "team": "SQL Optimization & Execution",
      "cost": 4.9867,
      "acp_interactions": 12,
      "workspace_count": 2,
      "active_users": 1,
      "message_count": 68,
      "user_message_count": 34,
      "cost_per_ws": 2.4934,
      "cost_per_acp": 0.4156,
      "acp_per_ws": 6.0,
      "message_per_ws": 34.0,
      "message_per_acp": 5.6667,
      "correction_message_ratio": null
    },
    {
      "team_path": "Engineering Group / Database Service Engineering / Observability & Diagnostics Service",
      "team": "Observability & Diagnostics Service",
      "cost": 1.3471,
      "acp_interactions": 1,
      "workspace_count": 1,
      "active_users": 1,
      "message_count": 2,
      "user_message_count": 1,
      "cost_per_ws": 1.3471,
      "cost_per_acp": 1.3471,
      "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 Enablement",
      "team": "Intelligent Support Enablement",
      "cost": 1.3373,
      "acp_interactions": 7,
      "workspace_count": 1,
      "active_users": 1,
      "message_count": 32,
      "user_message_count": 14,
      "cost_per_ws": 1.3373,
      "cost_per_acp": 0.191,
      "acp_per_ws": 7.0,
      "message_per_ws": 32.0,
      "message_per_acp": 4.5714,
      "correction_message_ratio": null
    },
    {
      "team_path": "Engineering Group / Global Support Intelligence / Advanced Intelligent Support",
      "team": "Advanced Intelligent Support",
      "cost": 0.1073,
      "acp_interactions": 1,
      "workspace_count": 1,
      "active_users": 1,
      "message_count": 2,
      "user_message_count": 1,
      "cost_per_ws": 0.1073,
      "cost_per_acp": 0.1073,
      "acp_per_ws": 1.0,
      "message_per_ws": 2.0,
      "message_per_acp": 2.0,
      "correction_message_ratio": null
    }
  ],
  "users": [
    {
      "user_email": "tailingxiang@pingcap.com",
      "name": "邰凌翔",
      "en_name": "Lingxiang Tai",
      "team_path": "Engineering Group / Database Service Engineering / Intelligent Query Processing Service / SQL Optimization & Execution",
      "team": "SQL Optimization & Execution",
      "mapping_source": "investibook-usage-team-overrides.csv",
      "cost": 4.9867,
      "acp_interactions": 12,
      "workspace_count": 2,
      "message_count": 24,
      "user_message_count": 12,
      "channel_breakdown": {
        "web": 12
      },
      "frequency_bucket": "高频",
      "depth_bucket": "高轮次",
      "behavior_mode": "高频高轮次",
      "avg_acp_per_ws": 6.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": 1.3471,
      "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": "xieyujie@pingcap.com",
      "name": "谢玉洁",
      "en_name": "Yujie Xie",
      "team_path": "Engineering Group / Global Support Intelligence / Intelligent Support Enablement",
      "team": "Intelligent Support Enablement",
      "mapping_source": "investibook-usage-team-overrides.csv",
      "cost": 1.3373,
      "acp_interactions": 7,
      "workspace_count": 1,
      "message_count": 16,
      "user_message_count": 7,
      "channel_breakdown": {
        "lark": 2,
        "web": 5
      },
      "frequency_bucket": "低频",
      "depth_bucket": "高轮次",
      "behavior_mode": "低频高轮次",
      "avg_acp_per_ws": 7.0
    },
    {
      "user_email": "jianghongmei@pingcap.com",
      "name": "江红梅",
      "en_name": "Hongmei Jiang",
      "team_path": "Engineering Group / Global Support Intelligence / Advanced Intelligent Support",
      "team": "Advanced Intelligent Support",
      "mapping_source": "investibook-usage-team-overrides.csv",
      "cost": 0.1073,
      "acp_interactions": 1,
      "workspace_count": 1,
      "message_count": 2,
      "user_message_count": 1,
      "channel_breakdown": {
        "web": 1
      },
      "frequency_bucket": "低频",
      "depth_bucket": "低轮次",
      "behavior_mode": "低频低轮次",
      "avg_acp_per_ws": 1.0
    }
  ],
  "message_categories": [
    {
      "category": "查询纠偏",
      "user_message_count": 1,
      "share": 0.047619,
      "estimated_cost_by_turn": 0.3704,
      "estimated_cost_by_output_weight": null,
      "avg_user_chars": 45.0,
      "avg_next_assistant_chars": null,
      "classification_method": "rule_based_keywords_v2"
    },
    {
      "category": "产出物迭代",
      "user_message_count": 1,
      "share": 0.047619,
      "estimated_cost_by_turn": 0.3704,
      "estimated_cost_by_output_weight": null,
      "avg_user_chars": 1014.0,
      "avg_next_assistant_chars": null,
      "classification_method": "rule_based_keywords_v2"
    },
    {
      "category": "Ad hoc 查询",
      "user_message_count": 9,
      "share": 0.428571,
      "estimated_cost_by_turn": 3.3336,
      "estimated_cost_by_output_weight": null,
      "avg_user_chars": 90.67,
      "avg_next_assistant_chars": null,
      "classification_method": "rule_based_keywords_v2"
    },
    {
      "category": "诊断启动",
      "user_message_count": 2,
      "share": 0.095238,
      "estimated_cost_by_turn": 0.7408,
      "estimated_cost_by_output_weight": null,
      "avg_user_chars": 53.0,
      "avg_next_assistant_chars": null,
      "classification_method": "rule_based_keywords_v2"
    },
    {
      "category": "解释追问",
      "user_message_count": 2,
      "share": 0.095238,
      "estimated_cost_by_turn": 0.7408,
      "estimated_cost_by_output_weight": null,
      "avg_user_chars": 39.0,
      "avg_next_assistant_chars": null,
      "classification_method": "rule_based_keywords_v2"
    },
    {
      "category": "流程控制/确认",
      "user_message_count": 2,
      "share": 0.095238,
      "estimated_cost_by_turn": 0.7408,
      "estimated_cost_by_output_weight": null,
      "avg_user_chars": 92.5,
      "avg_next_assistant_chars": null,
      "classification_method": "rule_based_keywords_v2"
    },
    {
      "category": "背景补充",
      "user_message_count": 3,
      "share": 0.142857,
      "estimated_cost_by_turn": 1.1112,
      "estimated_cost_by_output_weight": null,
      "avg_user_chars": 8240.67,
      "avg_next_assistant_chars": null,
      "classification_method": "rule_based_keywords_v2"
    },
    {
      "category": "未归类",
      "user_message_count": 1,
      "share": 0.047619,
      "estimated_cost_by_turn": 0.3704,
      "estimated_cost_by_output_weight": null,
      "avg_user_chars": 17.0,
      "avg_next_assistant_chars": null,
      "classification_method": "rule_based_keywords_v2"
    }
  ],
  "unmatched_users": [],
  "top_changed_workspaces": [
    {
      "workspace_id": "ws-1784963422633-4c84ebc2e",
      "title": "帮我看下这个单子 https://tidb.atlassian.net/browse/O11Y-26",
      "workspace_lifecycle": "new",
      "user_email": "tailingxiang@pingcap.com",
      "team_path": "Engineering Group / Database Service Engineering / Intelligent Query Processing Service / SQL Optimization & Execution",
      "scenario_group": "diagnosis",
      "scenario_category": "backup_or_restore",
      "cost": 3.4758,
      "message_count": 20,
      "user_message_count": 10
    },
    {
      "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": 1.3471,
      "message_count": 2,
      "user_message_count": 1
    },
    {
      "workspace_id": "ws-1784969282657-7eae3291d",
      "title": "这个单子能帮我看看吗 https://tidb.atlassian.net/browse/O11Y-",
      "workspace_lifecycle": "new",
      "user_email": "tailingxiang@pingcap.com",
      "team_path": "Engineering Group / Database Service Engineering / Intelligent Query Processing Service / SQL Optimization & Execution",
      "scenario_group": "diagnosis",
      "scenario_category": "backup_or_restore",
      "cost": 1.3015,
      "message_count": 4,
      "user_message_count": 2
    },
    {
      "workspace_id": "lark-ws-e273d7c5-2ad9-4cb1-a307-fd962253e53b",
      "title": "Lark O11Y-2623034",
      "workspace_lifecycle": "new",
      "user_email": "xieyujie@pingcap.com",
      "team_path": "Engineering Group / Global Support Intelligence / Intelligent Support Enablement",
      "scenario_group": "diagnosis",
      "scenario_category": "component_failure_or_bug",
      "cost": 1.215,
      "message_count": 16,
      "user_message_count": 7
    },
    {
      "workspace_id": "ws-1784963422633-4c84ebc2e",
      "title": "帮我看下这个单子 https://tidb.atlassian.net/browse/O11Y-26",
      "workspace_lifecycle": "new",
      "user_email": "tailingxiang@pingcap.com",
      "team_path": "Engineering Group / Database Service Engineering / Intelligent Query Processing Service / SQL Optimization & Execution",
      "scenario_group": "diagnosis",
      "scenario_category": "backup_or_restore",
      "cost": 0.1542,
      "message_count": 20,
      "user_message_count": 10
    },
    {
      "workspace_id": "lark-ws-e273d7c5-2ad9-4cb1-a307-fd962253e53b",
      "title": "Lark O11Y-2623034",
      "workspace_lifecycle": "new",
      "user_email": "xieyujie@pingcap.com",
      "team_path": "Engineering Group / Global Support Intelligence / Intelligent Support Enablement",
      "scenario_group": "diagnosis",
      "scenario_category": "component_failure_or_bug",
      "cost": 0.1222,
      "message_count": 16,
      "user_message_count": 7
    },
    {
      "workspace_id": "ws-1784955316222-c71cd17b3",
      "title": "tidbcloud审计日志写入s3存储桶源ip地址白名单确认(集群:",
      "workspace_lifecycle": "new",
      "user_email": "jianghongmei@pingcap.com",
      "team_path": "Engineering Group / Global Support Intelligence / Advanced Intelligent Support",
      "scenario_group": "diagnosis",
      "scenario_category": "storage_or_io_bottleneck",
      "cost": 0.1073,
      "message_count": 2,
      "user_message_count": 1
    },
    {
      "workspace_id": "ws-1784963422633-4c84ebc2e",
      "title": "帮我看下这个单子 https://tidb.atlassian.net/browse/O11Y-26",
      "workspace_lifecycle": "new",
      "user_email": "tailingxiang@pingcap.com",
      "team_path": "Engineering Group / Database Service Engineering / Intelligent Query Processing Service / SQL Optimization & Execution",
      "scenario_group": "diagnosis",
      "scenario_category": "backup_or_restore",
      "cost": 0.0484,
      "message_count": 20,
      "user_message_count": 10
    },
    {
      "workspace_id": "ws-1784969282657-7eae3291d",
      "title": "这个单子能帮我看看吗 https://tidb.atlassian.net/browse/O11Y-",
      "workspace_lifecycle": "new",
      "user_email": "tailingxiang@pingcap.com",
      "team_path": "Engineering Group / Database Service Engineering / Intelligent Query Processing Service / SQL Optimization & Execution",
      "scenario_group": "diagnosis",
      "scenario_category": "backup_or_restore",
      "cost": 0.0068,
      "message_count": 4,
      "user_message_count": 2
    }
  ],
  "charts": {
    "daily_cost_acp": [
      {
        "date": "2026-07-25",
        "cost": 7.7783,
        "acp_interactions": 21,
        "workspace_count": 5,
        "active_users": 4
      }
    ],
    "team_cost_bar": [
      {
        "team": "SQL Optimization & Execution",
        "team_path": "Engineering Group / Database Service Engineering / Intelligent Query Processing Service / SQL Optimization & Execution",
        "cost": 4.9867,
        "acp_interactions": 12,
        "workspace_count": 2,
        "active_users": 1
      },
      {
        "team": "Observability & Diagnostics Service",
        "team_path": "Engineering Group / Database Service Engineering / Observability & Diagnostics Service",
        "cost": 1.3471,
        "acp_interactions": 1,
        "workspace_count": 1,
        "active_users": 1
      },
      {
        "team": "Intelligent Support Enablement",
        "team_path": "Engineering Group / Global Support Intelligence / Intelligent Support Enablement",
        "cost": 1.3373,
        "acp_interactions": 7,
        "workspace_count": 1,
        "active_users": 1
      },
      {
        "team": "Advanced Intelligent Support",
        "team_path": "Engineering Group / Global Support Intelligence / Advanced Intelligent Support",
        "cost": 0.1073,
        "acp_interactions": 1,
        "workspace_count": 1,
        "active_users": 1
      }
    ],
    "team_ratio_scatter": [
      {
        "team": "SQL Optimization & Execution",
        "team_path": "Engineering Group / Database Service Engineering / Intelligent Query Processing Service / SQL Optimization & Execution",
        "x": 6.0,
        "y": 0.4156,
        "size": 2,
        "cost": 4.9867
      },
      {
        "team": "Observability & Diagnostics Service",
        "team_path": "Engineering Group / Database Service Engineering / Observability & Diagnostics Service",
        "x": 1.0,
        "y": 1.3471,
        "size": 1,
        "cost": 1.3471
      },
      {
        "team": "Intelligent Support Enablement",
        "team_path": "Engineering Group / Global Support Intelligence / Intelligent Support Enablement",
        "x": 7.0,
        "y": 0.191,
        "size": 1,
        "cost": 1.3373
      },
      {
        "team": "Advanced Intelligent Support",
        "team_path": "Engineering Group / Global Support Intelligence / Advanced Intelligent Support",
        "x": 1.0,
        "y": 0.1073,
        "size": 1,
        "cost": 0.1073
      }
    ],
    "message_category_stack": [
      {
        "team": "SQL Optimization & Execution",
        "category": "Ad hoc 查询",
        "count": 14
      },
      {
        "team": "SQL Optimization & Execution",
        "category": "查询纠偏",
        "count": 3
      },
      {
        "team": "SQL Optimization & Execution",
        "category": "流程控制/确认",
        "count": 3
      },
      {
        "team": "SQL Optimization & Execution",
        "category": "背景补充",
        "count": 9
      },
      {
        "team": "SQL Optimization & Execution",
        "category": "诊断启动",
        "count": 5
      },
      {
        "team": "Observability & Diagnostics Service",
        "category": "产出物迭代",
        "count": 1
      },
      {
        "team": "Intelligent Support Enablement",
        "category": "Ad hoc 查询",
        "count": 8
      },
      {
        "team": "Intelligent Support Enablement",
        "category": "未归类",
        "count": 2
      },
      {
        "team": "Intelligent Support Enablement",
        "category": "解释追问",
        "count": 4
      },
      {
        "team": "Advanced Intelligent Support",
        "category": "流程控制/确认",
        "count": 1
      }
    ],
    "user_behavior_quadrant": [
      {
        "user_email": "jianghongmei@pingcap.com",
        "x": 1,
        "y": 1.0,
        "cost": 0.1073,
        "mode": "低频低轮次"
      },
      {
        "user_email": "lingtao.li@pingcap.com",
        "x": 1,
        "y": 1.0,
        "cost": 1.3471,
        "mode": "低频低轮次"
      },
      {
        "user_email": "tailingxiang@pingcap.com",
        "x": 2,
        "y": 6.0,
        "cost": 4.9867,
        "mode": "高频高轮次"
      },
      {
        "user_email": "xieyujie@pingcap.com",
        "x": 1,
        "y": 7.0,
        "cost": 1.3373,
        "mode": "低频高轮次"
      }
    ]
  },
  "workspace_changes_ref": "workspace_changes.json"
}
