cd /news/artificial-intelligence/how-i-built-a-databricks-ai-agent-wi… · home topics artificial-intelligence article
[ARTICLE · art-41403] src=dev.to ↗ pub= topic=artificial-intelligence verified=true sentiment=↑ positive

How I Built a Databricks AI Agent with No Custom Tables (OpenAI Agents SDK + Gradio)

A developer built a fully working conversational AI agent on Databricks without custom tables or Vector Search, using only the built-in samples.tpch dataset. The stack includes OpenAI Agents SDK, Databricks Model Serving with Llama 3.3 70B, Databricks SQL Connector, MLflow, and Gradio UI deployed via Databricks Apps. Key challenges included using AsyncOpenAI instead of OpenAI, applying nest_asyncio, and using SQL Connector instead of Spark.

read1 min views1 publishedJun 26, 2026

Most Databricks agent tutorials start with "set up Unity Catalog and Vector Search first."

This one doesn't. I built a fully working conversational agent using only samples.tpch — the dataset that ships in every Databricks workspace by default. No custom tables, no Vector Search index, no catalog setup.

The stack:

  • OpenAI Agents SDK (with AsyncOpenAI — important, sync breaks it)
  • Databricks Model Serving (Llama 3.3 70B via OpenAI-compatible endpoint)
  • Databricks SQL Connector (not Spark — Apps have no Spark context)
  • MLflow for experiment tracking
  • Gradio chat UI deployed via Databricks Apps
  • OAuth credentials injected automatically — no tokens in code

The pattern that made it work:

Write an AGENTS.md instruction file with constraints, folder structure, SQL queries, and a validation checklist. Run one Codex prompt. Get a complete working codebase.

codex "implement everything described in AGENTS.md"

The three errors that will block you if you don't know:

  • AsyncOpenAI not OpenAI — the Agents SDK is async internally, sync client crashes at the model call.
  • nest_asyncio.apply() at module load — Databricks notebooks run a persistent event loop, Runner.run_sync() fails without this patch.
  • SQL Connector not Spark — Databricks Apps have no Spark context, spark.sql() crashes silently in the App runtime. Full walkthrough with all errors, architecture, deployment steps, and production caveats: 👉 Read the full article on
[Medium](https://medium.com/@dipayan-x-das/build-a-databricks-ai-agent-in-one-session-no-unity-catalog-or-vector-search-required-7b79f589d316?sharedUserId=dipayan-x-das)
GitHub: [github.com/dipayanthedata/DatabricksAgentDemo](https://github.com/dipayanthedata/DatabricksAgentDemo)
── more in #artificial-intelligence 4 stories · sorted by recency
── more on @databricks 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/how-i-built-a-databr…] indexed:0 read:1min 2026-06-26 ·