agentleFS
atsushi-greenatsushi-green/ds-ai-coding-skills/.claude/skills/python-project-ops/SKILL.md

python-project-ops

Skill86 starsChanged 49 days agoMITView on GitHub

Use this when managing Python dependencies with uv, running tests with pytest, linting with ruff, formatting code, type checking with mypy, or executing notebooks.

The file

We split this skill into the rules it gives an agent

10 rules. About 0 are common, 2 are distinctive, and 8 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈2

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 8

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Use this skill when changing dependencies, running tests, linting, formatting, type checking, or executing notebooks.

    line 8
  2. Very specific:

    Use uv for all dependency installation, synchronization, addition, removal, and updates.

    line 12
  3. Very specific:

    Never: use pip, pip3, python -m pip, poetry, conda, pipenv, or easy_install.

    line 13
  4. Very specific:

    Use uv add <package> when adding dependencies.

    line 15
  5. Very specific:

    Use uv add --group dev <package> for dev-only dependencies.

    line 16
  6. Very specific:

    After modifying pyproject.toml, run uv sync.

    line 37
  7. Very specific:

    After adding code, run uv run ruff check .

    line 38
  8. Very specific:

    Before committing, run uv run pytest and uv run mypy src.

    line 39
  9. Very specific:

    Place tests under tests/; keep them fast by minimizing external dependencies.

    line 44
  10. Distinctive:

    Verify notebooks re-run from a clean kernel — see notebook-workflow skill.

    line 47

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Skill: Python Project Operations

Use this skill when changing dependencies, running tests, linting, formatting, type checking, or executing notebooks.

Package Manager: uv Only

  • Use uv for all dependency installation, synchronization, addition, removal, and updates.
  • Never use pip, pip3, python -m pip, poetry, conda, pipenv, or easy_install.
  • Never manually create or edit requirements.txt.
  • Use uv add <package> when adding dependencies.
  • Use uv add --group dev <package> for dev-only dependencies.
  • Review diffs in pyproject.toml and uv.lock after dependency changes.

Python Version

  • Python 3.11.

Common Commands

uv sync                    # Install/synchronize dependencies
uv run pytest              # Run tests
uv run ruff check .        # Lint
uv run ruff format .       # Format
uv run mypy src            # Type check
uv run papermill notebooks/input.ipynb notebooks/output.ipynb  # Execute notebook
bash scripts/run_quality_checks.sh  # Run all quality checks

Workflow

  1. After modifying pyproject.toml, run uv sync.
  2. After adding code, run uv run ruff check . and uv run ruff format ..
  3. Before committing, run uv run pytest and uv run mypy src.
  4. For notebook execution in CI or automation, prefer papermill.

Tests and Tool Configuration

  • Place tests under tests/; keep them fast by minimizing external dependencies.
  • ruff settings live in the [tool.ruff] section of pyproject.toml.
  • mypy settings live in the [tool.mypy] section of pyproject.toml.
  • Verify notebooks re-run from a clean kernel — see notebook-workflow skill.

Validation Scripts

These run in GitHub Actions CI, and can be run locally before committing.

uv run python scripts/check_no_raw_data_commit.py    # rawデータのコミットを検知
uv run python scripts/check_no_sensitive_patterns.py # 秘密情報のパターンを検知
uv run python scripts/validate_agent_docs.py         # エージェント文書の必須ファイル確認
uv run python scripts/sync_agent_docs.py --check     # CLAUDE.md / AGENTS.md のドリフト検出
bash scripts/run_quality_checks.sh                   # 上記を含む一括実行

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.