databricks-genie

Create and query Databricks Genie Spaces for natural language SQL exploration.

Updated Mar 5, 2026
One-click install
npx skills add https://github.com/FMurray/mlfts --skill databricks-genie-fmurray
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: databricks-genie
Source: https://github.com/FMurray/mlfts/tree/main/.agents/skills/databricks-genie
Command: npx skills add https://github.com/FMurray/mlfts --skill databricks-genie-fmurray

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Business users often cannot write SQL, and analysts spend time translating plain-language questions into queries against Unity Catalog data. This Skill guides the creation of Databricks Genie Spaces and programmatic querying through the Genie Conversation API so natural language questions return SQL-generated answers. ## Core Features & Use Cases - Genie Space Creation: Inspect table schemas with get_table_details, then create spaces with create_or_update_genie including descriptions, table identifiers, and sample questions referencing actual column names. - Conversation API Querying: Ask questions with ask_genie and maintain context across follow-ups with ask_genie_followup using conversation IDs. - Warehouse Auto-Detection: Automatically select a running SQL warehouse when no warehouse_id is provided. - Use Case: After building silver-layer sales tables, create a "Sales Analytics" Genie Space, then test it by asking "What were total sales last month?" and following up with "Break that down by region." ## Quick Start Ask the agent to inspect your Unity Catalog tables, create a Genie Space with sample questions, and test it with a natural language question.

Frequently Asked Questions about databricks-genie

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I create a Databricks Genie Space?

First inspect your tables with get_table_details to learn column names and types, then call create_or_update_genie with a display name, table identifiers, a description of table relationships, and sample questions referencing actual columns.

How do I ask questions to a Genie Space programmatically?

Use the ask_genie tool with a space_id and your natural language question. It returns the generated SQL, columns, data rows, and a conversation_id you can pass to ask_genie_followup for context-aware follow-up questions.

When should I use ask_genie instead of execute_sql?

Use ask_genie when the space has curated business logic, certified queries, or the user explicitly requests Genie. Use execute_sql for simple ad-hoc queries, when you already have exact SQL, or when no Genie Space exists for the data.

Which tables should I add to a Genie Space?

Prefer silver and gold layer tables since they are cleaned and optimized for analytics; avoid bronze raw data. Include related tables that join together, use descriptive column names, and add table comments so Genie understands the data.

Why does Genie generate poor SQL queries?

Poor query generation usually comes from vague column names, missing table comments, or a lack of sample questions. Add instructions and sample questions that reference actual column names, and curate the space further in the Databricks UI.

What happens if no SQL warehouse is available for Genie?

If warehouse_id is not specified, the tool auto-detects warehouses, preferring running ones and smaller sizes. If none exist, it returns an error, so you must create a SQL warehouse or provide a warehouse_id explicitly.