Skip to content

feat(mason): support Unity Catalog agent skills - #492

Open
junchoi-db wants to merge 5 commits into
databricks:mainfrom
junchoi-db:jun-choi_data/feat/mason-agent-skills
Open

feat(mason): support Unity Catalog agent skills#492
junchoi-db wants to merge 5 commits into
databricks:mainfrom
junchoi-db:jun-choi_data/feat/mason-agent-skills

Conversation

@junchoi-db

@junchoi-db junchoi-db commented Aug 31, 2026

Copy link
Copy Markdown
Contributor

What

Adds declarative Unity Catalog Skills support to Mason's LangGraph template:

  • mason skills list --schema catalog.schema discovers UC skills through the workspace Skills endpoint.
  • mason skills add uc catalog.schema.skill --source . writes an exact, idempotent [[skills]] binding to agent.toml.
  • Graph construction injects skill name/description metadata only. load_skill fetches instructions lazily, and read_skill_file fetches referenced files lazily through get_skill_files.
  • The same binding is used in local development and Databricks Apps; skill bodies and references are never copied into the project or deployment.
[[skills]]
id = "review"
source = { kind = "uc", name = "catalog.schema.skill" }

Why

Custom agents need a declarative skill contract with progressive disclosure while keeping skill content governed in Unity Catalog and fresh at invocation time.

Scope and limits

  • Unity Catalog skills only. Local, custom, and path-based skill sources are rejected.
  • LangGraph template only; nonempty OpenAI skill declarations fail before dev/deploy side effects.
  • Exact three-part UC names only; versions, automatic discovery, and local file copying are not supported.
  • Prompt injection is metadata-only. Instruction and reference payloads are fetched remotely and bounded to 1 MiB of UTF-8 text.
  • A deployed App principal needs USE_CATALOG, USE_SCHEMA, and READ_VOLUME on each bound
    skill. The legacy READ_SKILL privilege does not authorize metadata or bundle reads.

CLI customer journey

MASON=/path/to/databricks-ai-bridge/integrations/mason/.venv/bin/mason
PROJECT=/tmp/mason-uc-skill-cuj

"$MASON" --profile <workspace-profile> init --framework langgraph \
  --profile <workspace-profile> --repo /path/to/databricks-ai-bridge \
  --ref feat/mason-agent-skills "$PROJECT"

"$MASON" --profile <workspace-profile> skills list \
  --schema catalog.schema
"$MASON" --profile <workspace-profile> skills add uc \
  catalog.schema.skill --source "$PROJECT"

"$MASON" --profile <workspace-profile> dev --source "$PROJECT"
"$MASON" --profile <workspace-profile> deploy <unique-app-name> \
  --source "$PROJECT"

Verification

  • Isolated Mason base-install suite: 223 passed on the rebased head.
  • Ruff lint/format and ty check: passed.
  • Live CLI/local-agent CUJ on product SHA d821203: list, idempotent add, exact manifest binding,
    no local file copy, lazy body loading, and lazy referenced-file loading passed. After the final
    conflict-free rebase, git range-diff maps that product patch identically to 9163537.
  • Clean deployed-App CUJ: body prompt called load_skill({"skill_id":"uc-cuj"}); reference prompt
    called load_skill then
    read_skill_file({"skill_id":"uc-cuj","path":"references/proof.txt"}). Both completed with
    HTTP 200 and exact proof markers after granting the App principal READ_VOLUME.
  • The generated agent/agent.py was byte-identical to the template before the final deployment;
    the deployment source contained no copied skill body or reference file.
  • Temporary App, workspace deployment source, and UC skill were deleted and verified absent.
  • Internal CLI/CUJ HTML report SHA-256:
    b944c5b7c340e6964d95d799185a9786fcf6c89165d1843ea1bedf68f2dba891 (byte-identical publish
    round trip). The reproducible commands and decisive proof are included above without exposing
    private workspace/report URLs in this public PR.

Design reference

This pull request and its description were written by Isaac.

@junchoi-db
junchoi-db force-pushed the jun-choi_data/feat/mason-agent-skills branch from 64ee3de to 01929d2 Compare August 31, 2026 21:59
@junchoi-db junchoi-db changed the title feat(mason): support declarative agent skills feat(mason): support project-local agent skills Aug 31, 2026
@junchoi-db
junchoi-db marked this pull request as ready for review August 31, 2026 22:01
@junchoi-db
junchoi-db force-pushed the jun-choi_data/feat/mason-agent-skills branch from 01929d2 to bc754bf Compare September 1, 2026 17:32
import tomli as tomllib


_MAX_SKILLS = 60

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what is this limit for

@junchoi-db
junchoi-db force-pushed the jun-choi_data/feat/mason-agent-skills branch from bc754bf to ccaddb3 Compare September 1, 2026 23:55
@junchoi-db junchoi-db changed the title feat(mason): support project-local agent skills feat(mason): support Unity Catalog agent skills Sep 2, 2026
@junchoi-db
junchoi-db force-pushed the jun-choi_data/feat/mason-agent-skills branch from 3bd51ca to ef2daa1 Compare September 2, 2026 00:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant