project-guidelines-example

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Project Guidelines Skill (Example)

项目规范Skill(示例)

This is an example of a project-specific skill. Use this as a template for your own projects.
Based on a real production application: Zenith - AI-powered customer discovery platform.
这是一个项目专属Skill的示例。可将其作为模板创建自有项目的规范。
基于真实生产应用:Zenith - 人工智能驱动的客户发现平台。

When to Use

使用场景

Reference this skill when working on the specific project it's designed for. Project skills contain:
  • Architecture overview
  • File structure
  • Code patterns
  • Testing requirements
  • Deployment workflow
在为其设计的特定项目中工作时,请参考本Skill。项目Skill包含:
  • 架构概述
  • 文件结构
  • 代码模式
  • 测试要求
  • 部署流程

Reference Documents

参考文档

  • Architecture & File Structure - Tech stack, service diagram, directory layout
  • Code Patterns - API response format, frontend API calls, Claude AI integration, custom hooks
  • Testing & Deployment - pytest, React Testing Library, deployment commands, environment variables
  • 架构与文件结构 - 技术栈、服务图、目录布局
  • 代码模式 - API响应格式、前端API调用、Claude AI集成、自定义hooks
  • 测试与部署 - pytest、React Testing Library、部署命令、环境变量

Critical Rules

关键规则

  1. No emojis in code, comments, or documentation
  2. Immutability - never mutate objects or arrays
  3. TDD - write tests before implementation
  4. 80% coverage minimum
  5. Many small files - 200-400 lines typical, 800 max
  6. No console.log in production code
  7. Proper error handling with try/catch
  8. Input validation with Pydantic/Zod
  1. 代码、注释或文档中禁止使用表情符号
  2. 不可变性 - 绝不修改对象或数组
  3. TDD - 先编写测试再实现功能
  4. 最低80%测试覆盖率
  5. 多采用小文件 - 通常200-400行,最多800行
  6. 生产代码中禁止使用console.log
  7. 使用try/catch进行正确的错误处理
  8. 使用Pydantic/Zod进行输入验证

Related Skills

相关Skills

  • coding-standards
    - General coding best practices
  • backend-patterns
    - API and database patterns
  • frontend-patterns
    - React and Next.js patterns
  • tdd-workflow
    - Test-driven development methodology
  • coding-standards
    - 通用编码最佳实践
  • backend-patterns
    - API与数据库模式
  • frontend-patterns
    - React和Next.js模式
  • tdd-workflow
    - 测试驱动开发方法论