Methodology

DAXBench evaluates language models on their ability to write correct, production-grade DAX code. Answers are verified by execution, and scoring goes beyond correctness to measure code quality, performance patterns, and clarity.

Evaluation Pipeline

DAX Task
Prompt + Context
LLM API
Model Inference
Response Parsing
Extract DAX
Execution
Validate Output
Multi-Dim Score
4 Dimensions
DAX Task
Prompt + Context
LLM API
Model Inference
Response Parsing
Extract DAX
Execution
Validate Output
Multi-Dim Score
4 Dimensions

v2 Scoring

Benchmark v2 runs a new task set against prepared Power BI models and is scored separately from v1, so v1 and v2 scores are never compared or mixed.

The v2 tasks and expected results are provided by SQLBI. DAXBench is developed by Maxim Anatsko in collaboration with SQLBI.

  • All or nothing

    A task is correct only if every probe query and every required structural check passes.

  • Probes are diagnostic

    The probes-passed count shows how close an answer came. It is not partial credit and adds no points.

  • Points-first ranking

    Correct tasks earn points weighted by complexity, plus a style bonus from the quality dimensions. Incorrect tasks earn nothing.

  • Format reported separately

    Whether the model followed the requested output format is reported on its own and never changes the score.

  • Incomplete is not incorrect

    If the benchmark or the infrastructure (fixture, parser or provider) fails, the task is marked incomplete and is not counted against the model.

v1 Scoring Dimensions

Correctness
Best Practices
Performance
Clarity

Correctness

Does the code produce the expected output? We verify results through execution against real Power BI data when available.

Best Practices

Does the code follow DAX conventions recommended by the community and Microsoft documentation?

Performance

Does the code use efficient patterns that matter at scale?

Clarity

Is the code readable and maintainable with clear structure and naming?

Correctness Gating: Style scores are only awarded when correctness exceeds a minimum threshold. This prevents models from ranking highly with well-formatted but incorrect code.

Task Design

Real-World Context

Tasks use the Contoso sample database with realistic business scenarios.

Multiple Valid Solutions

Different correct approaches receive full credit.

Execution Validated

Code runs against live Power BI data to verify results.

Tasks span three complexity tiers. Advanced tasks contribute more to the final score.

Basic
Foundational
Intermediate
Common scenarios
Advanced
Complex challenges

Fairness & Transparency

Consistent Conditions

  • Same prompts for all models
  • Identical data model context
  • Standardized inference parameters
  • No model-specific tuning

Transparent Results

  • Per-task success rates shown
  • Dimensional score breakdowns
  • Category-level performance
  • Minimum coverage requirements

Explore the Results

See how different models perform across task categories, complexity levels, and scoring dimensions.

Evaluating language model capabilities in DAX code generation

Developed by Maxim Anatsko in collaboration with SQLBI

maxanatsko