Define a schema as a Raku Grammar with named tokens
Use LLM::Functions to normalize free-form text to your DSL
Parse the DSL with Grammar + Actions
Get typed, validated structured output
Build schema-driven pipelines instead of fragile regex or prompt hacks
Add a token-address subrule with its own sub-tokens, and a nested class inside Booking. The Actionable role composes naturally.
Wire extract-booking as a tool in an LLM::Functions agent so the LLM can invoke it mid-conversation.
Parse incrementally as the LLM streams tokens — useful when the DSL is long.
Catch a failed parse, feed the raw LLM output back with an error message, and ask it to correct the DSL. Usually one retry is enough.
Use the structured Booking / Ticket objects as typed messages passed between agents in a multi-step pipeline.
Paste any Grammar + Actions pair into https://slangify.org to test and share your DSL interactively — no local install needed.