1. **Analyze the Request:** * Task: Extract structured information from unstructured text. * Output format: ONLY valid JSON matching the provided schema. No markdown wrapping. * Schema: `{"people": [{"name": str, "role": str, "email": str|null, "phone": str|null, "mentioned_projects": [str]}], "meetings": [{"title": str, "datetime_iso": str, "attendees": [str]}]}` * Text: "Hi team, Karen (CTO, karen@acme.io) wants to sync on Project Aurora and the Q3 migration next Tuesday at 2:30pm PT. Please include Dan Pham (eng lead, dan@acme.io, 415-555-0198) and Priya from product (priya.n@acme.io). We'll also chat about Project Lumen with Karen. Separately, Friday 10am PST is the all-hands that Dan is running. Assume today is 2025-04-21." 2. **Analyze the Text & Extract Data:** * **People:** * Karen: Role = CTO, Email = karen@acme.io, Phone = null, Projects = ["Project Aurora", "Project Lumen"] * Dan Pham: Role = eng lead, Email = dan@acme.io, Phone = 415-555-0198, Projects = [] (not explicitly mentioned as working on a project, just running a meeting) * Priya: Role = product, Email = priya.n@acme.io, Phone = null, Projects = [] * **Meetings:** * Meeting 1: "sync on Project Aurora and the Q3 migration" * Title: "sync on Project Aurora and the Q3 migration" (or similar, let's use "sync on Project Aurora and the Q3 migration") * Date/Time: "next Tuesday at 2:30pm PT". Today is 2025-04-21 (Monday). Next Tuesday is 2025-04-22. Time is 2:30pm PT. ISO format: 2025-04-22T14:30:00-07:00 (PT is UTC-7 in April). * Attendees: Karen, Dan Pham, Priya. * Meeting 2: "all-hands" * Title: "all-hands" * Date/Time: "Friday 10am PST". Today is 2025-04-21 (Monday). Friday is 2025-04-25. Time is 10am PST. ISO format: 2025-04-25T10:00:00-08:00 (PST is UTC-8). * Attendees: Dan Pham (running it), team (implied, but let's just list Dan Pham as explicitly mentioned). 3. **Refine Data Extraction:** * *Karen*: name="Karen", role="CTO", email="karen@acme.io", phone=null, mentioned_projects=["Project Aurora", "Project Lumen"] * *Dan Pham*: name="Dan Pham", role="eng lead", email="dan@acme.io", phone="415-555-0198", mentioned_projects=[] * *Priya*: name="Priya", role="product", email="priya.n@acme.io", phone=null, mentioned_projects=[] * *Meeting 1*: title="sync on Project Aurora and the Q3 migration", datetime_iso="2025-04-22T14:30:00-07:00", attendees=["Karen", "Dan Pham", "Priya"] * *Meeting 2*: title="all-hands", datetime_iso="2025-04-25T10:00:00-08:00", attendees=["Dan Pham"] 4. **Format as JSON:** ```json { "people": [ { "name": "Karen", "role": "CTO", "email": "karen@acme.io", "phone": null, "mentioned_projects": ["Project Aurora", "Project Lumen"] }, { "name": "Dan Pham", "role": "eng lead", "email": "dan@acme.io", "phone": "415-555-0198", "mentioned_projects": [] }, { "name": "Priya", "role": "product", "email": "priya.n@acme.io", "phone": null, "mentioned_projects": [] } ], "meetings": [ { "title": "sync on Project Aurora and the Q3 migration", "datetime_iso": "2025-04-22T14:30:00-07:00", "attendees": ["Karen", "Dan Pham", "Priya"] }, { "title": "all-hands", "datetime_iso": "2025-04-25T10:00:00-08:00", "attendees": ["Dan Pham"] } ] } ``` 5. **Double Check Constraints:** * ONLY valid JSON matching the schema. * Do not wrap in markdown. * Schema types: `str`, `str|null`, `[str]`. * Dates: Today is 2025-04-21. Next Tuesday is 2025-04-22. Friday is 2025-04-25. * Timezones: PT is Pacific Time (UTC-7 in April due to DST). PST is Pacific Standard Time (UTC-8). The text says "PT" and "PST". I will use -07:00 for PT and -08:00 for PST. 6. **Final Polish:** Ensure no markdown formatting (like ```json) is present in the output. Just raw JSON string. {"people": [{"name": "Karen", "role": "CTO", "email": "karen@acme.io", "phone": null, "mentioned_projects": ["Project Aurora", "Project Lumen"]}, {"name": "Dan Pham", "role": "eng lead", "email": "dan@acme.io", "phone": "415-555-0198", "mentioned_projects": []}, {"name": "Priya", "role": "product", "email": "priya.n@acme.io", "phone": null, "mentioned_projects": []}], "meetings": [{"title": "sync on Project Aurora and the Q3 migration", "datetime_iso": "2025-04-22T14:30:00-07:00", "attendees": ["Karen", "Dan Pham", "Priya"]}, {"title": "all-hands", "datetime_iso": "2025-04-25T10:00:00-08:00", "attendees": ["Dan Pham"]}]}