convex-optimize
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
Chinese<!-- GENERATED from convex-agents content/capabilities/optimize.json — do not edit by hand. -->
<!-- 根据 convex-agents content/capabilities/optimize.json 生成——请勿手动编辑。 -->
Audit and optimize an existing Convex app
审计并优化现有的 Convex 应用
The remediation WORKFLOW for an existing app: open with a scored assessment, then act on it — upgrade stale components and set up observability — plan-then-confirm-then-apply. The assessment itself is delegated to launch-readiness (the findings-bus scorer); optimize's distinct value is the actions it takes on the result.
这是针对现有应用的修复工作流:首先进行评分评估,再根据结果采取行动——升级过期组件并设置可观测性——整个过程遵循先规划、再确认、后执行的原则。评估工作本身会委派给 launch-readiness(findings-bus 评分器);optimize 的独特价值在于根据评估结果执行相应操作。
Workflow
工作流
- Detect the app: a directory, the schema, and whether it's an anonymous or cloud deployment.
convex/ - ASSESS via — one scored, deduped report across authz/reviewer/advisor/insights with an ordered fix plan. Do not re-run those passes by hand; optimize consumes launch-readiness's report rather than re-implementing the audit.
launch-readiness - UPGRADE: run against the pinned
check-updatescomponents and fold stale-component (staleness-class) findings into the same plan.@convex-dev/* - OBSERVABILITY: if the readiness report flagged an observability gap (no prod error capture), offer to install .
sentinel - Present the combined prioritized plan — the launch-readiness score + the fix plan + upgrades + observability, security/data-loss first — and apply only on explicit confirmation, dispatching each fix to its fixCapability.
- After applying, re-run the launch-readiness assessment and show the score delta.
- 检测应用:查找 目录和 schema,并判断应用采用匿名(anonymous)部署还是云端(cloud)部署。
convex/ - 通过 launch-readiness 进行评估——汇总 authz/reviewer/advisor/insights,生成一份带评分且去重的报告,并附带按优先级排序的修复计划。不要手动重新运行这些检查流程;optimize 应直接使用 launch-readiness 的报告,而不是重新实现审计。
- 升级:针对已锁定版本的 组件运行
@convex-dev/*,并将过期组件(staleness-class)相关发现合并到同一计划中。check-updates - 可观测性:如果就绪报告指出存在可观测性缺口(未捕获生产环境错误),则提议安装 。
sentinel - 展示合并后的优先级计划——包括 launch-readiness 评分、修复计划、升级和可观测性措施,并优先处理安全与数据丢失风险——仅在获得明确确认后执行,同时将每项修复分派给对应的 fixCapability。
- 应用修复后,重新运行 launch-readiness 评估并展示评分变化。
Rules
规则
- Read-only first. Present a plan and CONFIRM before changing any file.
- Delegate the audit to launch-readiness (the findings-bus scorer); don't re-implement reviewer/advisor/insights inline — optimize's job is acting on the report (upgrades + observability), not re-scoring.
- Prioritize security and data-loss risks above style, following launch-readiness's ordering.
- Never auto-land changes on someone's existing prod app; re-assess after applying and show the score moved.
- 首先保持只读。展示计划,并在修改任何文件前进行确认。
- 将审计委派给 launch-readiness(findings-bus 评分器);不要在内部重新实现 reviewer/advisor/insights——optimize 的职责是根据报告采取行动(升级 + 可观测性),而不是重新评分。
- 按照 launch-readiness 的排序,将安全与数据丢失风险置于样式问题之上。
- 绝不要将变更自动落地到用户现有的生产应用;应用后重新评估,并展示评分变化。