Help / Red Codens
エラー検知 → 自動修正 PR。Sentry や手動報告から検知したバグを解析し、修正 plan を生成。複雑な fix は Purple chain に提出して PR まで自動化します。
Red Codens のメインユニットは bug report です。bug report は次のいずれかから生成されます:
解析が走ると fix plan が生成され、ワンクリック / 1 コールで Purple Codens に提出して PR を出すところまで自動化できます。3-Retry ロジックでテスト fail から最大数回まで自動改善します。
codens-mcp がインストール済み・ログイン済みダッシュボード(app.red.codens.ai)から「New Project」を選択。または MCP 経由で他プロダクトとまとめて登録:
// 複数プロダクトに 1 コールで登録
await tools.codens_register_project_unified({
repo_full_name: "Corevice/your-repo",
products: ["red", "purple"]
});project 作成時に GitHub App の install ステータスを確認するため、未 install の場合は install フローへ誘導されます。
issue が webhook で届くと自動で bug report が作成され、解析がキックされます。
// 解析もまとめてキック
await tools.red_bug_report({
action: "create",
project_id: "...",
title: "Login endpoint returns 500 on empty password",
description: "...",
severity: "high",
auto_analyze: true
});// 解析結果から fix plan を生成
const plan = await tools.red_bug_fix_plan({
action: "generate",
bug_id: "..."
});
// Purple Codens に提出して PR 化
const submission = await tools.red_bug_fix_plan({
action: "submit_to_purple",
plan_id: plan.id
});
// → workflow run が走り、PR URL が返る単純な fix は red_fix_proposal 単独でも PR を出せますが、構造的な修正や複数ファイルにまたがる fix は Purple chain の方が結果が良くなります。
red_external_task で「リファクタリング」「機能追加」「テスト作成」など bug 以外のタスクも実行可能