from fastapi import APIRouter, Query from app.controllers.nlp.meeting import get_caught_result from app.models.domain.nlp import MeetingInfoResponse router = APIRouter() @router.get("/meeting/info", response_model=MeetingInfoResponse) async def catch_meeting_info(sentence: str = Query(..., max_length=100)): ( start_time, end_time, duration, room_size, topic, name_list, ) = await get_caught_result(sentence) response = { "Message": "success", "AcceptableStartTime": start_time, "AcceptableEndTime": end_time, "MeetingDurationSeconds": duration, "MeetingRoomSize": room_size, "Topic": topic, "Participants": name_list, } return response