Skip to main content
Manusで任意のスキルを実行
ワンクリックで

python-service-and-schema-cohesion

スター4
フォーク0
更新日2026年5月17日 18:29

Use when designing or editing services and schemas in a FastAPI + SQLAlchemy backend: files in `app/services/` and `app/schemas/`. Triggers on edits to those directories; on definitions of `class *Service`, `class *Command`, `class *Get`; on user mentions of "use case", "service layer", "Pydantic schema", "command", "response shape", "from_model", "to_new_X", "cohesion", "domain service", "policy", "god service", "business rule extraction". Encodes: class-when-state vs function-when-stateless, service returns Pydantic schema (not SA model), top-level service owns the transaction with `AsyncSession.begin()`, composable collaborators do not commit, pure domain services/policies for business rules that do not belong to one aggregate, schema naming (*Get / *Create / *Update / *Command), cohesion methods (`from_<source>` classmethod inbound, `to_<target>` method outbound), Pydantic v2 `from_attributes=True`, no `utils.py` / no free transform functions. Do NOT use for: repos (use python-aggregate-and-repo), routes

インストール

Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。

ファイルエクスプローラー
3 ファイル
SKILL.md
readonly