diff --git a/README.ja.md b/README.ja.md index 2b153ec5..86a3a939 100644 --- a/README.ja.md +++ b/README.ja.md @@ -1,6 +1,6 @@ ### OpenDeRisk -OpenDeRisk AI-Native Risk Intelligence Systems —— AIネイティブなリスクインテリジェンスシステム。アプリケーションシステムのリスクインテリジェントマネージャーとして、24時間365日の包括的で徹底的な保護を提供します。 +OpenDeRisk は AI ネイティブリスクインテリジェンスシステムです。アプリケーションシステムのリスクインテリジェントマネージャーとして、24 時間 365 日の包括的で徹底的な保護を提供します。

@@ -24,18 +24,18 @@ OpenDeRisk AI-Native Risk Intelligence Systems —— AIネイティブなリス

-[**English**](README.md) | [**简体中文**](README.zh.md) | [**日本語**](README.ja.md) | [**視頻チュートリアル**](https://www.youtube.com/watch?v=1qDIu-Jwdf0) +[**English**](README.md) | [**简体中文**](README.zh.md) | [**日本語**](README.ja.md) | [**動画チュートリアル**](https://www.youtube.com/watch?v=1qDIu-Jwdf0)
### ニュース -- [2025/10] 🔥 OpenDerisk V0.2をリリースしました. [OpenDerisk V0.2 ReleaseNote](./docs/docs/OpenDerisk_v0.2.md) +- [2025/10] 🔥 OpenDerisk V0.2 をリリースしました。[OpenDerisk V0.2 ReleaseNote](./docs/docs/OpenDerisk_v0.2.md) ### 機能特徴 1. **DeepResearch RCA:** ログ、トレース、コードの詳細な分析により、問題の根本原因を迅速に特定します。 2. **可視化された証拠チェーン:** 診断プロセスと証拠チェーンを完全に可視化し、診断を明確にして精度を迅速に判断できます。 -3. **マルチエージェント協調:** SRE-Agent、Code-Agent、ReportAgent、Vis-Agent、Data-Agentの協調作業。 -4. **オープンソースアーキテクチャ:** OpenDeRiskは完全にオープンソースのアーキテクチャで構築されており、関連フレームワークとコードをオープンソースプロジェクトですぐに使用できます。 +3. **マルチエージェント協調:** SRE-Agent、Code-Agent、ReportAgent、Vis-Agent、Data-Agent の協調作業。 +4. **オープンソースアーキテクチャ:** OpenDeRisk は完全にオープンソースのアーキテクチャで構築されており、関連フレームワークとコードをオープンソースプロジェクトですぐに使用できます。

@@ -47,118 +47,97 @@ OpenDeRisk AI-Native Risk Intelligence Systems —— AIネイティブなリス

#### 紹介文書 -- [OpenDerisk DeepWikiドキュメント](https://deepwiki.com/derisk-ai/OpenDerisk) - -このシステムはマルチエージェントアーキテクチャを採用しています。現在、コードは主に緑色でハイライトされた部分を実装しています。アラート認識はMicrosoftのオープンソース[OpenRCAデータセット](https://github.com/microsoft/OpenRCA)に基づいています。データセットのサイズは解凍後約26GBです。このデータセット上で、マルチエージェントの協調により根本原因分析と診断を実現し、Code-Agentが最終分析のために動的にコードを作成します。 +このシステムはマルチエージェントアーキテクチャを採用しています。現在、コードは主にハイライトされた部分を実装しています。アラート認識は Microsoft のオープンソース [OpenRCA データセット](https://github.com/microsoft/OpenRCA) に基づいています。データセットのサイズは解压後約 26GB です。このデータセット上で、マルチエージェントの協調により根本原因分析と診断を実現し、Code-Agent が最終分析のために動的にコードを作成します。 #### 技術実装 -**データ層:** GitHubから大規模なOpenRCAデータセット(20GB)を取得し、ローカルで解凍して分析用に処理します。 +**データ層:** GitHub から大規模な OpenRCA データセット (20GB) を取得し、ローカルで解压して分析用に処理します。 -**ロジック層:** マルチエージェントアーキテクチャで、SRE-Agent、Code-Agent、ReportAgent、Vis-Agent、Data-Agentが協調して詳細なDeepResearch RCA(根本原因分析)を実行します。 +**ロジック層:** マルチエージェントアーキテクチャで、SRE-Agent、Code-Agent、ReportAgent、Vis-Agent、Data-Agent が協調して詳細な DeepResearch RCA(根本原因分析)を実行します。 -**可視化層:** Visプロトコルを使用して、全体の処理フローと証拠チェーン、およびマルチロールの協調とスイッチングプロセスを動的にレンダリングします。 +**可視化層:** Vis プロトコルを使用して、全体の処理フローと証拠チェーン、およびマルチロールの協調とスイッチングプロセスを動的にレンダリングします。 -OpenDeRiskのデジタル従業員(エージェント) +OpenDeRisk のデジタル従業員(エージェント)

-### クイックスタート +### インストール(推奨) -uvのインストール +#### curl でのインストール ```shell -curl -LsSf https://astral.sh/uv/install.sh | sh +# 最新バージョンのダウンロードとインストール +curl -fsSL https://raw.githubusercontent.com/derisk-ai/OpenDerisk/main/install.sh | bash ``` -#### パッケージのインストール +#### 設定ファイル +インストール後、システムを設定する必要があります。設定ファイルを作成してください: +`~/.openderisk/derisk-proxy-aliyun.toml` を編集し、API キーを設定してください。 +#### 起動 ``` -uv sync --all-packages --frozen \ ---extra "base" \ ---extra "proxy_openai" \ ---extra "rag" \ ---extra "storage_chromadb" \ ---extra "derisks" \ ---extra "storage_oss2" \ ---extra "client" \ ---extra "ext_base" +openderisk-server ``` -#### 起動 +### ソースからのインストール(開発用) + +uv のインストール(必須): +```shell + +git clone https://github.com/derisk-ai/OpenDerisk.git + +cd OpenDerisk + +# 依存関係のインストール +sh scripts/prepare_release.sh +``` -`derisk-proxy-aliyun.toml`ファイルでAPI_KEYを設定し、次のコマンドを実行して起動します。 +#### サーバーの起動 -> 注意:デフォルトでは、OpenRCAデータセットのTelecomデータセットを使用します。リンクまたは以下のコマンドでダウンロードできます: +`derisk-proxy-aliyun.toml` で API_KEY を設定し、実行: -> gdown https://drive.google.com/uc?id=1cyOKpqyAP4fy-QiJ6a_cKuwR7D46zyVe +> 注意:デフォルトでは、OpenRCA データセットの Telecom データセットを使用します。リンクまたは以下のコマンドでダウンロードできます: +> `gdown https://drive.google.com/uc?id=1cyOKpqyAP4fy-QiJ6a_cKuwR7D46zyVe` -ダウンロード後、データセットを`pilot/datasets/`パスに移動します。 +ダウンロード後、データセットを `pilot/datasets/` パスに移動します。 起動コマンドを実行: -``` +```bash uv run python packages/derisk-app/src/derisk_app/derisk_server.py --config configs/derisk-proxy-aliyun.toml ``` #### ウェブサイトへのアクセス -ブラウザを開いて[`http://localhost:7777`](http://localhost:7777)にアクセス -

- -

+ブラウザを開いて [`http://localhost:7777`](http://localhost:7777) にアクセス + ### 使用方法 -* AI-SRE(OpenRCA) - - 注意:OpenRCAデータセット[Bankデータセット](https://drive.usercontent.google.com/download?id=1enBrdPT3wLG94ITGbSOwUFg9fkLR-16R&export=download&confirm=t&uuid=42621058-41af-45bf-88a6-64c00bfd2f2e)を使用しています - - 次のリンクでデータセットをダウンロードできます: - ``` - gdown https://drive.google.com/uc?id=1enBrdPT3wLG94ITGbSOwUFg9fkLR-16R - ``` - - データセットを`${derisk}/pilot/datasets`パスに配置します。 -* フレームグラフアシスタント - - ローカルアプリケーションサービスプロセスのフレームグラフ(Java/Python)をアシスタントにアップロードして分析と問い合わせを行います。 -* DataExpert - - メトリクス、ログ、トレース、または様々なExcelデータシートをアップロードして対話型分析を行います。 +* **AI-SRE (OpenRCA)** + - 注意: OpenRCA データセットの [Bank データセット](https://drive.usercontent.google.com/download?id=1enBrdPT3wLG94ITGbSOwUFg9fkLR-16R&export=download&confirm=t&uuid=42621058-41af-45bf-88a6-64c00bfd2f2e) を使用しています + - ダウンロード: `gdown https://drive.google.com/uc?id=1enBrdPT3wLG94ITGbSOwUFg9fkLR-16R` + - データセットを `${derisk}/pilot/datasets` パスに配置します +* **フレームグラフアシスタント** + - ローカルアプリケーションサービスプロセスのフレームグラフ (Java/Python) をアシスタントにアップロードして分析を行います +* **DataExpert** + - メトリクス、ログ、トレース、または様々な Excel データシートをアップロードして対話型分析を行います ### 高速開発 -* エージェント開発 - `derisk-ext.agent.agents`配下の実装ロジックを参照してください。 -* ツール開発 - * ローカルツール - * MCP -* その他の開発 - ドキュメント準備中... - -* DeRisk-Skills 発達 +* **エージェント開発** + - `derisk-ext.agent.agents` 配下の実装ロジックを参照してください +* **ツール開発** + * ローカルツール + * MCP (Model Context Protocol) +* **DeRisk-Skills 開発** - [derisk-skills](https://github.com/derisk-ai/derisk_skills) #### 実行結果 -下図に示すように、複数のエージェントが協調して複雑な運用診断タスクを処理するシナリオを示しています。 +下图に示すように、複数のエージェントが協調して複雑な運用診断タスクを処理するシナリオを示しています。

-### ロードマップ -- [x] 0530 V0.1バージョン:ドメイン知識とMCPサービスに基づき、異常認識→自律的意思決定→適応的実行と問題解決を実現。 - - [x] 技術リスクのためのドメイン知識エンジン - - [x] 異常認識→意思決定→実行のための大規模モデル駆動推論エンジン - - [x] 自動トラブルシューティングと修正 - -- [x] 0830 V0.2バージョン - - [x] 技術リスクのためのMCPサービスと管理 - - [x] 知識とMCPツールのカスタムバインディングサポート - - [x] 3つ以上のDevOpsドメインMCPサービスのサポート - -- [ ] 0930 V0.3バージョン - - [ ] 本番環境との統合サポート - - [ ] 本番環境デプロイメントの完全なソリューションを提供し、本番の問題診断をサポート。 - -- [ ] 1230 V0.4バージョン - - [ ] エンドツーエンドAIOpsオンラインAgentic RL - - [ ] エンドツーエンド評価機能 - -### いんよう +### 引用 このリポジトリのコードについては、以下の論文で詳細な紹介をしています。もし、あなたの研究に役立ったと思われる場合は、ぜひ引用してください。 ``` @misc{di2025openderiskindustrialframeworkaidriven, @@ -178,14 +157,15 @@ uv run python packages/derisk-app/src/derisk_app/derisk_server.py --config confi - [MetaGPT](https://github.com/FoundationAgents/MetaGPT) - [OpenRCA](https://github.com/microsoft/OpenRCA) -OpenDeRisk-AIコミュニティは、AIネイティブなリスクインテリジェンスシステムの構築に専念しています。🛡️ 私たちのコミュニティがより良いサービスを提供できることを願い、また皆様が私たちに参加してより良い未来を共に創造することを願っています。🤝 +OpenDeRisk-AI コミュニティは、AI ネイティブなリスクインテリジェンスシステムの構築に専念しています。🛡️ 私たちのコミュニティがより良いサービスを提供できることを願い、また皆様が私たちに参加してより良い未来を共に創造することを願っています。🤝 + [![Star History Chart](https://api.star-history.com/svg?repos=derisk-ai/OpenDerisk&type=Date)](https://star-history.com/#derisk-ai/OpenDerisk) ### コミュニティグループ -DingDingのネットワーキンググループに参加して、他の開発者と経験を共有しましょう! +DingTalk グループに参加して、他の開発者と経験を共有しましょう!
OpenDeRisk-AI 交流群 diff --git a/README.md b/README.md index f57b4367..cff0e6ca 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ ### OpenDeRisk -OpenDeRisk AI-Native Risk Intelligence Systems —— Your application system risk intelligent manager provides 7 * 24-hour comprehensive and in-depth protection. +OpenDeRisk is an AI-Native Risk Intelligence System designed as your application system's intelligent manager, providing 7×24 hour comprehensive and in-depth protection.

@@ -27,149 +27,116 @@ OpenDeRisk AI-Native Risk Intelligence Systems —— Your application system ri

-[**English**](README.md) | [**简体中文**](README.zh.md) | [**日本語**](README.ja.md) | [**视频教程**](https://www.youtube.com/watch?v=1qDIu-Jwdf0) +[**English**](README.md) | [**简体中文**](README.zh.md) | [**日本語**](README.ja.md) | [**Video Tutorial**](https://www.youtube.com/watch?v=1qDIu-Jwdf0)
- -### News -- [2025/10] 🔥 We released OpenDerisk v0.2. [OpenDerisk V0.2 ReleaseNote](./docs/docs/OpenDerisk_v0.2.md) - - ### Features -1. **DeepResearch RCA:** Quickly locate the root cause of issues through in-depth analysis of logs, traces, and code. -2. **Visualized Evidence Chain:** Fully visualize the diagnostic process and evidence chain, making the diagnosis clear and enabling quick judgment of accuracy. -3. **Multi-Agent Collaboration:** Collaboration among SRE-Agent, Code-Agent, ReportAgent, Vis-Agent, and Data-Agent. -4. **Open and Open-Source Architecture:** OpenDeRisk is built with a completely open and open-source architecture, allowing related frameworks and code to be used out of the box in open-source projects. +1. **DeepResearch RCA:** Quickly locate root causes through in-depth analysis of logs, traces, and code. +2. **Visualized Evidence Chain:** Fully visualize diagnostic processes and evidence chains for clear, accurate judgment. +3. **Multi-Agent Collaboration:** SRE-Agent, Code-Agent, ReportAgent, Vis-Agent, and Data-Agent working in coordination. +4. **Open-Source Architecture:** Built with a completely open architecture, enabling framework and code reuse in open-source projects.

-### Architure +### Architecture

#### Introduction - -- [OpenDerisk Documents](https://deepwiki.com/derisk-ai/OpenDerisk) - -- [OpenDerisk DeepWiki](https://deepwiki.com/derisk-ai/OpenDerisk) - - -The system adopts a multi-agent architecture. Currently, the code mainly implements the green-highlighted parts. Alert awareness is based on Microsoft's open-source [OpenRCA dataset](https://github.com/microsoft/OpenRCA). The dataset size is approximately 26GB after decompression. On this dataset, we achieve root cause analysis and diagnosis through multi-agent collaboration, where the Code-Agent dynamically writes code for final analysis. +The system employs a multi-agent architecture. Currently, the code primarily implements the highlighted components. Alert awareness is based on Microsoft's open-source [OpenRCA dataset](https://github.com/microsoft/OpenRCA). The decompressed dataset is approximately 26GB. On this dataset, we achieve root cause analysis through multi-agent collaboration, with Code-Agent dynamically writing code for final analysis. #### Technical Implementation -**Data Layer:** Pull the large-scale OpenRCA dataset (20GB) from GitHub, decompress it locally, and process it for analysis. +**Data Layer:** Pull the large-scale OpenRCA dataset (20GB) from GitHub, decompress locally, and process for analysis. -**Logic Layer:** Multi-agent architecture, with collaboration among SRE-Agent, Code-Agent, ReportAgent, Vis-Agent, and Data-Agent to perform in-depth DeepResearch RCA (Root Cause Analysis). +**Logic Layer:** Multi-agent architecture with SRE-Agent, Code-Agent, ReportAgent, Vis-Agent, and Data-Agent collaborating for deep DeepResearch RCA (Root Cause Analysis). -**Visualization Layer:** Use the Vis protocol to dynamically render the entire processing flow and evidence chain, as well as the process of multi-role collaboration and switching. +**Visualization Layer:** Use the Vis protocol to dynamically render the entire processing flow and evidence chain, as well as the multi-role collaboration and switching process. Digital Employees (Agents) in OpenDeRisk

-### Quick Start +### Install (recommended) -Install uv +#### Install via curl ```shell -curl -LsSf https://astral.sh/uv/install.sh | sh +# Download and install latest version +curl -fsSL https://raw.githubusercontent.com/derisk-ai/OpenDerisk/main/install.sh | bash ``` +#### Configuration File +After installation, you need to configure the system. Create a configuration file: +Edit `~/.openderisk/derisk-proxy-aliyun.toml` and set your API keys. -#### Install Packages - +#### Start ``` -uv sync --all-packages --frozen \ ---extra "base" \ ---extra "proxy_openai" \ ---extra "rag" \ ---extra "storage_chromadb" \ ---extra "derisks" \ ---extra "storage_oss2" \ ---extra "client" \ ---extra "ext_base" +openderisk-server ``` -#### Start +### From source(development) -Configure the API_KEY in the `derisk-proxy-aliyun.toml` file, then run the following command to start. +Install uv (required): +```shell +git clone https://github.com/derisk-ai/OpenDerisk.git -> Note: By default, we use the Telecom dataset from the OpenRCA dataset. You can download it via the link or the following command: +cd OpenDerisk + +# Install Dependencies +sh scripts/prepare_release.sh +``` -> gdown https://drive.google.com/uc?id=1cyOKpqyAP4fy-QiJ6a_cKuwR7D46zyVe +#### Start Server -After downloading, move the datasets to the path `pilot/datasets/` +Configure the API_KEY in `derisk-proxy-aliyun.toml`, then run: + +> Note: By default, we use the Telecom dataset from OpenRCA. Download via: +> `gdown https://drive.google.com/uc?id=1cyOKpqyAP4fy-QiJ6a_cKuwR7D46zyVe` + +After downloading, move datasets to `pilot/datasets/` Run the startup command: -``` +```bash uv run python packages/derisk-app/src/derisk_app/derisk_server.py --config configs/derisk-proxy-aliyun.toml ``` -#### Visit Website +#### Access Web UI Open your browser and visit [`http://localhost:7777`](http://localhost:7777)

-### How to Use? -* AI-SRE(OpenRCA) - - !Notice, We Use the OpenRCA Datasets[Bank Dataset](https://drive.usercontent.google.com/download?id=1enBrdPT3wLG94ITGbSOwUFg9fkLR-16R&export=download&confirm=t&uuid=42621058-41af-45bf-88a6-64c00bfd2f2e), - - You can download the dataset using next link: - ``` - gdown https://drive.google.com/uc?id=1enBrdPT3wLG94ITGbSOwUFg9fkLR-16R - ``` - - Put the datasets to the path ${derisk}/pilot/datasets。 -* Flame Graph Assistant - - Upload the flame graph (Java/Python) of your local application service process to the assistant for analysis and inquiries. -* DataExpert - - Upload your metrics, logs, traces, or various Excel data sheets for conversational analysis. - - -### Rapid Development -* Agent Development - Refer to the implementation logic under `derisk-ext.agent.agents`. -* Tool Development - * Local tool - * MCP -* Other Development - Documentation is under preparation... - -* DeRisk-Skills Development +### Usage Modes +* **AI-SRE (OpenRCA)** + - Notice: We use the OpenRCA Dataset [Bank Dataset](https://drive.usercontent.google.com/download?id=1enBrdPT3wLG94ITGbSOwUFg9fkLR-16R&export=download&confirm=t&uuid=42621058-41af-45bf-88a6-64c00bfd2f2e) + - Download: `gdown https://drive.google.com/uc?id=1enBrdPT3wLG94ITGbSOwUFg9fkLR-16R` + - Place datasets in `${derisk}/pilot/datasets` +* **Flame Graph Assistant** + - Upload flame graphs (Java/Python) from your local application for analysis +* **DataExpert** + - Upload metrics, logs, traces, or Excel data for conversational analysis + +### Development +* **Agent Development** + - Refer to implementations under `derisk-ext.agent.agents` +* **Tool Development** + - Skills + - MCP (Model Context Protocol) +* **DeRisk-Skills** - [derisk-skills](https://github.com/derisk-ai/derisk_skills) #### Execution Results -As shown in the figure below, this demonstrates a scenario where multiple agents collaborate to handle a complex operational diagnostic task. -

-### RoadMap -- [x] 0530 V0.1 Version: Based on domain knowledge and MCP services, achieving anomaly awareness -> autonomous decision-making -> adaptive execution and issue resolution. - - [x] Domain knowledge engine for technical risks - - [x] Reasoning engine driven by large models for anomaly awareness -> decision-making -> execution - - [x] Automated troubleshooting and fixes - -- [x] 0830 V0.2 Version - - [x] MCP services and management for technical risks - - [x] Support for custom binding of knowledge and MCP tools - - [x] Support for 3+ DevOps domain MCP services - -- [ ] 0930 V0.3 Version - - [ ] Support for integration with production environments - - [ ] Provide a complete production environment deployment solution, supporting production issue diagnosis. - -- [ ] 1230 V0.4 Version - - [ ] End-to-end AIOps online Agentic RL - - [ ] End-to-end evaluation capabilities - ### Citation -The code (training, serving, and evaluation) in this repository is mostly developed for or derived from the paper below. Please cite it if you find the repository helpful. +If you find this repository helpful, please cite: ``` @misc{di2025openderiskindustrialframeworkaidriven, title={OpenDerisk: An Industrial Framework for AI-Driven SRE, with Design, Implementation, and Case Studies}, @@ -190,14 +157,13 @@ The code (training, serving, and evaluation) in this repository is mostly develo The OpenDeRisk-AI community is dedicated to building AI-native risk intelligence systems. 🛡️ We hope our community can provide you with better services, and we also hope that you can join us to create a better future together. 🤝 - [![Star History Chart](https://api.star-history.com/svg?repos=derisk-ai/OpenDerisk&type=Date)](https://star-history.com/#derisk-ai/OpenDerisk) ### Community Group -Join our networking group on Dingding and share your experience with other developers! +Join our DingTalk group and share your experience with other developers!
- OpenDeRisk-AI 交流群 -
+ OpenDeRisk-AI Community +
\ No newline at end of file diff --git a/README.zh.md b/README.zh.md index 071a7ed6..ec78af23 100644 --- a/README.zh.md +++ b/README.zh.md @@ -1,6 +1,6 @@ ### OpenDeRisk -OpenDeRisk AI 原生风险智能系统 —— 7\*24H 应用系统AI数字运维助手(AI-SRE), 我们的愿景是, 为每个应用系统提供一个7\*24H的AI系统数字管家,并能与真人进行协同,7\*24H处理业务问题,形成7\*24H得深度护航与防护网。 +OpenDeRisk AI 原生风险智能系统 —— 7×24 小时应用系统 AI 数字运维助手 (AI-SRE)。我们的愿景是为每个应用系统提供一个 7×24 小时的 AI 系统数字管家,能够与真人协同工作,7×24 小时处理业务问题,构建深度护航与防护网。

@@ -28,128 +28,113 @@ OpenDeRisk AI 原生风险智能系统 —— 7\*24H 应用系统AI数字运维

-### News -- [2025/10] 🔥 我们发布了OpenDerisk V0.2版本. [OpenDerisk V0.2 ReleaseNote](./docs/docs/OpenDerisk_v0.2.md) +### 最新动态 +- [2025/10] 🔥 我们发布了 OpenDerisk V0.2 版本。[OpenDerisk V0.2 ReleaseNote](./docs/docs/OpenDerisk_v0.2.md) -### 特性 +### 核心特性

-1. DeepResearch RCA: 通过深度分析日志、Trace、代码进行问题根因的快速定位。 -2. 可视化证据链:定位诊断过程与证据链全部可视化展示,诊断过程一目了然,可以快速判断定位的准确性。 -3. 多智能体协同: SRE-Agent、Code-Agent、ReportAgent、Vis-Agent、Data-Agent协同工作。 -4. 架构开源开放: OpenDerisk采用完全开源、开放的方式构建,相关框架、代码在开源项目也能实现开箱即用。 +1. **DeepResearch RCA**: 通过深度分析日志、Trace、代码进行问题根因的快速定位。 +2. **可视化证据链**: 诊断过程与证据链全部可视化展示,诊断过程一目了然,可快速判断定位准确性。 +3. **多智能体协同**: SRE-Agent、Code-Agent、ReportAgent、Vis-Agent、Data-Agent 协同工作。 +4. **开源开放架构**: OpenDerisk 采用完全开源、开放的方式构建,相关框架、代码在开源项目中可开箱即用。 ### 架构方案

-#### 项目文档 -- [OpenDerisk Documents](https://deepwiki.com/derisk-ai/OpenDerisk) - -#### 介绍文档 -- [OpenDerisk DeepWiki文档](https://deepwiki.com/derisk-ai/OpenDerisk) - - -采用多Agent架构,目前代码中主要实现了绿色部分部分,告警感知采用的是微软开源的[OpenRCA数据集](https://github.com/microsoft/OpenRCA), 数据集的大小解压后在26G左右,我们实现在26G的数据集合上,通过多Agent协同,Code-Agent动态写代码来进行最终根因的分析诊断。 +#### 项目介绍 +系统采用多 Agent 架构,目前代码主要实现了高亮部分。告警感知基于微软开源的 [OpenRCA 数据集](https://github.com/microsoft/OpenRCA),数据集解压后约 26GB。在该数据集上,我们通过多 Agent 协同实现根因分析诊断,Code-Agent 动态编写代码进行最终分析。 #### 技术实现 -1. 数据层: 拉取Github OpenRCA的大规模数据集(20G), 解压本地处理分析。 -2. 逻辑层:Multi-Agent架构, 通过SRE-Agent、Code-Agent、ReportAgent、VisAgent、Data-Agent协同合作,进行深度的DeepResearch RCA(Root Cause Analyze) -3. 可视化层: 采用Vis协议、动态渲染整个处理流程与证据链, 以及多角色协同切换的过程。 +1. **数据层**: 从 GitHub 拉取大规模 OpenRCA 数据集 (20GB),本地解压处理分析。 +2. **逻辑层**: Multi-Agent 架构,通过 SRE-Agent、Code-Agent、ReportAgent、VisAgent、Data-Agent 协同合作,进行深度的 DeepResearch RCA (Root Cause Analysis) 根因分析。 +3. **可视化层**: 采用 Vis 协议动态渲染整个处理流程与证据链,以及多角色协同切换的过程。 -4. OpenDeRisk中的数字员工(Agent) +OpenDeRisk 中的数字员工 (Agent)

+### 安装(推荐) + +#### 使用 curl 安装 -#### 快速启动 -##### 1.open-derisk服务启动 - - Install uv - ```sh - curl -LsSf https://astral.sh/uv/install.sh | sh - ``` - - 依赖安装 - ``` - uv sync --all-packages --frozen \ - --extra "base" \ - --extra "proxy_openai" \ - --extra "rag" \ - --extra "storage_chromadb" \ - --extra "derisks" \ - --extra "storage_oss2" \ - --extra "client" \ - --extra "ext_base" - ``` - - 配置启动参数 - ``` - > 配置`derisk-proxy-aliyun.toml`文件中相关的API_KEY, 然后运行下面的命令启动。 - > 也可参考 `derisk-proxy-aliyun.toml` 文件中的配置使用全阿里云模型和oss方案 - > ** 注意 ** 最好在全新的环境下启动0.2版本,不然可能被0.1旧数据影响导致启动失败. - ``` - - 启动服务 - ``` - uv run python packages/derisk-app/src/derisk_app/derisk_server.py --config configs/derisk-proxy-aliyun.toml - ``` - - 服务访问 - > 打开浏览器访问 [`http://localhost:7777`](http://localhost:7777) - - -##### 2.内置场景快速使用 -* AI-SRE(OpenRca根因定位) - - !注意, 我们默认使用OpenRCA数据集中的[Bank数据集](https://drive.usercontent.google.com/download?id=1enBrdPT3wLG94ITGbSOwUFg9fkLR-16R&export=download&confirm=t&uuid=42621058-41af-45bf-88a6-64c00bfd2f2e), - - 你可以通过链接, 或者下述命令进行下载: - ``` - gdown https://drive.google.com/uc?id=1enBrdPT3wLG94ITGbSOwUFg9fkLR-16R - ``` - - 下载完成后, 将数据解压到 ${derisk项目}/pilot/datasets。 -* 火焰图助手 - - 使用你本地应用服务进程的火焰图(java/python)上传给助手提问分析 -* DataExpert - - 上传你的指标、日志、trace等各种Excel表格数据进行对话分析 -##### 3.快速开发 -* Agent开发 - 参考derisk-ext.agent.agents下的实现逻辑 -* 工具开发 - * local tool - * mcp -* 其他开发 - 文档准备中.... - -* DeRisk-Skills 开发 +```shell +# 下载并安装最新版本 +curl -fsSL https://raw.githubusercontent.com/derisk-ai/OpenDerisk/main/install.sh | bash +``` + +#### 配置文件 +安装完成后,需要配置系统。创建配置文件: +编辑 `~/.openderisk/derisk-proxy-aliyun.toml` 并设置您的 API 密钥。 + +#### 启动 +``` +openderisk-server +``` + +### 从源码安装(开发环境) + +安装 uv(必需): +```shell + +git clone https://github.com/derisk-ai/OpenDerisk.git + +cd OpenDerisk + +# 安装依赖 +sh scripts/prepare_release.sh +``` + +#### 启动服务 + +在 `derisk-proxy-aliyun.toml` 中配置 API_KEY,然后运行: + +> 注意:默认使用 OpenRCA 的 Telecom 数据集。通过以下链接或命令下载: +> `gdown https://drive.google.com/uc?id=1cyOKpqyAP4fy-QiJ6a_cKuwR7D46zyVe` + +下载后,将数据集移动到 `pilot/datasets/` 目录。 + +运行启动命令: +```bash +uv run python packages/derisk-app/src/derisk_app/derisk_server.py --config configs/derisk-proxy-aliyun.toml +``` + +#### 访问 Web 界面 + +打开浏览器访问 [`http://localhost:7777`](http://localhost:7777) + +##### 2. 内置场景快速使用 +* **AI-SRE (OpenRCA 根因定位)** + - 注意: 默认使用 OpenRCA 数据集中的 [Bank 数据集](https://drive.usercontent.google.com/download?id=1enBrdPT3wLG94ITGbSOwUFg9fkLR-16R&export=download&confirm=t&uuid=42621058-41af-45bf-88a6-64c00bfd2f2e) + - 下载命令: `gdown https://drive.google.com/uc?id=1enBrdPT3wLG94ITGbSOwUFg9fkLR-16R` + - 下载后解压到 `${derisk项目}/pilot/datasets` +* **火焰图助手** + - 上传本地应用服务进程的火焰图 (Java/Python) 进行分析 +* **DataExpert** + - 上传指标、日志、Trace 等各种 Excel 表格数据进行对话分析 + +##### 3. 快速开发 +* **Agent 开发** + - 参考 `derisk-ext.agent.agents` 下的实现逻辑 +* **工具开发** + - Skills + - MCP (Model Context Protocol) +* **DeRisk-Skills 开发** - [derisk-skills](https://github.com/derisk-ai/derisk_skills) #### 运行效果 -如下图所示, 为多智能体协同运行处理一个复杂的运维诊断任务的场景。 +多智能体协同处理复杂运维诊断任务场景:

-### RoadMap -- [x] 0530 V0.1版本,基于领域知识与MCP服务,实现从异动感知 -> 自主决策 -> 自适应执行与问题处理。 - - [x] 技术风险领域知识引擎 - - [x] 基于大模型推理驱动的异动感知 -> 决策 -> 执行推理引擎 - - [x] 自动TroubleShooting与Fix - -- [ ] 0830 V0.2版本 - - [x] 技术风险领域MCP服务与管理 - - [x] 支持自定义绑定知识与MCP工具 - - [x] 支持3+ DevOps领域MCP服务 - -- [ ] 0930 V0.3 - - [ ] 支持对接生产环境 - - [ ] 提供完整的生产环境部署解决方案,支持生产问题诊断。 - -- [ ] 1230 V0.4 - - [ ] 端到端AIOps在线Agentic RL - - [ ] 端到端评测能力 - ### 引用 - -针对此仓库中的代码, 我们通过如下的Paper进行了详细的介绍, 如果发现对你的工作有帮助, 请引用它。 +如对您的工作有帮助,请引用以下论文: ``` @misc{di2025openderiskindustrialframeworkaidriven, title={OpenDerisk: An Industrial Framework for AI-Driven SRE, with Design, Implementation, and Case Studies}, @@ -168,16 +153,15 @@ OpenDeRisk AI 原生风险智能系统 —— 7\*24H 应用系统AI数字运维 - [MetaGPT](https://github.com/FoundationAgents/MetaGPT) - [OpenRCA](https://github.com/microsoft/OpenRCA) -OpenDeRisk-AI 社区致力于构建 AI 原生的风险智能系统。🛡️ 我们希望我们的社区能够为您提供更好的服务,同时也希望您能加入我们,共同创造更美好的未来。🤝 +OpenDeRisk-AI 社区致力于构建 AI 原生的风险智能系统。🛡️ 我们希望社区能够为您提供更好的服务,同时也期待您的加入,共同创造更美好的未来。🤝 [![Star History Chart](https://api.star-history.com/svg?repos=derisk-ai/OpenDerisk&type=Date)](https://star-history.com/#derisk-ai/OpenDerisk) - ### 社区 -加入钉钉群, 与我们一起交流讨论。 +加入钉钉群,与我们一起交流讨论:
OpenDeRisk-AI 交流群 -
+ \ No newline at end of file diff --git a/assets/schema/derisk.sql b/assets/schema/derisk.sql index fb9a68fd..1f1892b3 100644 --- a/assets/schema/derisk.sql +++ b/assets/schema/derisk.sql @@ -9,6 +9,7 @@ use derisk; -- MySQL DDL Script for Derisk -- Version: 0.3.0 -- Generated from SQLAlchemy ORM Models + -- Generated: 2026-02-28 13:57:50 -- ============================================================ diff --git a/docs/README.md b/docs/README.md index 0e0fd0cb..b6b0c809 100755 --- a/docs/README.md +++ b/docs/README.md @@ -1,18 +1,55 @@ -# DeRisk documentation +# OpenDerisk Documentation + +Documentation site for OpenDeRisk built with Docusaurus. ## Quick Start -### Install dependencies -- Clone current project firstly! -- Install docusaurus dependencies, generate node_modules folder. +### Prerequisites +- Clone the project first! -``` +### Install Dependencies +```bash yarn install ``` -### launch -``` +### Launch Development Server +```bash yarn start ``` -The default service starts on port `3000`, visit `localhost:3000` +The default service starts on port `3000`. Visit `http://localhost:3000` + +## Building for Production + +```bash +yarn build +``` + +The built static files will be in the `build` directory. + +## Documentation Structure + +``` +docs/ +├── docs/ # Actual documentation content +│ ├── overview.md +│ ├── getting-started.md +│ └── ... +├── sidebars.js # Sidebar configuration +├── docusaurus.config.js # Docusaurus configuration +└── package.json +``` + +## Contributing + +When contributing to the documentation: + +1. Follow the existing markdown style +2. Add appropriate sidebar entries +3. Test the changes locally before submitting + +## More Information + +- [OpenDerisk Main Documentation](../README.md) +- [Docusaurus Documentation](https://docusaurus.io/) +- [DeepWiki](https://deepwiki.com/derisk-ai/OpenDerisk) \ No newline at end of file diff --git a/npm/README.md b/npm/README.md index 2fd52737..b8f4d8ae 100644 --- a/npm/README.md +++ b/npm/README.md @@ -8,14 +8,14 @@ NPM wrapper for OpenDeRisk AI-Native Risk Intelligence Systems. npm install -g openderisk ``` -Or use with npx (no installation): +Or use with npx (no installation required): ```bash npx openderisk ``` ## Usage -### CLI +### CLI Commands ```bash # Show help @@ -31,7 +31,7 @@ openderisk-server openderisk --update ``` -### Requirements +## Requirements - Node.js >= 16.0.0 - Python >= 3.10 (will be installed automatically) @@ -53,4 +53,4 @@ OpenDeRisk is an AI-Native Risk Intelligence System that provides: ## License -MIT +MIT \ No newline at end of file diff --git a/packages/derisk-app/README.md b/packages/derisk-app/README.md index 79d40738..b6ad5076 100644 --- a/packages/derisk-app/README.md +++ b/packages/derisk-app/README.md @@ -1,3 +1,48 @@ # derisk-app +Main application package for OpenDeRisk. +## Overview + +`derisk-app` is the main application package that provides the OpenDeRisk server and web interface. It integrates all the core components and extensions to provide a complete AI-SRE solution. + +## Features + +- **Web Server**: FastAPI-based REST API server +- **Web UI**: Next.js based chat interface +- **Static Assets**: Pre-built web assets for deployment + +## Installation + +```bash +uv sync --all-packages --frozen +``` + +## Quick Start + +1. Configure the API_KEY in your config file (e.g., `derisk-proxy-aliyun.toml`) +2. Run the server: +```bash +uv run python packages/derisk-app/src/derisk_app/derisk_server.py --config configs/derisk-proxy-aliyun.toml +``` +3. Access the web UI at http://localhost:7777 + +## Project Structure + +``` +packages/derisk-app/ +├── src/derisk_app/ +│ ├── static/web/ # Pre-built web assets +│ ├── derisk_server.py # Main server entry +│ └── ... +└── pyproject.toml +``` + +## Documentation + +- [OpenDerisk Main Documentation](../README.md) +- [DeepWiki](https://deepwiki.com/derisk-ai/OpenDerisk) + +## License + +MIT \ No newline at end of file diff --git a/packages/derisk-app/src/derisk_app/app.py b/packages/derisk-app/src/derisk_app/app.py index 56ff0076..effc1e78 100644 --- a/packages/derisk-app/src/derisk_app/app.py +++ b/packages/derisk-app/src/derisk_app/app.py @@ -49,7 +49,7 @@ def load_config(config_file: str = None) -> ApplicationConfig: if config_file is None: config_file = os.path.join( - DERISK_ROOT_PATH, "configs", "derisk-siliconflow.toml" + DERISK_ROOT_PATH, "configs", "derisk-proxy-aliyun.toml" ) elif not os.path.isabs(config_file): # If config_file is a relative path, make it relative to DERISK_ROOT_PATH diff --git a/packages/derisk-client/README.md b/packages/derisk-client/README.md index af41a6f1..3c28acc6 100644 --- a/packages/derisk-client/README.md +++ b/packages/derisk-client/README.md @@ -1,3 +1,40 @@ # derisk-client -Describe your project here. +Python client library for OpenDeRisk. + +## Overview + +`derisk-client` provides a Python SDK for interacting with OpenDeRisk services. It allows developers to integrate OpenDeRisk's AI-SRE capabilities into their own applications. + +## Features + +- **REST API Client**: Easy-to-use Python client for OpenDeRisk services +- **Async Support**: Full async/await support +- **Type Hints**: Comprehensive type annotations for IDE support + +## Installation + +```bash +pip install derisk-client +``` + +## Usage + +```python +from derisk_client import OpenDeriskClient + +# Create a client +client = OpenDeriskClient(base_url="http://localhost:7777") + +# Use the client +result = await client.analyze_issue(...) +``` + +## Documentation + +- [OpenDerisk Main Documentation](../README.md) +- [GitHub Repository](https://github.com/derisk-ai/OpenDerisk) + +## License + +MIT \ No newline at end of file diff --git a/packages/derisk-core/README.md b/packages/derisk-core/README.md index ccb6fd43..8b4546cb 100644 --- a/packages/derisk-core/README.md +++ b/packages/derisk-core/README.md @@ -1,3 +1,54 @@ # derisk-core -Package that contains modules and utilities that can be used across packages and services. \ No newline at end of file +Core package for OpenDeRisk AI-Native Risk Intelligence System. + +## Overview + +`derisk-core` is the foundational package that contains core modules and utilities used across all OpenDeRisk packages and services. It provides the fundamental infrastructure for building AI-driven SRE (Site Reliability Engineering) applications. + +## Features + +- **Multi-Agent Architecture**: Framework for building collaborative AI agents (SRE-Agent, Code-Agent, ReportAgent, Vis-Agent, Data-Agent) +- **ReAct Master Agent**: Advanced reasoning agent with doom loop detection, session compaction, and output truncation +- **Model Proxy**: Support for multiple LLM providers (OpenAI, Anthropic, Azure, etc.) +- **AWEL Operators**: Rich set of operators for building AI workflows +- **Data Processing**: Tools for processing logs, traces, and metrics + +## Installation + +```bash +# From source +uv sync --all-packages --frozen +``` + +## Dependencies + +Key dependencies include: +- `aiohttp` - Async HTTP client +- `pydantic` - Data validation +- `SQLAlchemy` - Database ORM +- `duckdb` - Embedded analytical database +- `uvicorn` - ASGI server + +Optional dependencies: +- `agent` - Agent-related functionality +- `framework` - Full framework features +- `hf` - HuggingFace integration +- `code` - Code execution support + +## Usage + +```python +from derisk import ... + +# Build your AI-SRE application +``` + +## Documentation + +- [OpenDerisk Documents](https://deepwiki.com/derisk-ai/OpenDerisk) +- [GitHub Repository](https://github.com/derisk-ai/OpenDerisk) + +## License + +MIT \ No newline at end of file diff --git a/packages/derisk-ext/README.md b/packages/derisk-ext/README.md index 08144eac..b7016822 100644 --- a/packages/derisk-ext/README.md +++ b/packages/derisk-ext/README.md @@ -1,3 +1,65 @@ -# derisk-integration +# derisk-ext -Package that contains modules and utilities that can be used across packages and services. +Extension package for OpenDeRisk with additional tools and integrations. + +## Overview + +`derisk-ext` provides extended functionality for OpenDeRisk, including: + +- **Sandbox**: Secure code execution environment with isolation +- **RAG**: Retrieval-Augmented Generation support +- **MCP Gateway**: Model Context Protocol gateway +- **Data Sources**: Connectors for various databases +- **Storage**: Support for vector stores (ChromaDB, Milvus, etc.) + +## Features + +### Local Sandbox +- Security isolation using platform-specific mechanisms (sandbox-exec on macOS, prlimit on Linux) +- Real browser automation with Playwright +- Resource limits (memory, CPU, network) + +### RAG Pipeline +- Document processing (PDF, Word, Excel, PPT) +- Text chunking and embedding +- Vector storage and retrieval + +### MCP Services +- MCP Gateway for managing MCP tools +- Pre-built DevOps domain MCP services +- Custom MCP tool binding + +## Installation + +```bash +uv sync --all-packages --frozen --extra "ext_base" +``` + +Additional extras: +- `rag` - RAG functionality +- `storage_chromadb` - ChromaDB storage +- `storage_milvus` - Milvus storage +- `datasource_mysql` - MySQL connector +- `mcp_gateway` - MCP gateway + +## Usage + +```python +from derisk_ext.sandbox.local import LocalSandbox + +# Create a sandbox +sandbox = await LocalSandbox.create(user_id="user", agent="agent") + +# Run code +result = await sandbox.run_code("print('Hello, World!')") +``` + +## Documentation + +- [Local Sandbox Documentation](./src/derisk_ext/sandbox/local/README.md) +- [OpenDerisk Main Documentation](../README.md) +- [DeepWiki](https://deepwiki.com/derisk-ai/OpenDerisk) + +## License + +MIT \ No newline at end of file diff --git a/packages/derisk-serve/README.md b/packages/derisk-serve/README.md index 0578d45b..598fa0e3 100644 --- a/packages/derisk-serve/README.md +++ b/packages/derisk-serve/README.md @@ -1,3 +1,52 @@ # derisk-serve -Describe your project here. +Backend service package for OpenDeRisk. + +## Overview + +`derisk-serve` provides the backend API services for OpenDeRisk, including: + +- **Agent Services**: Multi-agent collaboration and management +- **Conversation Management**: Chat session handling +- **Knowledge Management**: RAG-based knowledge retrieval +- **Data Source Management**: Database and data source connections +- **Skill Management**: Agent skill registration and execution +- **Flow Management**: Workflow orchestration + +## Features + +- **RESTful APIs**: Comprehensive API endpoints for all services +- **Async Support**: Full async/await architecture +- **Database Integration**: Support for MySQL, PostgreSQL, DuckDB +- **Vector Storage**: ChromaDB, Milvus, Weaviate integration + +## Installation + +```bash +uv sync --all-packages --frozen +``` + +## Project Structure + +``` +packages/derisk-serve/ +├── src/derisk_serve/ +│ ├── agent/ # Agent services +│ ├── conversation/ # Conversation management +│ ├── datasource/ # Data source connections +│ ├── derisks/ # Risk management +│ ├── memory/ # Memory services +│ ├── skill/ # Skill management +│ ├── flow/ # Flow orchestration +│ └── ... +└── pyproject.toml +``` + +## Documentation + +- [OpenDerisk Main Documentation](../README.md) +- [DeepWiki](https://deepwiki.com/derisk-ai/OpenDerisk) + +## License + +MIT \ No newline at end of file diff --git a/web/README.md b/web/README.md index 3153525a..67e38260 100644 --- a/web/README.md +++ b/web/README.md @@ -1,33 +1,39 @@ -## 👋 Introduction +# OpenDerisk Web -[DERISK Web] is an Open source Tailwind and Next.js based chat UI for AI and GPT projects. It beautify a lot of markdown labels, such as `table`, `thead`, `th`, `td`, `code`, `h1`, `h2`, `ul`, `li`, `a`, `img`. Also it define some custom labels to adapted to AI-specific scenarios. Such as `plugin running`, `knowledge name`, `Chart view`, and so on. +Web UI for OpenDeRisk AI-Native Risk Intelligence System. -## 💪🏻 Getting Started +## Introduction -### Prerequisites +OpenDerisk Web is an open-source Next.js and Tailwind CSS based chat UI for AI and GPT projects. It provides a beautiful markdown rendering for various elements including tables, code blocks, headers, lists, images, and more. It also includes custom components for AI-specific scenarios such as plugin running, knowledge visualization, and chart views. + +## Prerequisites - [Node.js](https://nodejs.org/) >= 18.18 - [npm](https://npmjs.com/) >= 10 - [yarn](https://yarnpkg.com/) >= 1.22 -- Supported OSes: Linux, macOS and Windows +- Supported OSes: Linux, macOS, and Windows -### Installation +## Installation -```sh +```bash # Install dependencies npm install +# or yarn install ``` -### Usage -```sh +## Configuration + +```bash cp .env.template .env ``` -edit the `NEXT_PUBLIC_API_BASE_URL` to the real address +Edit the `NEXT_PUBLIC_API_BASE_URL` to point to your OpenDerisk server address. -```sh -# development model +## Development + +```bash +# Start development server npm run dev # or yarn dev @@ -37,22 +43,36 @@ pnpm dev bun dev ``` -Open [http://localhost:3000](http://localhost:3000) with your browser to see the result. +Open [http://localhost:3000](http://localhost:3000) in your browser. + +## Building for Production -### Packaging static files +```bash +cd web +yarn build +cp -r out/* ../packages/derisk-app/src/derisk_app/static/web/ ``` -1. cd web -2. yarn build +## Adding New Vis Components -3. cp -r out/* ../packages/derisk-app/src/derisk_app/static/web/ -``` +To add a new visual component: + +1. Create a new file in `components/chat-content-components/VisComponents` +2. Implement the component using React and necessary libraries +3. Update the `visComponentsRender` object in `config.tsx` to include your new component + +## Tech Stack + +- Next.js +- Tailwind CSS +- React +- TypeScript +## Documentation -### Add New Vis Components +- [OpenDerisk Main Documentation](../README.md) +- [DeepWiki](https://deepwiki.com/derisk-ai/OpenDerisk) -To add a new visual component, follow these steps: +## License -1. Create a new file for your component in the `components/chat-content-components/VisComponents` directory. -2. Implement the component using React and any necessary libraries. -3. Update the `visComponentsRender` object in `config.tsx` to include your new component. +MIT \ No newline at end of file