Borrowing it
Nothing to install: this file belongs to DDS-Solutions/AI-TadPole-OS. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/DDS-Solutions/AI-TadPole-OS/main/.agent/skills/python-patterns/SKILL.mdgit clone --depth 1 https://github.com/DDS-Solutions/AI-TadPole-OSWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/dds-solutions/ai-tadpole-os/python-patterns)<a href="https://agentmods.dev/skills/dds-solutions/ai-tadpole-os/python-patterns"><img src="https://agentmods.dev/badge/skills/dds-solutions/ai-tadpole-os/python-patterns/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/dds-solutions/ai-tadpole-os/python-patterns"><img src="https://agentmods.dev/badge/skills/dds-solutions/ai-tadpole-os/python-patterns.svg" alt="Reviewed on agentmods" width="80" height="20"></a>- NVIDIA SkillSpector pass
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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00024 | $0.01160 |
| Opus 5.5 | $0.00010 | $0.00464 |
| Sonnet 5.5 | $0.00005 | $0.00232 |
| Haiku 4.5 | $0.00002 | $0.00116 |
Grade A, and why
python-patterns 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 3d 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.
- **Golden Rule**: Never execute blocking sync calls (`time.sleep`, `requests.get`) inside an `async def` function. Use `asyncio.sleep` or `httpx.AsyncClient`. How it starts
The opening of the file, as written. The whole thing — 91 lines — stays where its author put it; the contents beside it link to each section on GitHub.
[!IMPORTANT] AI Context & Knowledge Heritage
- Subsystem: Agent Skills Registry / python-patterns
- Architecture:
@docs ARCHITECTURE:Documentation- Failure Path: Blocking calls inside async loops, bare exception masking, or mutable default arguments.
- Observability: Traceability via
execution/parity_guard.py([SKILL])
Python Development Patterns & Architecture
Philosophy: Explicit is better than implicit. Asynchronous for I/O; synchronous threadpools for compute. Type hints at every public boundary.
Workflow Bindings: Integrated into/create,/refactor, and/audit.
🎯 Progressive Disclosure & L3 Reference Index
Read the core Sovereign rules below; consult deep L3 Reference Guides on demand:
| L3 Reference Guide | Purpose | Trigger / When to Load |
|---|---|---|
references/framework_cheatsheets.md |
FastAPI vs Django vs Flask, async drivers, test fixtures | Framework selection & database setup |
scripts/python_linter.py |
Automated static auditor for bare except:, mutable defaults, and async blocking |
Auditing Python scripts and execution tools |
🧭 1. Framework & Concurrency Selection
What are you building?
├── High-concurrency API / ML Serving ➔ FastAPI (Async, Pydantic v2, ASGI)
├── Full-Stack / Admin Backoffice ➔ Django 5.0+ (Batteries-included, ORM)
├── Lightweight CLI / Script / Worker ➔ Python Standard Library / Click / Typer
└── Background Distributed Tasks ➔ Celery / ARQ (Redis backend)
Async vs Sync Rules
- Use
async deffor: I/O-bound operations (Database queries, REST API requests, WebSockets, File streams). - Use
def(Sync) for: CPU-bound computation, image processing, or blocking legacy libraries. - Golden Rule: Never execute blocking sync calls (
time.sleep,requests.get) inside anasync deffunction. Useasyncio.sleeporhttpx.AsyncClient.
What ships with it
2 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
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.
- 3d ago Changed · +9 lines · -6 tokens per session 63e22628022c
- 1mo ago First seen · 82 lines · 30 tokens per session scan A 7d73e74704dc
python-patterns is a skill published in the GitHub repository DDS-Solutions/AI-TadPole-OS (8 stars, last pushed today), licensed MIT. It adds 24 tokens to every session and 1,160 once invoked, about $0.0001 per session on Opus 5.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-09-03.
Other skills, from other repositories
client-setup
Create a vanilla tRPC client with createTRPCClient (), configure link chain with httpBatchLink/httpLink, dynamic headers for auth, transformer on links (not client constructor). Infer types with inferRouterInputs and inferRouterOutputs. AbortController signal support. TRPCClientError typing.
adapter-express
Mount tRPC as Express middleware with createExpressMiddleware() from @trpc/server/adapters/express. Access Express req/res in createContext via CreateExpressContextOptions. Mount at a path prefix like app.use('/trpc', ...). Avoid global express.json() conflicting with tRPC body parsing for FormData.
trpc-router
Entry point for all tRPC skills. Decision tree routing by task: initTRPC.create(), t.router(), t.procedure, createTRPCClient, adapters, subscriptions, React Query, Next.js, links, middleware, validators, error handling, caching, FormData.
langgraph-docs
Fetches and references LangGraph Python documentation to build stateful agents, create multi-agent workflows, and implement human-in-the-loop patterns. Use when the user asks about LangGraph, graph agents, state machines, agent orchestration, LangGraph API, or needs LangGraph implementation guidance.
stripe-projects
Use after E2B sandbox/API access has been provisioned through Stripe Projects and the user needs to use the resulting E2B API key with the E2B CLI, JavaScript SDK, Python SDK, or Code Interpreter SDK.
dd-code-generation
Use pup CLI for immediate Datadog operations or generate code for integration into applications.