Files
superset2/tests/unit_tests/semantic_layers
Amin Ghadersohi a26a383386 feat(mcp): add semantic layer MCP tools
Adds a semantic-layer surface to the MCP service for LLM-driven metric
discovery and querying across both built-in SqlaTable datasets and
external SemanticView-backed sources:

- list_metrics: unified metric discovery with inline compatible
  dimensions and pagination, sorted deterministically.
- get_table: query a dataset/semantic view by metric + dimension name,
  with time_column/time_range validation.
- get_compatible_dimensions / get_compatible_metrics: progressive
  query-builder support, resolving per-metric compatibility for
  external views.

Includes shared utilities (query_utils.validate_names,
response_utils.format_data_columns), DAO permission filtering
(SemanticViewDAO.find_accessible), and unit test coverage for all
four tools plus the shared utilities and DAO methods.
2026-07-07 03:44:45 +00:00
..