python-uv CLAUDE.md

Development instructions for a Python project template and utility package managed with uv, a Python package and environment manager, and Ruff, a code checker and formatter.

In plain words
What is it for?
Installing dependencies, running tests with coverage, formatting Python and SQL, and checking code quality.
Why use it?
They collect the project’s setup, dependency, testing, formatting, and code-quality commands in one place.

Instructions file

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add instructions/a5chin/python-uv/claude-md
Clone the repo
git clone --depth 1 https://github.com/a5chin/python-uv
Per session 2,165 This file is loaded in full into every session.
When invoked 2,165 The same file — it is already loaded in full.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.02165 $0.02165
Opus 5 $0.01082 $0.01082
Sonnet 5 $0.00433 $0.00433
Haiku 4.5 $0.00216 $0.00216

Measured 2d ago against content hash 82e38420914c, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

python-uv CLAUDE.md scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

CLAUDE.md · 294 lines

How it starts

The opening of the file, as written. The whole thing — 294 lines — stays where its author put it; the contents beside it link to each section on GitHub.

CLAUDE.md

This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.

Project Overview

This is a Python development environment template using uv (fast Python package manager) and Ruff (linter/formatter). The repository serves dual purposes:

  1. A template for starting new Python projects
  2. A reusable tools/ package with production-ready utilities (Logger, Config, Timer)

Development Commands

Package Management

# Install dependencies
uv sync

# Add new dependency
uv add <package>

# Add dev dependency
uv add --dev <package>

# Remove dependency
uv remove <package>

Testing

# Run all tests with coverage (75% minimum required)
uv run nox -s test

# Run specific test file
uv run pytest tests/tools/test__logger.py

# Run with JUnit XML output for CI
uv run nox -s test -- --cov_report xml --junitxml junit.xml

# Run pytest directly (bypasses nox)
uv run pytest

Linting & Formatting

# Format code with Ruff
uv run nox -s fmt -- --ruff

# Format SQL files with sqruff
uv run nox -s fmt -- --sqruff

# Format both Python and SQL
uv run nox -s fmt -- --ruff --sqruff

# Lint with all tools (Ruff, sqruff, ty)
uv run nox -s lint -- --ruff --sqruff --ty

# Lint with Ruff only
uv run nox -s lint -- --ruff

# Lint SQL files only
uv run nox -s lint -- --sqruff

# Lint with ty only
uv run nox -s lint -- --ty

# Run Ruff directly
uv run ruff check . --fix
uv run ruff format .

# Run sqruff directly
uv run sqruff lint
uv run sqruff fix

# Run ty directly
uv run ty check

Pre-commit Hooks

# Install hooks
uv run pre-commit install

# Run all hooks manually
uv run pre-commit run --all-files

# Run specific hook
uv run pre-commit run ruff-format

Documentation

# Serve docs locally at http://127.0.0.1:8000
uv run mkdocs serve

# Build documentation
uv run mkdocs build

# Deploy to GitHub Pages
uv run mkdocs gh-deploy

Architecture

Core Modules

Read the full file on GitHub · 294 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 294 lines · 2,165 tokens per session scan A 82e38420914c

Subscribe to this mod's changes

python-uv CLAUDE.md is an instructions file published in the GitHub repository a5chin/python-uv (374 stars, last pushed 6d ago), licensed MIT. It adds 2,165 tokens to every session, about $0.0108 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.