cd /news/ai-agents/a-semantic-layer-with-an-mcp-server-… · home › topics › ai-agents › article
[ARTICLE · art-174602] src=dev.to ↗ pub= topic=ai-agents verified=true sentiment=↑ positive

A semantic layer with an MCP server: eMondrian gives AI agents your business metrics

The eMondrian project released an open-source semantic layer and OLAP server with a built-in MCP server, included free in the Community edition without a license key, that lets AI agents such as Claude list catalogs, cubes and measures, run MDX queries, and retrieve metrics computed from centrally defined model logic rather than guessing joins and formulas from raw tables. The same MCP server also serves as the authoring tool: agents install database drivers, register databases, write and validate cubes, set roles and users, and build dashboards and Power BI reports, with Excel PivotTables and Power BI reading the same live model. A public read-only demo runs on 182 million US flights in ClickHouse and is reachable via `claude mcp add --transport http emondrian-demo https://demo.emondrian.com/emondrian/mcp`.

key takeaway

Connecting an agent to eMondrian's MCP server lets it query a semantic layer's defined measures via MDX (e.g. TopCount of airlines by flights in 2024) instead of writing SQL against unknown tables, so agent, Excel and Power BI return the same number.

by read4 min views4 publishedNov 23, 2026

eMondrian is an open-source semantic layer and OLAP server with a built-in MCP server. The MCP server is part of the free Community edition and needs no license key. Through it, an AI agent such as Claude lists your catalogs, cubes and measures, runs MDX queries, and gets numbers calculated by the definitions in your model, instead of guessing joins and formulas from raw tables. With the DAX module (a 30-day evaluation key is free), the agent also runs DAX and builds Power BI reports.

The same MCP server is also how you build the semantic layer. An agent installs the database driver and registers the database, writes and checks the cubes, sets the roles, adds users and builds the dashboards and Power BI reports. Every part of the work goes faster when an agent does it, and the MCP server has tools for each of these steps.

Excel PivotTables and Power BI connect to the same model live. The agent, Excel and Power BI read one definition of Revenue, and get one number.

Give an agent access to the database, and it writes SQL against tables it doesn't know. It decides on its own how revenue is calculated, whether returns count, and which join is right. Ask twice and you may get two numbers, neither of them the one in the board report.

A semantic layer defines the numbers once: measures, dimensions, hierarchies, and which rows each person may see. An agent connected to the semantic layer asks for Store Sales by Region, and the server calculates it the way the model says.

The public demo is open without sign-in, with read-only schemas, on 182 million US flights in ClickHouse:

claude mcp add --transport http emondrian-demo https://demo.emondrian.com/emondrian/mcp

In claude.ai: Customize → Connectors, add a custom connector with the URL https://demo.emondrian.com/emondrian/mcp.

On your own server the address is https://<your server>/emondrian/mcp (Streamable HTTP; /emondrian/mcp/sse for clients that only speak SSE). Claude Desktop connects through mcp-remote; any MCP client works. See AI agents (MCP).

"Which five airlines flew the most flights in 2024, and what was their average arrival delay?"

The agent reads the cube with describe_cube, writes the query with the model's names and runs it with execute_query:

SELECT {[Measures].[Flights], [Measures].[Avg Arr Delay]} ON 0,
       TopCount([Airline].[Airline].Members, 5, [Measures].[Flights]) ON 1
FROM [OnTime (attributes)]
WHERE [Time].[2024]
Airline Flights Avg arrival delay, min
WN 1,419,419 12.13
DL 1,009,174 13.19
AA 984,306 23.01
UA 760,451 15.07
OO 744,658 15.96

Flights and Avg Arr Delay are measures of the model. Excel and Power BI on the same cube show the same values.

The agent is the main development tool in eMondrian. It does the work, you review it.

Step MCP tools
Connect a database install_driver ,list_drivers ,save_catalog ,list_source_credentials (you put the database password into.env ; the agent sees only its name)
Read the database describe_source ,validate_source_sql (structure only, no rows)
Write and check a cube get_cube_authoring_guide ,validate_schema ,save_schema ,get_schema ,add_time_measures (YTD, previous year, YoY)
Test the numbers describe_cube ,execute_query (MDX; DAX with the DAX module)
Decide who sees what list_roles ,get_role ,save_role ,delete_role ,set_default_role ;execute_query withas_user to see it as that user (administrators)
Add users and groups (with authentication on) create_user (it can e-mail the user a link to set a password),create_group ,set_user_groups (users who may manage users)
Build dashboards create_dashboard ,update_dashboard ,set_dashboard_access (with a key that includes dashboards)
Build Power BI reports with a live connection make_project ,make_page ,make_visual ,arrange_page ,validate_report (with the DAX module)
Find a problem read_logs ,get_properties

Ask, for example, with a catalog MySales registered and its password in .env: "In catalog MySales, create a cube Sales on the ClickHouse table sales: a Time dimension from sale_date, Region and Product, measures Amount and Quantity, and Avg Price = Amount / Quantity. Validate it, save it, and show total Amount by Region." The agent reads the columns, writes the schema, checks it against the database, saves it and runs the query. The schema is a plain XML file: review it and keep it in Git. With authentication on, changing schemas, roles and drivers and reading logs need administrator rights on the server; the public demo has read-only schemas, so build your first cube on your own Community.

Switch authentication on (one command), and every MCP call runs as the user who signed in: through OAuth in the browser, with a password, or with the user's personal token.

The MCP server, sign-in, roles and the call log are part of the free Community edition. DAX, Power BI reports and dashboards need a key that includes them.

The agent, Excel PivotTables and Power BI read the same model on your own server. Services and scripts get it too, over a REST API with JSON (/api/v1), free in Community. Change a measure once: the agent uses the new definition from its next query, Excel and Power BI from their next connection.

Read more: AI agents (MCP) · Security · REST API (JSON) · Install with Docker

First published on docs.emondrian.com.

── more in #ai-agents 4 stories · sorted by recency
── more on @emondrian 3 stories trending now
sponsored brought to you by zahid.host 4,200+ EU-deployed projects
reading about agents? ship yours in a single git push.

Run your AI side-project on zahid.host

EU-based hosting, git-push deploys, automatic HTTPS, no cold starts. Free tier with a custom domain — perfect for shipping the agent you just read about.

$git push zahid main
→ Live at https://your-agent.zahid.host ✓
Get free account → Pricing
from €0/mo · no card required
LIVE [news/a-semantic-layer-wit…] indexed:0 read:4min 2026-11-23 · —