feat: 初始化工程

This commit is contained in:
2026-08-31 15:22:00 +08:00
commit 825e097989
10 changed files with 287 additions and 0 deletions

5
routers/__init__.py Normal file
View File

@@ -0,0 +1,5 @@
from .agent import router as agent_router
routers = [
agent_router
]

15
routers/agent.py Normal file
View File

@@ -0,0 +1,15 @@
from fastapi import APIRouter
from service import agent_service
router = APIRouter(prefix="/agent", tags=["Agent"])
@router.post("/tip/generate")
def generate_tip():
return agent_service.generate_tip_agent()
@router.get("/tip/latest")
def latest_tip():
return agent_service.get_latest_tip()