# Malte Landgren

- **Event:** [Built with Opus 4.7: a Claude Code hackathon](https://cerebralvalley.ai/e/built-with-4-7-hackathon)
- **When:** Apr 21 at 12:00 PM – Apr 27 at 2:00 AM (EDT)
- **Where:** Online
- **Team:** [Malte Landgren](https://cerebralvalley.ai/u/Malte)
- **GitHub:** https://github.com/maltelandgren/orate
- **Demo video:** https://www.youtube.com/watch?v=SutZZU9Spds
- **Gallery:** https://cerebralvalley.ai/e/built-with-4-7-hackathon/hackathon/gallery
- **Page:** https://cerebralvalley.ai/e/built-with-4-7-hackathon/hackathon/gallery/128

Orate is a library for Programmatic Grammar over Inference of LLMs. It unifies structured output, toolcalling under one abstraction, @program, which headline feature is that it allows you to constrain the fields you extract with arbitrary python predicate. Instead of only typing, now we can also guide the output with logic.

The library handles compiling your decorated program schema into a grammar, and how it should recompile when needed depending on how the execution goes (as fields can reference other fields!). These programs are also composable, and it then also handles switching grammars. Today only rudimentary optimizations are in place, like grammar caching so we don't always need to recompute.

---

Markdown version of https://cerebralvalley.ai/e/built-with-4-7-hackathon/hackathon/gallery/128. Site index for agents: https://cerebralvalley.ai/llms.txt · full text: https://cerebralvalley.ai/llms-full.txt
