Skip to content

Show skill scopes per agent - #485

Open
artjen wants to merge 1 commit into
skill-agent-add-commandfrom
skill-agent-status
Open

Show skill scopes per agent#485
artjen wants to merge 1 commit into
skill-agent-add-commandfrom
skill-agent-status

Conversation

@artjen

@artjen artjen commented Sep 3, 2026

Copy link
Copy Markdown
Collaborator

Why

Once agents can have different skill scopes, the old status output is misleading because it shows only the shared list. Developers need to see the effective scope each agent will actually receive.

What changed

This PR makes ucode status display skill MCP locations per agent when those effective scopes differ.

How it works

  • Status computes each configured client's effective scope through the shared scope helper.
  • Divergent scopes render as separate Claude Code, Codex, and other client rows.
  • Identical scopes retain the existing compact shared row.

Builds on agent-scoped configuration in #484.

Testing

  • uv run pytest tests/test_skills_download.py tests/test_mcp.py tests/test_cli.py -q — 502 passed
  • uv run ruff check .
  • uv run ty check src/

Manual staging validation

Validated the stack through this PR against https://eng-ml-inference.staging.cloud.databricks.com with artjen.default.ucode-pr3-cli-smoke.

  • Added artjen.default to Codex only, then to Claude Code only.
  • Confirmed ucode status and each client's MCP URL showed only the intended agent-specific schema.
  • Confirmed the selected agent exposed skill_artjen.default.ucode-pr3-cli-smoke and returned UCODE_PR3_SCOPE_OK.
  • Confirmed the other agent did not expose the schema-specific dynamic tool.

Stack created with GitHub Stacks CLIGive Feedback 💬

@artjen
artjen marked this pull request as ready for review September 3, 2026 20:11
Copilot AI lite review requested due to automatic review settings September 3, 2026 20:11

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🟢 Approval recommended

The change is narrowly scoped to status rendering, reuses the canonical scope-resolution helper, and is covered by a focused CLI test.

Pull request overview

Updates ucode status to accurately reflect agent-scoped Skills MCP configuration by displaying each client’s effective skill scope when clients differ, while keeping the prior compact output when all configured clients share the same scope.

Changes:

  • Compute per-client effective skill locations using the shared skill_locations_for_client(...) helper.
  • Render either a single shared “Skill MCP Locations” row (when identical) or per-client rows (when divergent).
  • Add a CLI regression test covering divergent per-agent scopes.
File summaries
File Description
src/ucode/cli.py Enhances status() Skills section to compute and render per-client effective skill scopes when they differ.
tests/test_cli.py Adds coverage asserting ucode status renders separate skill-location lines for clients when scopes diverge.
Review details
  • Files reviewed: 2/2 changed files
  • Comments generated: 0
  • Review effort level: Lite

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Copilot AI review requested due to automatic review settings September 3, 2026 20:32
@artjen
artjen force-pushed the skill-agent-status branch from fe70b39 to 5774835 Compare September 3, 2026 20:32

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🟢 Approval recommended

The change is localized to status() rendering, leverages the existing scope helper, and is covered by an added CLI test for divergent scopes.

Review details
  • Files reviewed: 2/2 changed files
  • Comments generated: 0 new
  • Review effort level: Lite

@artjen
artjen requested a review from xsh310 September 3, 2026 20:39
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.

2 participants