{
  "entry_points": [
    "app/main.py",
    "app/proxy.py",
    "app/store.py",
    "app/reports.py",
    "app/redaction.py"
  ],
  "data_flow": [
    "app/main.py -> app/proxy.py (registers /v1/chat/completions route)",
    "app/proxy.py -> app/store.py (records metadata and llm_requests)",
    "app/proxy.py -> upstream llama.cpp (forwards requests)",
    "app/store.py -> app/reports.py (aggregates dashboard stats)",
    "app/reports.py -> app/main.py (serves dashboard pages)",
    "app/redaction.py -> app/main.py (removes secrets from previews)"
  ],
  "risks": [
    "app/proxy.py - potential injection attacks when forwarding to upstream llama.cpp",
    "app/store.py - SQL injection risk when inserting data into SQLite",
    "app/main.py - potential XSS/CSRF in dashboard pages if not properly sanitized",
    "app/redaction.py - potential漏掉敏感信息的风险，如果redaction逻辑不完善",
    "app/proxy.py - no rate limiting or authentication checks before forwarding to llama.cpp"
  ]
}