{
  "version": 2,
  "description": "WorkBuddy AI Infra 全量关键资产：文档/程序 + Dify/Langfuse/Xinference 相关配置与脚本",
  "include_dirs": [
    "docs/md_cursor",
    "docs/html_cursor",
    "scripts_cursor",
    "scripts_bash_cursor",
    "patches_cursor",
    "data",
    "tools",
    "keep",
    ".cursor/rules"
  ],
  "include_files": [
    "gen_all_html.py",
    "gen_index_html.py",
    "gen_homework3_html.py",
    "gen_langfuse_dify_html.py",
    "gen_topic12_html.py",
    "gen_topic13_html.py",
    "gen_topic14_html.py",
    "gen_topic15_html.py",
    "dify_api.py",
    "dify_diag.py",
    "docker-compose.yaml",
    "vllm_qwen_run.sh",
    "health_check.py",
    "preserve.py",
    ".env",
    "token.txt",
    "langfuse_api_keys.txt",
    "langfuse_deploy_creds.txt",
    "configure_dify_langfuse.py",
    "setup_langfuse_keys.py",
    "setup_dify_rerank.py",
    "setup_login.py",
    "enable_langfuse_dual.py",
    "verify_weaviate.py",
    "verify_full_trace.py",
    "verify_langfuse_after_dual.py",
    "verify_langfuse_traces.py",
    "verify_langfuse_traces2.py",
    "verify_timeline.py",
    "verify_timeline2.py",
    "inspect_langfuse_compose_env.py",
    "inspect_langfuse_flush.py",
    "inspect_dify_langfuse.py",
    "inspect_dify_langfuse2.py",
    "inspect_dify_langfuse3.py",
    "inspect_dify_langfuse4.py",
    "inspect_dify_langfuse5.py",
    "inspect_dify_langfuse6.py",
    "inspect_dify_langfuse7.py",
    "inspect_dify_langfuse8.py",
    "inspect_dify_langfuse9.py",
    "fetch_compose.py",
    "dump_compose_mig.py",
    "final_env_check.py",
    "apply_hostnet.py",
    "apply_relay.py",
    "apply_relay_fix.py",
    "apply_relay_fix2.py",
    "apply_and_verify_rerank.py",
    "apply_fix.py",
    "apply_patch_lf_id.py",
    "backup_snap.json",
    "backup_draft.json",
    "backup_snap_before_8192.json",
    "backup_draft_before_8192.json",
    "backup_snap_before_32768.json",
    "backup_draft_before_32768.json",
    "backup_snap_before_rerank.json",
    "backup_draft_before_rerank.json"
  ],
  "include_globs_root": [
    "inspect_*.py",
    "diag_*.py",
    "probe_*.py",
    "fix_*.py",
    "agent_*.py",
    "check_*.py",
    "launch_*.py",
    "patch_*.py",
    "restore_*.py",
    "retry_*.py",
    "run_*.py",
    "verify*.py",
    "add_*.py",
    "align_*.py",
    "api_*.py",
    "db_*.py",
    "destroy_*.py",
    "dump_*.py",
    "enable_*.py",
    "fetch_*.py",
    "final_*.py",
    "find_*.py",
    "llm_*.py",
    "rebuild_*.py",
    "rescue*.py",
    "restart_*.py",
    "squid_*.py",
    "test_*.py"
  ],
  "exclude_dir_names": [
    "__pycache__",
    ".git",
    ".idea",
    "node_modules",
    ".workbuddy",
    "baidu_backup"
  ],
  "exclude_file_names": [],
  "exclude_globs": [
    "*.pyc",
    "*.pyo",
    "*.log",
    ".DS_Store",
    "Thumbs.db"
  ],
  "max_file_bytes": 52428800,
  "remote_snapshot": {
    "enabled": true,
    "host": "192.168.110.207",
    "user": "root",
    "pass": "123456",
    "paths": [
      {"src": "/dify/dify-main/docker/.env", "dst": "platform_snapshot/dify/docker.env", "category": "dify"},
      {"src": "/dify/dify-main/docker/docker-compose.yaml", "dst": "platform_snapshot/dify/docker-compose.yaml", "category": "dify"},
      {"src": "/dify/dify-main/docker/docker-compose.yml", "dst": "platform_snapshot/dify/docker-compose.yml", "category": "dify"},
      {"src": "/Langfuse/langfuse/.env", "dst": "platform_snapshot/langfuse/.env", "category": "langfuse"},
      {"src": "/Langfuse/langfuse/docker-compose.yml", "dst": "platform_snapshot/langfuse/docker-compose.yml", "category": "langfuse"},
      {"src": "/Langfuse/langfuse/docker-compose.yaml", "dst": "platform_snapshot/langfuse/docker-compose.yaml", "category": "langfuse"},
      {"src": "/opt/workbuddy/scripts_cursor/_config.py", "dst": "platform_snapshot/workbuddy/_config.py", "category": "workbuddy"},
      {"src": "/opt/workbuddy/patches_cursor/作业8_SLA监控大盘/docker-compose.monitoring.yml", "dst": "platform_snapshot/monitoring/docker-compose.monitoring.yml", "category": "monitoring"},
      {"src": "/opt/workbuddy/patches_cursor/作业8_SLA监控大盘/prometheus/prometheus.yml", "dst": "platform_snapshot/monitoring/prometheus.yml", "category": "monitoring"},
      {"src": "/opt/litellm/config.yaml", "dst": "platform_snapshot/litellm/config.yaml", "category": "litellm"},
      {"src": "/etc/systemd/system/litellm.service", "dst": "platform_snapshot/litellm/litellm.service", "category": "litellm"},
      {"src": "/opt/workbuddy/patches_cursor/LiteLLM部署/.env", "dst": "platform_snapshot/litellm/patch.env", "category": "litellm"},
      {"src": "/opt/higress/compose/.env", "dst": "platform_snapshot/higress/compose.env", "category": "higress"},
      {"src": "/opt/workbuddy/patches_cursor/Higress部署/console.env", "dst": "platform_snapshot/higress/console.env", "category": "higress"},
      {"src": "/opt/workbuddy/patches_cursor/Higress部署/install_options.env", "dst": "platform_snapshot/higress/install_options.env", "category": "higress"}
    ],
    "commands": [
      {
        "name": "docker_ps.txt",
        "dst": "platform_snapshot/runtime/docker_ps.txt",
        "category": "runtime",
        "cmd": "docker ps --format 'table {{.Names}}\\t{{.Image}}\\t{{.Status}}\\t{{.Ports}}' 2>/dev/null || true"
      },
      {
        "name": "higress_status.txt",
        "dst": "platform_snapshot/higress/status.txt",
        "category": "higress",
        "cmd": "/opt/higress/bin/status.sh 2>/dev/null | head -n 80 || echo 'higress status skip'"
      },
      {
        "name": "higress_routes.txt",
        "dst": "platform_snapshot/higress/routes_probe.txt",
        "category": "higress",
        "cmd": "curl -sf -m 10 http://127.0.0.1:18080/llm/v1/models -H 'Authorization: Bearer sk-litellm-bocheng-207' 2>/dev/null | head -c 4000 || echo 'higress llm probe fail'"
      },
      {
        "name": "litellm_models.txt",
        "dst": "platform_snapshot/litellm/models.txt",
        "category": "litellm",
        "cmd": "curl -sf -H 'Authorization: Bearer sk-litellm-bocheng-207' http://127.0.0.1:4000/v1/models 2>/dev/null | head -c 200000 || echo 'litellm unreachable'"
      },
      {
        "name": "litellm_service.txt",
        "dst": "platform_snapshot/litellm/service_status.txt",
        "category": "litellm",
        "cmd": "systemctl is-active litellm 2>/dev/null; systemctl status litellm --no-pager -l 2>/dev/null | head -n 40 || echo 'litellm unit missing'"
      },
      {
        "name": "xinference_models.txt",
        "dst": "platform_snapshot/xinference/models.txt",
        "category": "xinference",
        "cmd": "curl -sf -H 'Authorization: Bearer xf-K8H3LiS27H4188XdOyWJj74MWMOlIR9tZbiybDbxbSas7eAI' http://127.0.0.1:9997/v1/models 2>/dev/null | head -c 200000 || echo 'xinference unreachable'"
      },
      {
        "name": "vllm_models.txt",
        "dst": "platform_snapshot/vllm/models.txt",
        "category": "vllm",
        "cmd": "curl -sf -H 'Authorization: Bearer 123456' http://116.62.10.183:8000/v1/models 2>/dev/null | head -c 200000 || echo 'vllm unreachable'"
      },
      {
        "name": "langfuse_health.txt",
        "dst": "platform_snapshot/langfuse/health.txt",
        "category": "langfuse",
        "cmd": "curl -sf http://127.0.0.1:3000/api/public/health 2>/dev/null || echo 'langfuse unreachable'"
      },
      {
        "name": "nvidia_smi_183.txt",
        "dst": "platform_snapshot/vllm/nvidia_smi.txt",
        "category": "vllm",
        "cmd": "sshpass -p 'HuaweiCloud2027$' ssh -o StrictHostKeyChecking=no root@116.62.10.183 'nvidia-smi' 2>/dev/null || echo 'skip gpu smi'"
      }
    ]
  },
  "notes": "含密钥/环境变量；网盘目录请控制访问权限。超过 max_file_bytes 的单文件会跳过。"
}
