Files
digital-psychology/.ai/workflow.md
T
jackyu66gitandCursor 0f320e040b feat: P1 profile/portrait API and freeze local-dev environment
Add host-first environment contracts (Local vs CI vs Prod), deps-only
compose, and the Profile → Portrait → deep-access mock payment slice
with device identity and auto-migrate on API startup.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-02 16:24:57 +08:00

1.3 KiB
Raw Blame History

Workflow — Feature Development Flow

默认循环。环境:本机 Go/Vite + deps-only Docker(见 development.md)。

Receive task
    ↓
1. Understand
   - feature-map / user-journey / lexicon(产品)
   - domain-map / erd / OpenAPI(数据与契约)
   - page-tree(路由)
    ↓
2. Design(若有缺口)
   - Update OpenAPI / erd / migration 草案
   - ADR if stack/API style changes
    ↓
3. Implement
   - Backendservice 竖切)→ Frontend
   - Follow patterns + playbooks
    ↓
4. Verify
   - commandstest / health / build:h5
   - review.md
   - DoD + checklist
    ↓
5. Document
   - OpenAPI / erd / feature 标记若行为变化
    ↓
CommitConventional Commitsone concern

Architecture Check

  1. Reverse Accepted ADR? → ASK / new ADR.
  2. Correct layer? Handler / Service / Repository?
  3. Domain words = .ai/domain.md + lexicon for UI?
  4. Envelope still {code,message,data}?
  5. Local workflow still host runtime(非 Docker-only 编码)?

Stop conditions

  • Unclear requirement → ASK FIRST
  • Need GraphQL / new auth scheme / new datastore → ADR before coding
  • Urge to “just ALTER TABLE” → write migration instead

Playbooks

Prefer: add-api · new-page · new-table · payment · login