dhirajchaudhari20/agentic-ai-incident-response

GitHub: dhirajchaudhari20/agentic-ai-incident-response

一个多智能体事件响应与自动化工作流项目,解决从杂乱数据生成可验证报告与行动项的问题。

Stars: 0 | Forks: 0

# 未来转型 - AI 开发者实习生任务 **Candidate**: Dhiraj Chaudhari **Submission Date**: April 18, 2026 ## 仓库结构 ``` ├── incident-response-agent/ # Task 1: Agentic AI — Incident Response │ ├── main.py # Entry point (generates reports) │ ├── README.md # Full documentation │ ├── data/ # Input files (alerts, metrics, logs, chat, runbook) │ ├── agents/ # 4 agents (triage, forensics, hypothesis, verifier) │ ├── tools/ # 8 callable tools │ ├── state/ # LangGraph state schema │ ├── safety/ # Prompt injection defense │ ├── gold/ # Gold case expected outputs │ ├── tests/ # 12 test scenarios + evaluation │ └── output/ # Generated incident_report.md + action_items.json │ └── n8n-lead-automation/ # Task 2: n8n — Lead-to-Support Workflow ├── workflow.json # Exported n8n workflow ├── README.md # Setup instructions └── sample_payloads/ # 10 webhook payload JSONs ``` ## 任务1:事件响应代理 ### 快速启动 ``` cd incident-response-agent pip install -r requirements.txt python main.py ``` ### 它的功能 一个自主多智能体系统,能够摄取杂乱的 incident 数据并生成: - **`output/incident_report.md`** — 带有证据支持的时间线验证后的 incident 报告 - **`output/action_items.json`** — 带有推断负责人的优先级行动项 ### 关键特性 | Feature | Implementation | |---------|---------------| | **Multi-Agent** | 4 个智能体:Triage、Forensics、Hypothesis、Verifier | | **Tools** | 8 个可调用工具(file_loader、log_search、metrics_parser、anomaly_detector、entity_extractor、runbook_applier、evidence_indexer、timeline_builder) | | **State Machine** | 包含 6 个阶段及条件重新调查的 LangGraph StateGraph | | **Safety** | 提示注入检测、输入清洗、工具允许列表 | | **Evidence** | 每一项声明均引用来源,格式为 `path:L#-L#` | | **Testing** | 金标准用例 + 12 个边缘场景 + 评估指标 | ### 流水线结果(黄金案例) ``` Severity: P1 Impacted Services: api-gateway, orders, payments Start Time: 2026-01-17T10:30:00Z Root Cause: Bad database migration caused table locks, exhausting the connection pool and cascading to dependent services Verified Claims: 5/5 (100%) Rejected Claims: 0 ``` 📖 **Full documentation**: [incident-response-agent/README.md](incident-response-agent/README.md) ## 任务2:n8n 潜在客户到支持自动化 ### 工作流 ``` Webhook → Validate → Enrich → Store (Sheets) → Route by Urgency │ ┌─────────────┤ ▼ ▼ HIGH NORMAL Slack Alert Conf Email Trello Card ``` ### 功能 - 带有字段验证 + 垃圾检测功能的 Webhook 触发 - 潜在客户扩展(从邮箱域名提取公司信息) - 通过 MD5 哈希实现幂等性(重放 3 次 → 1 条记录) - Google Sheets 存储与死信表 - 高优先级 → Slack 提醒 + Trello 卡片 - 普通优先级 → 确认邮件 - 每日下午 6 点摘要(按优先级、产品、Top 5 潜在客户统计) 📖 **Full documentation**: [n8n-lead-automation/README.md](n8n-lead-automation/README.md) ## 交付清单 ### 任务1 - [x] `main.py` 可运行 — 生成 `incident_report.md` 与 `action_items.json` - [x] 输入文件已提交 — `alerts.json`、`metrics.csv`、`logs/`、`chat.txt`、`runbook.md` - [x] 多智能体编排(4 个智能体)+ 验证器 - [x] 状态机/图(LangGraph StateGraph) - [x] 8 个可调用工具(在 README 中文档化) - [x] 安全性 — `chat.txt` 与 `runbook.md` 中的提示注入防御 - [x] 证据溯源 — 所有声明均引用 `path:lineStart-lineEnd` - [x] 金标准用例与预期输出(`gold/expected.json`) - [x] 12 个测试场景(`tests/test_scenarios.py`) - [x] README 中的评估指标 ### 任务2 - [x] 导出的 n8n 工作流 JSON - [x] 设置说明(凭据/环境变量) - [x] 10 个示例 Webhook 负载 JSON - [x] 幂等性实现 - [x] 错误处理与死信路径 - [x] 每日摘要
标签:AI 代理, AMSI绕过, LangGraph, Lead-to-Support, n8n 自动化, Prompt 安全, PyRIT, Python 自动化, SEO: AI 开发者实习, SEO: n8n 工作流, SEO: 事件响应代理, SEO: 自动化安全响应, Webhook 集成, 多智能体系统, 威胁检测, 实习项目, 实体抽取, 工作流编排, 异常检测, 指标解析, 文件加载, 注入防御, 测试评估, 自动化响应, 证据索引, 运行手册应用, 逆向工具