data-agent
Manage data agents (create, query, and interact with AI agents)
Authentication scope: fabric
List data agents in a workspace
fabio data-agent list --workspace <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
Read-only · Returns list
Show details of a data agent
fabio data-agent show --workspace <value> --id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Data agent ID |
Read-only · Returns object
create
Section titled “create”Create a new data agent
fabio data-agent create --workspace <value> --name <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--name |
string |
Yes | Data agent display name |
--description |
string |
No | Data agent description (max 256 characters) |
--sensitivity-label |
string |
No | Sensitivity label ID to apply on creation |
Examples
fabio data-agent create --workspace $WS --name "SalesAssistant"Mutates state · Returns object
update
Section titled “update”Update a data agent (name and/or description)
fabio data-agent update --workspace <value> --id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Data agent ID |
--name |
string |
No | New display name |
--description |
string |
No | New description (max 256 characters) |
Mutates state · Returns object
delete
Section titled “delete”Delete a data agent
fabio data-agent delete --workspace <value> --id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Data agent ID |
--hard-delete |
bool |
No | Permanently delete (cannot be recovered) |
Mutates state · Destructive · Returns void
Query (chat with) a published data agent using natural language
fabio data-agent query --workspace <value> --id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Data agent ID |
--prompt |
string |
No | Natural language question (omit to read from stdin) |
--published-url |
string |
No | Published URL (from portal Settings page after publishing the agent) |
--show-steps |
bool |
No | Include execution details (SQL queries, tool calls, run steps) |
--stage |
string |
No | Agent stage to query: only production (published) is supported via the public API Default: production. |
--thread-id |
string |
No | Reuse an existing thread for a multi-turn follow-up (from a prior query’s threadId) |
--keep-thread |
bool |
No | Keep the thread after the query (returns its threadId for a follow-up turn) |
--download-files |
string |
No | Download files attached to the answer into this directory (e.g. generated CSVs/charts) |
--visuals |
bool |
No | Extract chart/visual specifications the agent generated (chart type, axes, title, sort, and the aggregated data) into a visuals array in the output |
--timeout |
integer |
No | Maximum wait time in seconds for the query to complete (default: 300) Default: 300. |
Examples
fabio data-agent query --workspace $WS --id $DA --prompt "Who is the top customer by revenue?"fabio data-agent query --workspace $WS --id $DA --prompt "Remember the number 7." --keep-threadfabio data-agent query --workspace $WS --id $DA --prompt "What number did I mention?" --thread-id thread_abc123fabio data-agent query --workspace $WS --id $DA --prompt "Chart monthly revenue as a CSV" --download-files ./outfabio data-agent query --workspace $WS --id $DA --prompt "Complex query..." --timeout 600 --show-stepsRead-only · Returns object
evaluate
Section titled “evaluate”Batch-run a set of questions against a published data agent (evaluation primitive)
fabio data-agent evaluate --workspace <value> --id <value> --questions <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Data agent ID |
--questions |
string |
Yes | Questions file: JSON (array of strings, or [{“question”,“expected”}]) or CSV/TSV with a question column (optional expected) |
--published-url |
string |
No | Published URL (from portal Settings page after publishing the agent) |
--repeats |
string |
No | Number of times to run each question (default: 1) |
--show-steps |
bool |
No | Include execution details (SQL queries, tool calls, run steps) per run |
--stage |
string |
No | Agent stage to query: only production (published) is supported via the public API |
--timeout |
string |
No | Maximum wait time in seconds per question run (default: 300) |
--llm-endpoint |
string |
No | LLM judge endpoint to grade answers (Azure OpenAI resource URL or OpenAI-compatible base). Enables LLM grading |
--llm-key |
string |
No | LLM judge API key |
--llm-model |
string |
No | LLM judge model (Azure deployment name, or model id for OpenAI-compatible) |
--llm-api-version |
string |
No | Azure OpenAI API version (default: 2024-10-21) |
Examples
fabio data-agent evaluate --workspace $WS --id $DA --questions questions.jsonfabio data-agent evaluate --workspace $WS --id $DA --questions qs.csv --repeats 3 --show-stepsfabio data-agent evaluate --workspace $WS --id $DA --questions qs.json --llm-endpoint https://r.openai.azure.com --llm-key $KEY --llm-model gpt-4oRead-only · Returns object
validate-fewshots
Section titled “validate-fewshots”Validate a data source’s few-shot examples with an LLM (duplicates, conflicts, quality)
fabio data-agent validate-fewshots --workspace <value> --id <value> --datasource <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Data agent ID |
--datasource |
string |
Yes | Data source name or ID |
--stage |
string |
No | Stage to read: staging (draft) or published (live). Default: staging |
--llm-endpoint |
string |
No | LLM judge endpoint (Azure OpenAI resource URL or OpenAI-compatible base). Required |
--llm-key |
string |
No | LLM judge API key. Required |
--llm-model |
string |
No | LLM judge model (Azure deployment name, or model id for OpenAI-compatible). Required |
--llm-api-version |
string |
No | Azure OpenAI API version (default: 2024-10-21) |
Examples
fabio data-agent validate-fewshots --workspace $WS --id $DA --datasource MyLakehouse --llm-endpoint https://r.openai.azure.com --llm-key $KEY --llm-model gpt-4oFABIO_LLM_ENDPOINT=https://r.openai.azure.com FABIO_LLM_KEY=$KEY FABIO_LLM_MODEL=gpt-4o fabio data-agent validate-fewshots --workspace $WS --id $DA --datasource MyLakehouseRead-only · Returns object
mcp-url
Section titled “mcp-url”Print the Model Context Protocol (MCP) endpoint URL for consuming a published data agent
fabio data-agent mcp-url --workspace <value> --id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Data agent ID |
Read-only · Returns object
get-config
Section titled “get-config”Get the configuration of a data agent (instructions, data sources, preview runtime)
fabio data-agent get-config --workspace <value> --id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Data agent ID |
--stage |
string |
No | Stage to read: staging (draft) or published (live). Default: staging |
Examples
fabio data-agent get-config --workspace $WS --id $DAfabio data-agent get-config -w $WS --id $AGENT --stage publishedRead-only · Returns object
update-config
Section titled “update-config”Update the configuration of a data agent (instructions, preview runtime)
fabio data-agent update-config --workspace <value> --id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Data agent ID |
--instructions |
string |
No | AI instructions for the agent (guides data source selection and query generation) |
--instructions-file |
string |
No | Path to file containing AI instructions (alternative to –instructions) |
--enable-preview-runtime |
bool |
No | Enable preview runtime (multi-step reasoning: Advanced NL2SQL for SQL sources AND Advanced DAX generation for semantic models) |
--disable-preview-runtime |
bool |
No | Disable preview runtime (revert to the single-pass standard runtime: GA NL2SQL / standard DAX generation) |
Examples
fabio data-agent update-config --workspace $WS --id $DA --instructions "Answer questions about sales data. Use SQL for lakehouse tables."fabio data-agent update-config --workspace $WS --id $DA --instructions-file instructions.txtfabio data-agent update-config --workspace $WS --id $DA --enable-preview-runtimeMutates state · Returns object
list-datasources
Section titled “list-datasources”List configured data sources for a data agent
fabio data-agent list-datasources --workspace <value> --id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Data agent ID |
--stage |
string |
No | Stage to read: staging (draft) or published (live). Default: staging |
Examples
fabio data-agent list-datasources --workspace $WS --id $DARead-only · Returns list
show-datasource
Section titled “show-datasource”Show details of a configured data source
fabio data-agent show-datasource --workspace <value> --id <value> --datasource <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Data agent ID |
--datasource |
string |
Yes | Data source name or ID |
--stage |
string |
No | Stage to read: staging (draft) or published (live). Default: staging |
Examples
fabio data-agent show-datasource --workspace $WS --id $DA --datasource "SalesLakehouse"Read-only · Returns object
add-datasource
Section titled “add-datasource”Add a data source to the agent (auto-discovers schema from artifact)
fabio data-agent add-datasource --workspace <value> --id <value> --artifact <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Data agent ID |
--artifact |
string |
Yes | Artifact name or ID (lakehouse, warehouse, KQL database, semantic model, etc.) |
--artifact-workspace |
string |
No | Workspace containing the artifact (defaults to same workspace as agent) |
--artifact-type |
string |
No | Artifact type (auto-detected if omitted). Values: Lakehouse, Warehouse, KQLDatabase, SemanticModel, Ontology, GraphModel, MirroredDatabase, SQLDatabase |
--instructions |
string |
No | Data source instructions (how the agent should use this source) |
Examples
fabio data-agent add-datasource --workspace $WS --id $DA --artifact "SalesLakehouse"fabio data-agent add-datasource --workspace $WS --id $DA --artifact $LAKEHOUSE_ID --artifact-type Lakehouse --instructions "Contains product catalog and order history"Mutates state · Returns object
remove-datasource
Section titled “remove-datasource”Remove a data source from the agent
fabio data-agent remove-datasource --workspace <value> --id <value> --datasource <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Data agent ID |
--datasource |
string |
Yes | Data source name or ID to remove |
Examples
fabio data-agent remove-datasource --workspace $WS --id $DA --datasource "SalesLakehouse"Mutates state · Destructive · Returns object
update-datasource
Section titled “update-datasource”Update a data source’s metadata (instructions, description)
fabio data-agent update-datasource --workspace <value> --id <value> --datasource <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
uuid |
Yes | Workspace ID |
--id |
uuid |
Yes | Data agent ID |
--datasource |
string |
Yes | Data source name or ID |
--instructions |
string |
No | New data source instructions (how the agent should use this source) |
--description |
string |
No | New description for the data source |
Examples
fabio data-agent update-datasource -w $WS --id $AGENT --datasource "SalesLakehouse" --instructions "Contains order history and product catalog. Use for sales analytics queries."Mutates state · Returns void
list-fewshots
Section titled “list-fewshots”List few-shot examples for a data source
fabio data-agent list-fewshots --workspace <value> --id <value> --datasource <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Data agent ID |
--datasource |
string |
Yes | Data source name or ID |
--stage |
string |
No | Stage to read: staging (draft) or published (live). Default: staging |
Examples
fabio data-agent list-fewshots --workspace $WS --id $DA --datasource $LH_IDRead-only · Returns list
show-fewshot
Section titled “show-fewshot”Show a specific few-shot example by ID
fabio data-agent show-fewshot --workspace <value> --id <value> --datasource <value> --fewshot-id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
uuid |
Yes | Workspace ID |
--id |
uuid |
Yes | Data agent ID |
--datasource |
string |
Yes | Data source name or ID |
--fewshot-id |
uuid |
Yes | Few-shot example ID |
--stage |
string |
No | Stage to read: staging (draft) or published (live). Default: staging |
Examples
fabio data-agent show-fewshot -w $WS --id $AGENT --datasource "SalesLakehouse" --fewshot-id $FS_IDRead-only · Returns object
add-fewshot
Section titled “add-fewshot”Add a few-shot example (question/query pair) to a data source
fabio data-agent add-fewshot --workspace <value> --id <value> --datasource <value> --question <value> --answer <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Data agent ID |
--datasource |
string |
Yes | Data source name or ID |
--question |
string |
Yes | Natural language question |
--answer |
string |
Yes | The example query that answers the question, in the data source’s language (SQL for lakehouse/warehouse, KQL for a KQL database, GQL for graph/ontology). Aliases: –sql/–kql/–dax/–gql |
Examples
fabio data-agent add-fewshot --workspace $WS --id $DA --datasource $LH_ID --question "Who is the top customer by revenue?" --answer "SELECT TOP 1 customer_name, SUM(total_amount) as revenue FROM orders GROUP BY customer_name ORDER BY revenue DESC"Mutates state · Returns object
update-fewshot
Section titled “update-fewshot”Update an existing few-shot example (question and/or query)
fabio data-agent update-fewshot --workspace <value> --id <value> --datasource <value> --fewshot-id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
uuid |
Yes | Workspace ID |
--id |
uuid |
Yes | Data agent ID |
--datasource |
string |
Yes | Data source name or ID |
--fewshot-id |
uuid |
Yes | Few-shot example ID to update |
--question |
string |
No | Updated natural language question |
--answer |
string |
No | Updated example query (aliases: –sql/–kql/–dax/–gql) |
Examples
fabio data-agent update-fewshot -w $WS --id $AGENT --datasource "SalesLakehouse" --fewshot-id $FS_ID --answer "SELECT COUNT(DISTINCT customer_id) FROM orders"Mutates state · Returns void
remove-fewshot
Section titled “remove-fewshot”Remove a few-shot example by ID
fabio data-agent remove-fewshot --workspace <value> --id <value> --datasource <value> --fewshot-id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Data agent ID |
--datasource |
string |
Yes | Data source name or ID |
--fewshot-id |
string |
Yes | Few-shot example ID to remove |
Examples
fabio data-agent remove-fewshot --workspace $WS --id $DA --datasource $LH_ID --fewshot-id $FEWSHOT_IDMutates state · Destructive · Returns object
clear-fewshots
Section titled “clear-fewshots”Delete all few-shot examples for a data source
fabio data-agent clear-fewshots --workspace <value> --id <value> --datasource <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
uuid |
Yes | Workspace ID |
--id |
uuid |
Yes | Data agent ID |
--datasource |
string |
Yes | Data source name or ID |
Examples
fabio data-agent clear-fewshots -w $WS --id $AGENT --datasource "SalesLakehouse"Mutates state · Destructive · Returns void
upload-fewshots
Section titled “upload-fewshots”Bulk upload few-shot examples from a JSON or CSV file
fabio data-agent upload-fewshots --workspace <value> --id <value> --datasource <value> --file <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Data agent ID |
--datasource |
string |
Yes | Data source name or ID |
--file |
string |
Yes | File with few-shots (JSON: [{“question”:“…”, “query”:“…”}] or CSV with question,query columns) |
Examples
fabio data-agent upload-fewshots --workspace $WS --id $DA --datasource $LH_ID --file fewshots.jsonfabio data-agent upload-fewshots --workspace $WS --id $DA --datasource $LH_ID --file fewshots.csvMutates state · Returns object
select-tables
Section titled “select-tables”Select or unselect data-source elements (tables, or ontology/graph entity types)
fabio data-agent select-tables --workspace <value> --id <value> --datasource <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Data agent ID |
--datasource |
string |
Yes | Data source name or ID |
--tables |
string |
No | Comma-separated table names to select (e.g. “orders,products,customers”) |
--all-tables |
bool |
No | Select all tables |
--elements |
string |
No | Comma-separated element names of any type to select (e.g. ontology entity types on an Ontology/GraphModel data source) |
--all-elements |
bool |
No | Select all elements regardless of type |
--unselect |
bool |
No | Unselect (instead of select) |
Examples
fabio data-agent select-tables --workspace $WS --id $DA --datasource $LH_ID --tables "orders,products,customers"fabio data-agent select-tables --workspace $WS --id $DA --datasource $LH_ID --all-tablesfabio data-agent select-tables --workspace $WS --id $DA --datasource $LH_ID --tables "staging_raw" --unselectMutates state · Returns object
list-elements
Section titled “list-elements”List elements (tables, columns) in a data source with selection state and descriptions
fabio data-agent list-elements --workspace <value> --id <value> --datasource <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Data agent ID |
--datasource |
string |
Yes | Data source name or ID |
--stage |
string |
No | Stage to read: staging (draft) or published (live). Default: staging |
Examples
fabio data-agent list-elements --workspace $WS --id $DA --datasource $LH_IDRead-only · Returns list
describe-element
Section titled “describe-element”Set or clear a description on a table or column in a data source
fabio data-agent describe-element --workspace <value> --id <value> --datasource <value> --path <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Data agent ID |
--datasource |
string |
Yes | Data source name or ID |
--path |
string |
Yes | Dot-separated path to the element (e.g. dbo.orders for a table, dbo.orders.total_amount for a column) |
--description |
string |
No | Description text (omit or pass empty string to clear) |
Examples
fabio data-agent describe-element --workspace $WS --id $DA --datasource $LH_ID --path "dbo.orders" --description "Customer orders with amounts and shipping dates"fabio data-agent describe-element --workspace $WS --id $DA --datasource $LH_ID --path "dbo.orders.total_amount" --description "Total order value in USD including tax"Mutates state · Returns object
delete-element
Section titled “delete-element”Delete a stale schema element (only elements no longer in the live schema)
fabio data-agent delete-element --workspace <value> --id <value> --datasource <value> --element-id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
uuid |
Yes | Workspace ID |
--id |
uuid |
Yes | Data agent ID |
--datasource |
string |
Yes | Data source name or ID |
--element-id |
string |
Yes | Element ID to delete (from list-elements output) |
Examples
fabio data-agent delete-element -w $WS --id $AGENT --datasource "SalesLakehouse" --element-id "dbo.deprecated_table"Mutates state · Destructive · Returns void
get-definition
Section titled “get-definition”Get the definition of a data agent (configuration, data sources, etc.)
fabio data-agent get-definition --workspace <value> --id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Data agent ID |
--decode |
bool |
No | Decode base64 payloads inline (adds decodedPayload field) |
Read-only · Long-running operation · Returns object
update-definition
Section titled “update-definition”Update the definition of a data agent (configure data sources, instructions, etc.)
fabio data-agent update-definition --workspace <value> --id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Data agent ID |
--file |
string |
No | Path to definition file (JSON with parts array) |
--content |
string |
No | Inline JSON definition (alternative to –file) |
--update-metadata |
bool |
No | Also update item metadata from .platform file if present |
Mutates state · Long-running operation · Returns void
publish
Section titled “publish”Publish a data agent (promotes draft configuration to published state)
fabio data-agent publish --workspace <value> --id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Data agent ID |
--description |
string |
No | Optional publish description |
--to-m365 |
bool |
No | Also publish to Microsoft 365 Copilot Agent Store |
Examples
fabio data-agent publish --workspace $WS --id $DA --description "v1.0 production"fabio data-agent publish --workspace $WS --id $DA --to-m365Mutates state · Returns object
Reset staging (discard all draft changes, revert to published state)
fabio data-agent reset --workspace <value> --id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
uuid |
Yes | Workspace ID |
--id |
uuid |
Yes | Data agent ID |
Examples
fabio data-agent reset -w $WS --id $AGENTMutates state · Destructive · Returns void
