Agent skill

Python Guidelines

by fcakyon in fcakyon/claude-codex-settings

This skill should be used when writing, reviewing, or refactoring Python code.

Apache-2.0Auto-check passedDevelopment

Install Python Guidelines

skills CLI
$ npx skills add fcakyon/claude-codex-settings --skill python-guidelines -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install fcakyon/claude-codex-settings python-guidelines --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/fcakyon/claude-codex-settings.git skills-src && mkdir -p .claude/skills && cp -r skills-src/plugins/python-skills/skills/python-guidelines .claude/skills/python-guidelines && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
python-guidelines
GitHub stars
1.2k
Token cost
~1.2k tokens
SKILL.md length
543 words
Files
5 (incl. references)
Skills in repo
43
Repo updated
First seen
Licence
Apache-2.0

At a glance

This skill should be used when writing, reviewing, or refactoring Python code.

  • Tasks that involve Technical documentation
  • SKILL.md covers Code Philosophy, Simplicity Over Abstraction, Environment and Testing Discipline, plus 2 more sections
  • Calls python and uv
  • Tasks that involve Refactoring

What it does

Python Guidelines is an agent skill from fcakyon/claude-codex-settings. This skill should be used when writing, reviewing, or refactoring Python code. Covers code integration, idiomatic patterns, docstring formatting, anti-abstraction rules, and software engineering basics.

Its SKILL.md is about 1.2k tokens, which your agent loads only when the skill is triggered. The skill folder holds 5 other files, including reference files (for example `references/effective-python-tips.md`, `references/google-style-guide.md` and `references/idiomatic-patterns.md`).

It sits in Development, covering Technical documentation and Refactoring. It works with Python. The repository describes itself as: Battle-tested Claude Code, OpenAI Codex, Cursor configs, plugins, hooks and agents with Kimi, MiniMax and GLM API support. The licence is Apache-2.0.

When your agent uses it

  • Tasks that involve Technical documentation
  • Tasks that involve Refactoring

Example prompts

  • “/python-guidelines”

Requirements

  • Python 3

What it can do on your machine

Read from SKILL.md and the folder at commit a035b4e. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • python
    • uv

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md. Its commands use uv, which can reach the network depending on how they are called.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Python Guidelines loads about 1.2k tokens when it runs, and up to ~4.5k if it reads all its reference files. Until then it costs about 55 tokens; SKILL.md has 543 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~55
When it runs · the whole SKILL.md, loaded when a task matches
~1.2k
With references · SKILL.md plus every file in references/, read only if the agent opens them
~4.5k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from fcakyon/claude-codex-settings at commit a035b4e, republished under its Apache-2.0 licence (© fcakyon). 543 words, ~1,226 tokens.

