code-style

Enforce Python code style with type annotations and Decimal for financial values.

Updated Nov 7, 2025
One-click install
npx skills add https://github.com/MMorit00/fund-portfolio-bot --skill code-style-mmorit00
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: code-style
Source: https://github.com/MMorit00/fund-portfolio-bot/tree/main/.claude/skills/code-style
Command: npx skills add https://github.com/MMorit00/fund-portfolio-bot --skill code-style-mmorit00

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This skill enforces essential coding conventions for the fund-portfolio-bot project, focusing on readability, correctness, and maintainability.

Core Features & Use Cases

  • Enforces type hints on function parameters and returns, using modern syntax such as list[str], dict[str, Decimal], and X | None.
  • Mandates Decimal for financial values and prohibits using float for financial calculations.
  • Encourages clear docstrings, concise inline comments, and a well-structured module and class layout to improve reviewability.
  • Use when creating new Python modules (especially under src/), editing existing functions or classes, performing refactors, or reviewing code for adherence to project standards.
  • Provides guidance on CLI-style comments with ordered steps such as 1., 2., and 3 for clarity.

Quick Start

Start applying the Python code style guidelines to new and existing code immediately.

Frequently Asked Questions about code-style

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

FAQPage Schema
How do I enforce Python type annotations and modern typing syntax in my project?

To enforce Python type annotations, this skill requires type hints on all function parameters and returns using modern syntax like list[str], dict[str, Decimal], and X | None for consistent project code style.

Why should I use Decimal instead of float for financial calculations in Python?

You should use Decimal for financial calculations because this skill mandates it for financial values and prohibits float arithmetic to ensure calculation correctness and prevent precision loss.

What's the best way to standardize Python docstrings and inline comments during code reviews?

The best way to standardize Python docstrings during reviews is using this skill to enforce clear docstrings, concise inline comments, and CLI-style comments with ordered steps like 1., 2., and 3 for clarity.

Does this Python code style guidance apply when creating new modules and refactoring existing classes?

Yes, this Python code style guidance applies directly when creating new modules under src/, editing existing functions or classes, performing refactors, or reviewing code for project standard adherence.