CtrlK
BlogDocsLog inGet started
Tessl Logo

fastapi-patterns

FastAPI best practices covering project structure, Pydantic v2 schemas, dependency injection, async handlers, authentication, authorization, transactional service layers, and testing with httpx and pytest. Use when building or reviewing FastAPI apps — Pydantic schemas, dependencies, async handlers, auth, or tests.

68

Quality

83%

Does it follow best practices?

Run evals on this skill

Adds up to 20 points to the overall score

View guide

SecuritybySnyk

Passed

No findings from the security scan

SKILL.md
Quality
Evals
Security

Quality

Content

78%Weight 40%Scale 1-5

Reviews the quality of instructions and guidance provided to agents. Good implementation is clear, handles edge cases, and produces reliable results.

Highly actionable, executable content with a clean section structure and lean, code-first writing. The main weakness is the monolithic single-file layout: no reference files split out the service layer, testing fixtures, or extended patterns, and the anti-patterns section duplicates earlier code.

Suggestions

Split the Service Layer, Testing (conftest.py), and Anti-Patterns sections into one-level-deep reference files (e.g., references/service-layer.md, references/testing.md) and link them from a concise overview in SKILL.md.

Remove the duplicated create_user 'Good' example in Anti-Patterns — reference the Router section's version instead and keep only the 'Bad' contrast inline.

Add brief inline validation checkpoints (e.g., 'run pytest after wiring dependencies') between major setup steps so the build sequence has explicit verify points.

DimensionReasoningScore

Conciseness

The body is code-dominant with almost no padded prose or re-explanation of concepts Claude already knows, but the Anti-Patterns section repeats the create_user "Good" example nearly verbatim from the Router section — a minor instance of trimmable content that keeps it below anchor 5 and clearly above anchor 3.

4 / 5

Actionability

Every section delivers complete, copy-paste-ready implementations (app factory, pydantic-settings config, Pydantic v2 schemas, DI with annotated aliases, router endpoints, transactional service layer, and full pytest/httpx fixtures), covering the common cases end-to-end — a direct match for anchor 5.

5 / 5

Workflow Clarity

The sections follow a clear, logical build order (structure → app factory → config → schemas → DI → routes → services → tests → anti-patterns), but there are no explicit validation checkpoints between steps beyond the final testing section, fitting anchor 4 (clear sequence, most checkpoints present, minor validation gaps) rather than anchor 5.

4 / 5

Progressive Disclosure

There are no bundle files (no references/, scripts/, or assets/), so all ~500 lines — including the full service layer, complete conftest.py fixtures, and the anti-patterns — are inlined in SKILL.md. Section headers provide good structure, but substantial content that would naturally live in one-level-deep reference files is inline with no navigation to external materials, which matches anchor 3 rather than anchor 4.

3 / 5

Total

16

/

20

Passed

Description

87%Weight 40%Scale 1-5

Based on the skill's description, can an agent find and select it at the right time? Clear, specific descriptions lead to better discovery.

A strong description: it states a comprehensive, specific capability list and pairs it with an explicit, natural "Use when" trigger clause. The only refinement would be phrasing capabilities as concrete actions and adding a few more trigger synonyms.

DimensionReasoningScore

Specificity

The description enumerates many concrete capability areas ("project structure, Pydantic v2 schemas, dependency injection, async handlers, authentication, authorization, transactional service layers, and testing with httpx and pytest"), but these are topics rather than concrete action verbs, placing it between anchors 4 and 5 — comprehensive coverage without the crisp action phrasing of anchor 5.

4 / 5

Completeness

It explicitly answers both what ("FastAPI best practices covering project structure, Pydantic v2 schemas, ... testing with httpx and pytest") and when ("Use when building or reviewing FastAPI apps — Pydantic schemas, dependencies, async handlers, auth, or tests") with concrete trigger phrases, exactly matching the anchor-5 example pattern.

5 / 5

Trigger Term Quality

"Use when building or reviewing FastAPI apps — Pydantic schemas, dependencies, async handlers, auth, or tests" supplies natural terms users would actually say, but misses common variations such as "endpoints", "REST API", or "pytest" alone, matching anchor 4 (good coverage, a few natural terms missing) rather than anchor 5.

4 / 5

Distinctiveness Conflict Risk

It occupies a clear niche (FastAPI) with distinct, well-scoped triggers; overlap risk with generic Python/web skills is minimal, matching anchor 5. It is not vague or broad enough to fit anchor 4.

5 / 5

Total

18

/

20

Passed

Validation

87%

Checks the skill against the spec for correct structure and formatting. All validation checks must pass before discovery and implementation can be scored.

Validation — 14 / 16 Passed

Validation for skill structure

CriteriaDescriptionResult

skill_md_line_count

SKILL.md is long (515 lines); consider splitting into references/ and linking

Warning

metadata_version

'metadata.version' is missing

Warning

Total

14

/

16

Passed

Repository
affaan-m/ECC
Reviewed

Table of Contents

Is this your skill?

If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.