python-docs

A reference for Python 3.13, a general-purpose programming language. It covers the language itself, its standard library, packages, virtual environments, type hints, asynchronous code, files, testing, and more.

In plain words
What is it for?
Use it when writing or reviewing Python code, choosing built-in data structures, handling errors, managing packages, adding type hints, working with files, or building asynchronous programs.
Why use it?
It gives you current explanations and examples for Python syntax and common development tasks in one place.

Skill for Claude CodeCodex

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 skills/pledgeandgrow/pledge-skills/python
Any agent
npx skills add pledgeandgrow/pledge-skills --skill python
Clone the repo
git clone --depth 1 https://github.com/pledgeandgrow/pledge-skills

Made for: Claude Code, Codex.

Per session 251 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,360 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. 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.00251 $0.02360
Opus 5 $0.00125 $0.01180
Sonnet 5 $0.00050 $0.00472
Haiku 4.5 $0.00025 $0.00236

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

Security

Grade A, and why

python-docs scanned grade A with 1 finding 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.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

| threading, multiprocessing, concurrent.futures, queue, socket, ssl, http, socketserver, sqlite3, hashlib/hmac, base64, struct, decimal, fractions, statistics, time, inspect, traceback, gc, weakref, types, operator, zip
skills/python/SKILL.md · 263 lines

How it starts

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

Python Expert (3.13)

Official Documentation: https://docs.python.org/3/

Quick Reference

Topic File
Variables, built-in types, strings, bytes/bytearray/memoryview, control flow, f-strings, pattern matching, keywords, constants, special attributes, dict views, set methods basics-syntax.md
Functions, lambda, *args/**kwargs, decorators, generators, closures, scope resolution (LEGB) functions-lambdas.md
Classes, inheritance, dataclasses, enums, metaclasses, properties, slots, dunder methods classes-objects.md
List, dict, set, tuple, comprehensions, collections module, sequences collections.md
Imports, packages, pip, venv, pyproject.toml, packaging, distribution modules-packages.md
try/except, custom exceptions, exception groups, context managers, warnings exceptions.md
Type hints, generics, protocols, TypedDict, mypy, pyright, narrowing typing.md
async/await, asyncio, tasks, streams, synchronization, async generators async-asyncio.md
os, sys, math, itertools, functools, datetime, json, re, argparse, random stdlib-core.md
File I/O, pathlib, io, csv, pickle, logging, shutil, tempfile stdlib-io.md
threading, multiprocessing, concurrent.futures, queue, socket, ssl, http, socketserver, sqlite3, hashlib/hmac, base64, struct, decimal, fractions, statistics, time, inspect, traceback, gc, weakref, types, operator, zipfile/tarfile, configparser, tomllib, ipaddress, urllib, ctypes, email/smtplib/imaplib/poplib, html.parser/entities, xml.etree/dom/sax/expat, string, textwrap, difflib, unicodedata, codecs, numbers, pdb, cProfile, timeit, tracemalloc, faulthandler, atexit, signal, mmap, sched, tkinter, turtle, curses, gettext/locale, copyreg, pkgutil, importlib, contextvars, graphlib, zoneinfo, calendar, pprint, cmath, logging.config/handlers, select/selectors, stat, reprlib, filecmp, fileinput, cmd, readline, rlcompleter, stringprep, netrc, plistlib, mailbox, binascii, quopri, wsgiref, ftplib, http.cookies/cookiejar, xmlrpc, wave, colorsys, bdb, trace, sys.monitoring, code/codeop, modulefinder, zipimport, optparse, _thread, shared_memory, builtins, warnings, os.path, audit events, devmode, IDLE, test, dis, py_compile, compileall, tokenize, tabnanny, symtable, keyword, ast, removed modules (imghdr, sndhdr, crypt, aifc, sunau, chunk, nntplib, telnetlib, uu, xdrlib, cgi, cgitb, distutils, formatter), descriptors, GIL stdlib-extended.md
pytest, unittest, mocking, fixtures, coverage, hypothesis, doctest testing.md
PEP 8, idioms, patterns, performance, EAFP, duck typing, naming idioms-best-practices.md
Python 3.13 features, free-threaded, JIT, REPL, error messages, 3.12/3.11 changes whats-new.md

Read the full file on GitHub · 263 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 · 263 lines · 251 tokens per session scan A b1e2eaa3c686

Subscribe to this mod's changes

python-docs is a skill published in the GitHub repository pledgeandgrow/pledge-skills (10 stars, last pushed 1mo ago), licensed MIT. It adds 251 tokens to every session and 2,360 once invoked, about $0.0013 per session on Opus 5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.