python-naming

Enforce Python naming conventions for variables, functions, classes, constants, files, and directories.

4|1|Updated Dec 13, 2025
One-click install
npx skills add https://github.com/jr2804/mcp-config-converter --skill python-naming
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: python-naming
Source: https://github.com/jr2804/mcp-config-converter/tree/main/.claude/skills/development/python_naming
Command: npx skills add https://github.com/jr2804/mcp-config-converter --skill python-naming

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Ensures consistent and readable Python code by providing clear naming conventions for variables, functions, classes, constants, files, and directories.

Core Features & Use Cases

  • Variable & Function Naming: Enforces snake_case for clarity.
  • Class Naming: Mandates PascalCase for distinct class identification.
  • Constant Naming: Utilizes UPPER_SNAKE_CASE for immutable values.
  • File & Directory Naming: Provides suffixes like _file and _dir for unambiguous path variables.
  • Use Case: Maintain a high standard of code quality and reduce cognitive load across your Python projects by adhering to these established naming best practices.

Quick Start

Use the python-naming skill to get guidance on naming a new Python variable.

Frequently Asked Questions about python-naming

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

FAQPage Schema
What naming convention should I use for Python variables and functions?

Python variables and functions should use snake_case to ensure clarity and consistency. This convention formats identifiers with lowercase letters and underscores separating words, reducing cognitive load when reading and maintaining your codebase.

How do I name constants in Python to distinguish them from variables?

Python constants should use UPPER_SNAKE_CASE to distinguish them from variables. This convention utilizes all uppercase letters with underscores, providing a clear visual cue for immutable values throughout your codebase.

What is the correct way to name classes in Python?

Python classes should use PascalCase to provide distinct class identification. This convention capitalizes the first letter of every word without underscores, ensuring classes stand out from variables and functions in your codebase.

How do I name file and directory path variables in Python?

File and directory path variables in Python should use suffixes like `_file` and `_dir` for unambiguous identification. This practice ensures paths are easily recognizable and clearly distinguishes between files and directories in your codebase.

How do I avoid magic values when standardizing Python code?

To avoid magic values in Python code, define them as constants using UPPER_SNAKE_CASE. This establishes clear, named references for immutable values instead of hardcoding numbers or strings directly within your functions and variables.