uv-script

Convert Python scripts to uv-runnable format with PEP 723 inline metadata.

3|Updated Jan 10, 2026
One-click install
npx skills add https://github.com/MaxWolf-01/agents --skill uv-script-maxwolf-01
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: uv-script
Source: https://github.com/MaxWolf-01/agents/tree/main/mx/skills/uv-script
Command: npx skills add https://github.com/MaxWolf-01/agents --skill uv-script-maxwolf-01

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Python scripts often fail to run on other machines because their dependencies are not declared anywhere, forcing users to manually track down and install missing packages. This Skill adds PEP 723 inline metadata to a script so it runs directly with uv run without a separate requirements file or virtual environment setup. ## Core Features & Use Cases - Dependency Detection: Reads the script's import statements and identifies the packages it needs. - PEP 723 Metadata Injection: Adds a standards-compliant inline metadata block with requires-python and a dependencies list. - Code Preservation: Keeps the existing code and structure untouched while only adding the metadata header. - Use Case: You receive a standalone data-processing script from a colleague. Use this Skill to add inline metadata, then run it immediately with uv run script.py and let uv resolve and install the dependencies automatically. ## Quick Start Convert my Python script to run with uv by adding PEP 723 inline metadata with its detected dependencies.

Frequently Asked Questions about uv-script

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I run a Python script with uv without a requirements file?

Add a PEP 723 inline metadata block at the top of the script listing its dependencies, then execute it with `uv run script.py`. uv reads the metadata, creates an isolated environment, and installs the declared packages automatically.

What is PEP 723 inline script metadata?

PEP 723 defines a standard comment block format for embedding dependency and Python version requirements directly inside a single Python file. Tools like uv parse this block to resolve and install dependencies before running the script.

Does uv run automatically install script dependencies?

Yes, when a script contains a PEP 723 metadata block with a dependencies list, `uv run` resolves and installs those packages into an ephemeral environment before execution. No manual pip install step is needed.

How are dependencies detected from Python imports?

The script's import statements are read and mapped to their corresponding package names. Standard library modules are excluded, and third-party imports are listed in the dependencies array of the metadata block.

Will converting a script change my existing code?

No, the conversion only adds the PEP 723 metadata comment block at the top of the file. The existing code and structure are preserved unchanged.