Skip to content

skill: add additive skill configuration - #466

Open
artjen wants to merge 1 commit into
mainfrom
skill-add
Open

skill: add additive skill configuration#466
artjen wants to merge 1 commit into
mainfrom
skill-add

Conversation

@artjen

@artjen artjen commented Sep 2, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • Add the ucode skill add command namespace.
  • Add schemas to the Skills MCP connection without replacing existing schemas.
  • Support additive disk downloads with named and fully-qualified skill selection.
  • Preserve all existing ucode configure skills behavior.

Part 1 of the skill CLI series.

Testing

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

Stack created with GitHub Stacks CLIGive Feedback 💬

@artjen
artjen marked this pull request as ready for review September 2, 2026 21:19
Copilot AI lite review requested due to automatic review settings September 2, 2026 21:19

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 implementation and validation logic align with the documented behavior, and the PR adds focused test coverage for both the MCP union path and CLI parsing/dispatch.

Pull request overview

This PR adds a new ucode skill add CLI command to support additive Skills configuration: it can either (1) union new UC skill schema scopes into the existing Skills MCP connection (--mcp), or (2) download skills to disk without removing existing downloads, including support for selecting named skills via bare or fully-qualified identifiers.

Changes:

  • Added ucode skill add CLI surface area with validation for --location, --mcp, --path, and --skills (including fully-qualified <catalog>.<schema>.<name> handling).
  • Implemented additive Skills MCP scope updates via _union_locations(...) and add_skills_command(...).
  • Added test coverage for both the unioning behavior and CLI argument parsing/dispatch, plus README documentation for the new command.
File summaries
File Description
tests/test_mcp.py Adds unit tests for _union_locations and add_skills_command additive scope behavior.
tests/test_cli.py Adds CLI tests ensuring ucode skill add validates flags correctly and dispatches to MCP union vs download modes.
src/ucode/mcp.py Introduces _union_locations and add_skills_command to merge new schema scopes into the existing Skills MCP connection.
src/ucode/cli.py Adds the skill Typer sub-app and skill add command, including --skills parsing for named/fully-qualified selection.
README.md Documents ucode skill add usage and adds it to the command summary table.
Review details
  • Files reviewed: 5/5 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.

@artjen
artjen requested a review from xsh310 September 2, 2026 21:24
Comment thread src/ucode/cli.py Outdated

@xsh310 xsh310 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Looks great!

Copilot AI review requested due to automatic review settings September 2, 2026 23:49

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.

🟡 Changes recommended

_union_locations does not normalize duplicates already present in the existing base scope, which can preserve repeated locations and propagate them into persisted state/URL generation.

Once you've addressed the issues Copilot identified, you can request another Copilot review.

Review details
  • Files reviewed: 5/5 changed files
  • Comments generated: 1
  • Review effort level: Lite

Comment thread src/ucode/mcp.py
Add the ucode skill add command for additive MCP schema registration and skill downloads, including named and fully-qualified skill selection.
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.

3 participants