Examples · learn/17-typed-replies · 226 of 339
task-1.solution
tin run examples/learn/17-typed-replies/task-1.solution.tintype Event = {
title: string
/// The day, as YYYY-MM-DD
date: string
/// Who organises it
host: string
/// How many people come
guests: int
}
agent Reader { model: "mock", system: "Extract calendar events from messages." }
fn main() {
let e: Event = Reader("6 people for 'Team lunch' on '2026-12-01', 'Ada' is hosting")
print("{e.title} on {e.date}, hosted by {e.host}, {e.guests} guests")
}