LMQL logo

LMQL

Effortlessly query and control language models with LMQL, the versatile AI programming language.

Screenshots

LMQL screenshot 1

About

LMQL, an AI programming language, was specifically developed for seamless interaction with large language models. Offering users the ability to leverage high-level constraints and Python programming, LMQL empowers individuals to query language models and regulate their responses effectively. The tool encompasses a range of functionalities, including debugging, decoding, interaction, control flow, and chatbot capabilities. Users can easily specify constraints such as length, stopping phrases, and token masking to shape the behavior of the model. LMQL offers a comprehensive and adaptable prompting system comprising types, templates, constraints, and an optimizing runtime. Developed by the SRI Lab at ETH Zurich, LMQL enables procedural programming with prompts, enabling the creation of structured and reusable code for LLMs. It is compatible with various backends and emphasizes safety and transparency.

Category

Development

Tags

AI Programming LanguageLarge Language ModelsConstraintsPythonDebuggingDecodingChatbotMeta-PromptingNatural Language Processing

Pricing

Freemium

Listed

December 24, 2025