AgentSkillsCN

mythosmud-full-stack-feature

在全栈范围内实现MythosMUD的各项功能:前端(React/TypeScript)、后端(FastAPI/Pydantic),以及持久化层(PostgreSQL)。适用于用户提出功能实现需求、新增接口,或构建全新能力时使用。

SKILL.md
--- frontmatter
name: mythosmud-full-stack-feature
description: Implement MythosMUD features across the full stack: client (React/TypeScript), server (FastAPI/Pydantic), and persistence (PostgreSQL). Use when the user asks to implement a feature, add an endpoint, or build a new capability.

MythosMUD Full-Stack Feature

Principle

When implementing a feature, implement the entire stack: client, server, and persistence (where applicable).

Authority

Server is authoritative over the client. On any disparity, server state is correct; client must follow server data (events, command responses, room/game state). See CLAUDE.md "SERVER AUTHORITY" and .cursor/rules/server-authority.mdc.

Checklist

  • API / server: Routes, request/response models (Pydantic), business logic. Location: server/
  • Persistence: Schema changes, migrations, repositories if needed. PostgreSQL only; see mythosmud-database-placement. Location: db/, server/
  • Client: UI, hooks, API calls, types. Location: client/. Client state must reflect server authority.
  • Terminology: Use "coordinator" or "controller," not "master"; use "agent," not "slave"

Stack Summary

LayerTechNotes
ClientReact 18+, TypeScriptclient/
APIFastAPI, Pydanticserver/
DataPostgreSQLNo SQLite; no *.db without permission

When to Touch Each Layer

  • New endpoint: Server route + Pydantic models; client API function + types; optionally OpenAPI regen (see mythosmud-openapi-workflow).
  • New screen or flow: Client components + server endpoints + persistence if data is stored.
  • New persisted entity: DB schema/migrations, server repository and models, client types and UI.

Reference