platform-backend

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Principles

原则

  • Throw early with guard clauses — fail fast at the top of functions
  • Never swallow errors silently — log or propagate every failure
  • 使用守卫语句尽早抛出异常——在函数顶部快速失败
  • 切勿静默忽略错误——记录或传播每一处故障

Rules

规则

See rules index for detailed patterns.
查看规则索引获取详细模式。

Examples

示例

Positive Trigger

触发场景

User: "Design error handling and validation strategy for this API endpoint."
Expected behavior: Use
platform-backend
guidance, follow its workflow, and return actionable output.
用户:“为这个API端点设计错误处理和验证策略。”
预期行为:遵循
platform-backend
指导规范,执行其工作流程,并返回可落地的输出结果。

Non-Trigger

非触发场景

User: "Create a Tailwind design token scale."
Expected behavior: Do not prioritize
platform-backend
; choose a more relevant skill or proceed without it.
用户:“创建Tailwind设计令牌体系。”
预期行为:不优先使用
platform-backend
;选择更相关的Skill或直接执行任务。

Troubleshooting

故障排查

Skill Does Not Trigger

Skill未触发

  • Error: The skill is not selected when expected.
  • Cause: Request wording does not clearly match the description trigger conditions.
  • Solution: Rephrase with explicit domain/task keywords from the description and retry.
  • 问题:预期情况下Skill未被选中。
  • 原因:请求表述未明确匹配描述中的触发条件。
  • 解决方案:使用描述中的明确领域/任务关键词重新表述请求后重试。

Guidance Conflicts With Another Skill

指导规范与其他Skill冲突

  • Error: Instructions from multiple skills conflict in one task.
  • Cause: Overlapping scope across loaded skills.
  • Solution: State which skill is authoritative for the current step and apply that workflow first.
  • 问题:同一任务中多个Skill的指令存在冲突。
  • 原因:已加载的Skill存在范围重叠。
  • 解决方案:指定当前步骤以哪个Skill为权威,优先应用其工作流程。

Output Is Too Generic

输出过于笼统

  • Error: Result lacks concrete, actionable detail.
  • Cause: Task input omitted context, constraints, or target format.
  • Solution: Add specific constraints (environment, scope, format, success criteria) and rerun.
  • 问题:结果缺乏具体、可落地的细节。
  • 原因:任务输入遗漏了上下文、约束条件或目标格式。
  • 解决方案:添加具体约束(环境、范围、格式、成功标准)后重新运行。

Workflow

工作流程

  1. Identify whether the request clearly matches
    platform-backend
    scope and triggers.
  2. Apply the skill rules and referenced guidance to produce a concrete result.
  3. Validate output quality against constraints; if gaps remain, refine once with explicit assumptions.
  1. 判断请求是否明确匹配
    platform-backend
    的范围和触发条件。
  2. 应用Skill规则及参考的指导规范生成具体结果。
  3. 根据约束条件验证输出质量;若仍存在不足,基于明确假设优化一次。