Download SKILL.mdSave it as .claude/skills/python-guidelines/SKILL.md (or your agent's skills folder). This skill also uses 4 other files; get the full folder from GitHub.
name
python-guidelines
description
This skill should be used when writing, reviewing, or refactoring Python code. Covers code integration, idiomatic patterns, docstring formatting, anti-abstraction rules, and software engineering basics.

Python Guidelines

Integrate into existing code. Don't append to it.

Simple is better than complex. Flat is better than nested. Errors should never pass silently. Unless explicitly silenced. If the implementation is hard to explain, it's a bad idea.

-- The Zen of Python (PEP 20)

Code Philosophy

  • Match existing naming, importing, and signature patterns. Use existing utilities and data structures.
  • Functions have a single purpose. Don't hardcode behavior that makes them less general.
  • No trivial wrappers for 2 lines or less. Inline it.
  • Inline single-use variables at the usage site.
  • No try/except unless critical. Let errors surface.
  • No duplicate code.
  • Functions handle their own input validation. No if-else checks in main.
  • Use pathlib, not os.path.
  • Consider API and time costs for MongoDB/Gemini/OpenAI/Claude/Voyage.

Don't do this:

python
# Generate comment report only if requested
if include_comments:
    comment_report = generate_comments_report(start_date, end_date, team, verbose)
else:
    comment_report = ""
    print("   Skipping comment analysis (disabled)")

Do this:

python
comment_report = generate_comments_report(start_date, end_date, team, verbose) if include_comments else ""

Ask yourself: "Am I adding code, or integrating into what exists?"

Simplicity Over Abstraction

YAGNI: You Aren't Gonna Need It.

Don't build for hypothetical future requirements. Add complexity only when the current task demands it.

Avoid:

  • Abstract base classes for a single implementation
  • Configuration options nobody asked for
  • Error handling for impossible scenarios
  • Wrapper classes around a single function
  • Dependency injection when direct calls work
  • Generic type parameters for one concrete type

Three similar lines of code is better than a premature abstraction. Refactor when the third real use case appears, not before.

But simplicity does not mean chaos. Always maintain:

  • Clear function names that describe what they do
  • Logical grouping of related code into modules
  • Consistent naming conventions across the project
  • Clean separation between I/O and logic
  • Explicit parameters over global state or side effects

Ask yourself: "Is this abstraction solving a problem I have right now, or one I'm imagining?"

Environment

  • Package manager: uv (NOT pip)
  • Virtual env: source .venv/bin/activate or uv run python -c "..."
  • 3rd party packages: Find source with python -c "import pkg; print(pkg.__file__)", then Read.
Show full SKILL.md (236 more words)Show less

Testing Discipline

Never assume anything. Run python -c "..." to verify hypotheses about code behavior, package functions, or data structures before suggesting a plan or exiting plan mode.

Ask yourself: "Did I verify this with python -c before building on it?"

Google-Style Docstrings

  • Summary: Imperative mood ("Calculate", not "Calculates")
  • Args: All parameters with types and descriptions. No default values. Indent 4 spaces.
  • Types: int | str unions, uppercase shapes (N, M), lowercase builtins list/dict/tuple, capitalize Any/Path
  • Optional: name (type, optional): Description
  • Returns: Always (type) in parentheses. Never tuple types. Separate named values for multiple returns.
  • Sections: Examples (>>>), Notes, References (plaintext only). Section titles at 0 indent.
  • Omit: "Returns:" if nothing returned, "Args:" if no args, "Raises:" unless critical
  • Classes: Attributes section only, omit Methods/Args. Don't convert single-line to multiline.
  • __init__: Args only. No Examples/Notes/Methods/References.
  • Tests: Single-line docstrings only.
  • Erase default values from existing arg descriptions. Optionally include minimal Examples.

Ask yourself: "Would a new developer understand this function from the docstring alone?"

Reference Files

Read the matching file before you write the code, not after:

© fcakyon, Apache-2.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 4 other files (references) in plugins/python-skills/skills/python-guidelines of fcakyon/claude-codex-settings.

  • SKILL.md
  • references/effective-python-tips.md
  • references/google-style-guide.md
  • references/idiomatic-patterns.md
  • references/zen-of-python.md

Open the folder on GitHubat commit a035b4e

Compare with similar skills

Python Guidelines next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Python Guidelines compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Python Guidelines this skillfcakyon/claude-codex-settings1.2k—~1.2kAutomated safety check: PassApache-2.0
Dignified Python Standardsdocling-project/docling68k—~1.5kAutomated safety check: PassApache-2.0
Adk Sample Creatorgoogle/adk-python22k—~1.3kAutomated safety check: PassApache-2.0
Crafting Effective Readmescumbucadev/cinemaempoa1465 repos~669Automated safety check: PassGPL-3.0
Readable Pycrazyguitar/pysheeet8.2k—~2.4kAutomated safety check: PassMIT
Nexus MapperHaaaiawd/Nexus-skills1661 repos~2.5kAutomated safety check: NotesNone

Similar skills

  • Dignified Python Standards

    docling-project/docling

    Applies opinionated production Python conventions chosen by the project's Python version: modern type syntax, pathlib, explicit checks and interface guidance.

    68k GitHub stars~1.5k tokensUpdated yesterday
    DevelopmentAuto-check passed
  • Adk Sample Creator

    google/adk-python

    Official

    Creates a new sample agent in the ADK Python repository — the sample directory, its agent.py, and its README.md — following the conventions the existing samples already use.

    22k GitHub stars~1.3k tokensUpdated today
    DevelopmentAuto-check passed
  • Crafting Effective Readmes

    cumbucadev/cinemaempoa

    A skill your agent uses when writing or improving README files.

    146 GitHub starsUsed in 5 repos~669 tokens
    DevelopmentAuto-check passed
  • Readable Py

    crazyguitar/pysheeet

    Readable Python code rules inspired by The Art of Readable Code.

    8.2k GitHub stars~2.4k tokensUpdated today
    DevelopmentAuto-check passed
  • Nexus Mapper

    Haaaiawd/Nexus-skills

    Generate a persistent .nexus-map/ knowledge base that lets any AI session instantly understand a codebase's architecture, systems, dependencies, and change hotspots.

    166 GitHub starsUsed in 1 repo~2.5k tokens
    DevelopmentAuto-check: notes
  • Acquire Codebase Knowledge

    github/awesome-copilot

    Official

    Maps an unfamiliar codebase into seven evidence-backed documents in docs/codebase/, using a scan script and templates, for onboarding or architecture write-ups.

    40k GitHub starsUsed in 1 repo~2.3k tokens
    DevelopmentAuto-check passed

More from fcakyon/claude-codex-settings

All 43 skills in this repo
  • Slides

    fcakyon/claude-codex-settings

    Create and edit presentation slide decks (.pptx) with PptxGenJS, bundled layout helpers, and render/validation utilities.

    1.2k GitHub starsUsed in 1 repo~1.1k tokens
    Auto-check passed
  • Openobserve API

    fcakyon/claude-codex-settings

    This skill should be used when user asks to "query OpenObserve", "create OpenObserve dashboard", "edit OpenObserve panel", "fetch OpenObserve logs", "run OpenObserve search", "list OpenObserve…

    1.2k GitHub starsUsed in 1 repo~4.1k tokens
    Auto-check passed
  • Supabase JS

    fcakyon/claude-codex-settings

    This skill should be used when user asks to "use supabase-js", "query Supabase database", "supabase auth", "supabase storage", "supabase realtime", "supabase edge functions", or works with the…

    1.2k GitHub starsUsed in 1 repo~1.6k tokens
    Auto-check passed
  • Yolo Training

    fcakyon/claude-codex-settings

    This skill should be used when user asks to "improve my mAP", "why is my model overfitting", "my training is diverging", "read my results.csv", "interpret my training curves", "my AP50 is good but…

    1.2k GitHub starsUsed in 1 repo~1.4k tokens
    Auto-check passed
  • Dokploy Deploy

    fcakyon/claude-codex-settings

    This skill should be used when user asks to "deploy with Dokploy", "use Dokploy Cloud", "manage self-hosted Dokploy", "deploy Docker Compose on Dokploy", "manage Dokploy databases", "configure…

    1.2k GitHub stars~891 tokensUpdated yesterday
    Auto-check passed
  • Openship Config

    fcakyon/claude-codex-settings

    This skill should be used when the user asks to "create openship.json", "configure an OpenShip deployment", "make a repo deployable on OpenShip", or fix "openship config validate" errors.

    1.2k GitHub stars~803 tokensUpdated yesterday
    Auto-check passed

Works with

Categories

Questions about Python Guidelines

What does Python Guidelines do?

This skill should be used when writing, reviewing, or refactoring Python code. Python Guidelines is an agent skill from fcakyon/claude-codex-settings. This skill should be used when writing, reviewing, or refactoring Python code.

When should I use Python Guidelines?

Python Guidelines fits situations like: tasks that involve Technical documentation; tasks that involve Refactoring.

How do I install Python Guidelines in Claude Code?

Run `npx skills add fcakyon/claude-codex-settings --skill python-guidelines -a claude-code`. Or copy the skill folder (plugins/python-skills/skills/python-guidelines in fcakyon/claude-codex-settings) into .claude/skills/python-guidelines in your project. Claude Code loads it when a task matches its description.

How do I install Python Guidelines in Codex?

Run `npx skills add fcakyon/claude-codex-settings --skill python-guidelines -a codex`. Or copy the skill folder (plugins/python-skills/skills/python-guidelines in fcakyon/claude-codex-settings) into .agents/skills/python-guidelines in your project. Codex loads it when a task matches its description.

Can I use Python Guidelines in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add fcakyon/claude-codex-settings --skill python-guidelines -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/python-guidelines, .gemini/skills/python-guidelines, .github/skills/python-guidelines and .opencode/skills/python-guidelines in your project.

What does Python Guidelines need to run?

Going by SKILL.md and its folder, Python Guidelines needs the command-line tools its instructions call (python and uv). Our summary lists: Python 3.

Does Python Guidelines access the network?

SKILL.md contains no URLs. Its commands use uv, which can reach the network depending on how they are called. This is read from the text; nothing was executed.

Is Python Guidelines safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Python Guidelines use?

Python Guidelines is published under the Apache-2.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Python Guidelines use?

About 1.2k tokens (SKILL.md is roughly 4.9k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 3.3k tokens, read only when the agent opens those files.

What are the alternatives to Python Guidelines?

Skills that share tags, products or a category with Python Guidelines: Dignified Python Standards (docling-project/docling, 68k stars), Adk Sample Creator (google/adk-python, 22k stars), Crafting Effective Readmes (cumbucadev/cinemaempoa, 146 stars) and Readable Py (crazyguitar/pysheeet, 8.2k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Python Guidelines?

fcakyon (a GitHub user) maintains it in fcakyon/claude-codex-settings, which has 1,163 GitHub stars. The repository holds 43 skills in this directory. The repository was last updated on October 6, 2026.

Source: fcakyon/claude-codex-settings on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.