from pathlib import Path

from fastapi import APIRouter, Request
from fastapi.templating import Jinja2Templates

router = APIRouter(prefix="/studio", tags=["studio"])
BASE_DIR = Path(__file__).resolve().parent.parent.parent
templates = Jinja2Templates(directory=str(BASE_DIR / "templates"))


@router.get("")
async def studio_page(request: Request):
    return templates.TemplateResponse(
        "studio.html",
        {"request": request, "page_title": "AI Studio"},
    )
