Skip to content

Feature Request: Semantic Layer Support via MCP #427

Description

@b-barry

Problem

Data Formulator currently works mainly with the underlying data/schema.

For analytics use cases, it would be useful to connect Data Formulator to an existing semantic layer so the agent can work with already-defined business concepts such as:

  • Dimensions
  • Measures / metrics
  • Relationships
  • Descriptions
  • Filters

For example, instead of Data Formulator having to infer how revenue should be calculated from database tables, the semantic layer could already expose revenue as a governed measure.

Proposal

Add a way for Data Formulator to consume a semantic layer.

One simple approach could be MCP.

A semantic layer MCP server could expose tools such as:

  • list_models
  • get_model
  • list_dimensions
  • list_measures
  • query

Data Formulator could use these tools when generating an analysis.

Example:

User asks:

Show monthly revenue by country for 2026.

Instead of generating SQL directly from the database schema, Data Formulator could discover:

  • Dimension: month
  • Dimension: country
  • Measure: revenue

and execute the query through the semantic layer.

The resulting dataset can then be visualized normally by Data Formulator.

Example Semantic Layer

One example is Boring Semantic Layer:

https://boringdata.github.io/boring-semantic-layer/about

It provides semantic tables with dimensions and measures on top of Ibis.

The goal would not be to specifically support this implementation, but to provide a generic integration mechanism.

For example:

Data Formulator
      |
      | MCP
      v
Semantic Layer
      |
      +-- Models
      +-- Dimensions
      +-- Measures
      +-- Relationships
      |
      +-- Query
            |
            v
         Dataset
            |
            v
     Data Formulator

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions