python-style

Enforce Python type hints, Google-style docstrings, and PEP 8/Black formatting.

1|Updated Jan 15, 2026
One-click install
npx skills add https://github.com/janjaszczak/cursor --skill python-style-janjaszczak
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: python-style
Source: https://github.com/janjaszczak/cursor/tree/main/skills/python-style
Command: npx skills add https://github.com/janjaszczak/cursor --skill python-style-janjaszczak

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Writing or editing Python code often suffers from inconsistent typing, undocumented interfaces, and formatting drift. This skill enforces a quality gate that promotes consistent type hints, concise Google-style docstrings, and adherence to PEP 8/Black, with unit tests when applicable.

Core Features & Use Cases

  • Enforce consistent type hints and return types across codebases.
  • Require Google-style docstrings for public modules, classes, and functions.
  • Enforce PEP 8/Black formatting and ensure tests accompany changes where appropriate.
  • Use case: when working on Python APIs, refactors, or bug fixes to improve maintainability and correctness.

Quick Start

Activate this skill whenever you start editing Python files to enforce typing, docstrings, formatting, and tests.

Frequently Asked Questions about python-style

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

FAQPage Schema
How do I enforce Python type hints and docstrings across my codebase?

To enforce Python type hints and docstrings, you need a quality gate that checks for consistent return types and Google-style docstrings on public modules. This ensures maintainability and correctness during API edits or refactoring.

What's the best way to maintain PEP 8 and Black formatting when editing Python modules?

Maintaining PEP 8 and Black formatting requires applying a strict formatting standard whenever you edit Python modules. This prevents formatting drift and keeps your codebase consistently styled across all refactors and bug fixes.

Does this skill require unit tests when refactoring Python code?

Yes, enforcing unit tests when refactoring Python code is a core feature. It ensures that your bug fixes and API changes are accompanied by appropriate tests to verify correctness and prevent regressions.

When do I need Google-style docstrings for Python functions?

You need Google-style docstrings for Python functions whenever you are working on public modules, classes, or APIs. This documentation standard clarifies interfaces and improves overall code maintainability.

How do I add type hints to an existing Python API without breaking it?

Adding type hints to an existing Python API involves applying consistent type annotations and return types during your refactor. This process ensures the API remains correct and maintainable while clarifying expected data structures.