---
title: "MQL"
description: "1 posts about MQL, summarised, each linking to the original."
---

# MQL
> 1 posts about MQL, summarised, each linking to the original.

## Articles

### [Introducing AptMQL-Bench: A Text-to-MQL Benchmark](https://yomu.fyi/post/introducing-aptmql-bench-a-text-to-mql-benchmark.md)
- Company: [MongoDB](https://yomu.fyi/company/mongodb.md)
- Published: Oct 21, 2026
- Type: Benchmark

Large language models must reliably translate natural language requests into database query languages, but MQL, MongoDB’s query language, has lacked a dedicated benchmark. The authors introduce AptMQL-Bench, a Text-to-MQL benchmark derived from the BIRD Text-to-SQL dataset, comprising 21 MongoDB databases and 3,186 natural-language requests across domains like commerce and science. They present an agent-driven conversion pipeline that treats schema design as a first-class step, using access-pattern analysis to produce schemas that follow MongoDB’s golden rule of storing accessed-together data together. The pipeline includes automated validation checks and a second optimization pass that rewrote 45% of translated MQL queries to use embedded fields and precomputed aggregates. Evaluations of eight LLMs show the benchmark is challenging, with the best model (Claude Opus 4.5) achieving 70.34% soft execution accuracy with external knowledge, and the authors propose Soft-EX as a more appropriate metric for MQL than strict execution accuracy.
