Skip to main content Link Menu Expand (external link) Document Search Copy Copied

Task 02: Connect Azure Databricks Genie to Microsoft Foundry

Introduction

Microsoft Foundry allows AI agents to connect to external tools, including Databricks Genie.

Description

In this task, you’ll add an agent and add your Genie MCP server as a tool.

Example scenario

Zava exposes Genie-powered insights through a Foundry agent for broader consumption.

Success criteria

The Foundry agent successfully queries Genie and returns insights.

Learning resources

  • Microsoft Foundry agents
  • Tool grounding and orchestration

Key steps

01: Create a Microsoft Foundry agent

  1. Open a browser tab and go tohttps://portal.azure.com.

  2. If prompted, sign in by using the following credentials:

    Setting Value
    Username @lab.CloudPortalCredential(User1).Username
    Temporary Access Pass (TAP) token @lab.CloudPortalCredential(User1).AccessToken
  3. In the Search field, enter Resource Groups.

    3vjagv6y.jpg

  4. In the list of resource groups, select ResourceGroup1.

    ljgiy5dd.jpg

  5. In the list of resources, select the firstproject project.

    9igv32w4.jpg

  6. On the page for the project, select Go to Foundry portal to launch Microsoft Foundry.

    6m7xwhpy.jpg

  7. At the top of the page, set New Foundry to On.

    9600zodb.jpg

  8. On the command bar, select the dropdown arrow next to firstproject and then select Create a new project.

    o9s2veuj.png

  9. Foundry creates a project name. Remove the [-####] suffix from the end of the name.

    The created project name will look like this example: User1-11111111-2222

    Removing the suffix will render the name like this example: User1-11111111

  10. Expand the Advanced options and change the resource group to ResourceGroup1 if necessary.

  11. In the Create a project dialog, select Create.

    create-prject.png

  12. In the confirmation dialog that displays, select Let’s go.

    4shwpmsu.png

  13. In the Start building field, select Create agents.

    pk35q6qz.jpg

  14. In the Create an agent dialog, in the Agent name field, enter Genie-Agent@lab.LabInstance.GlobalId and then select Create.

    f3i91fq2.jpg


02: Connect the agent to the genie

  1. In the left pane, select Tools.

    l3tlor7j.jpg

  2. On the Tools page, select Connect a tool.

    ugjoqy79.jpg

  3. In the Select a tool dialog, select the Catalog tab and then select Azure Databricks Genie.

    u1kdcxtt.jpg

  4. Select Create.

  5. Configure the tool by entering the following values and then select Connect.

    Field Value
    Name AzuretGenie@lab.LabInstance.Id
    genie_space_id @lab.Variable(GenieSpaceID)
    workspace-hostname @lab.Variable(DatabricksAccountID)
    OAuth Provider Managed

    8yrhuuwi.jpg

  6. On the AzureGenie page, select Use in an agent and then select Genie-Agent@lab.LabInstance.GlobalId.

    k4e5rqr4.jpg

  7. On the command bar, select Publish and then select Publish agent.

    2ve6p9gi.jpg

  8. In the confirmation dialog, select Publish.

    zx5if613.jpg

  9. In the Agent published successfully dialog, select Close.

    vskrk8cr.jpg

  10. Submit the following prompt:

    What is the distribution of customers by Gender?

    Azure Databricks Genie in Microsoft Foundry supports up to five questions per minute due to Genie API rate limits.

  11. If prompted, sign in by using the following credentials and then select Allow access:

    Setting Value
    Username @lab.CloudPortalCredential(User1).Username
    Temporary Access Pass (TAP) token @lab.CloudPortalCredential(User1).AccessToken
  12. In the response from the agent, select Approve and then select Always approve this tool.

    buj6yy5y.jpg

  13. In the response, select Debug to view the conversation flow and tool usage.

    azwoj1vc.jpg