Problem
In reports.py:67, the export endpoint uses format as a query parameter name:
async def export_report(report_id: str, format: str = Query("json")) -> str:
This shadows Python's built-in format() function within the function scope.
Suggested Fix
Rename the parameter to format_type or export_format, using FastAPI's Query(alias="format") to preserve the external API:
async def export_report(report_id: str, export_format: str = Query("json", alias="format")) -> str: