joelcedric2/sentinel
GitHub: joelcedric2/sentinel
一个覆盖非洲大陆的开源 OSINT 实时情报监测平台,融合冲突、火灾、航班、卫星等多源数据并提供 AI 驱动的分析。
Stars: 0 | Forks: 0
# SENTINEL
**现有的情报工具是为北约国家构建的。Sentinel 覆盖非洲——火灾预测、冲突监测、卫星跟踪、AI 分析——开源且任何人都可以部署。**
使用 React、TypeScript 和 CesiumJS 构建的实时 OSINT 平台。覆盖全大陆的多源情报融合:冲突事件、新闻源、NASA 火灾数据、卫星跟踪、实时航班、摄像头源,以及 AI 驱动的威胁分析。支持双语(英语/法语)。
## 功能
- **3D 地球仪** — CesiumJS 结合 Google 逼真 3D Tiles,支持街道级缩放,7 种视图模式(标准、CRT、NVG、FLIR、模拟、Noir、雪景)
- **威胁情报** — 4 源融合:UCDP 冲突事件、50+ 新闻 RSS 源、GDELT 媒体监测、UN OCHA ReliefWeb 报告
- **火灾预测** — NASA FIRMS 双源(VIIRS + MODIS)、Open-Meteo 火灾天气指数、NDVI 植被干燥度、Copernicus GWIS 预测
- **AI 情报引擎** — 6 家提供商(Anthropic、OpenAI、OpenRouter、DeepSeek、Kimi 2.5、Ollama),多模态视觉分析,全量数据融合预测
- **实时航班** — 通过 adsb.lol + airplanes.live 进行 ADS-B 跟踪,航线丰富(AirLabs、ADSBdb、OpenSky)
- **卫星跟踪** — 通过 CelesTrak TLE + SGP4 推演跟踪 24 颗卫星
- **摄像头源** — HLS 直播流 + 快照轮询,AI 异常检测
- **资产监控** — 在地球仪上标记资产并设置监控半径,提供每小时自动 AI 威胁简报
- **警报** — 可配置的电子邮件/webhook 警报规则,支持威胁评分阈值
- **PDF 导出** — 包含威胁评分、预测、摄像头观测结果和时间模式的情报简报
- **双语** — 完整的英语/法语支持
## 前置条件
- **Node.js** >= 18
- **npm** >= 9
## 快速开始
```
# 克隆 repo
git clone https://github.com/YOUR_USERNAME/sentinel.git
cd sentinel
# 安装 dependencies
npm install
# 复制 environment template
cp .env.example .env
# 编辑 .env 并添加你的 API keys(见下文)
# 启动 dev server
npm run dev
```
应用程序将在 `http://localhost:5173` 上可用。
## 环境变量
将 `.env.example` 复制到 `.env` 并填入相应的值。应用程序具有三个级别的 API 密钥:
### 必需(核心功能)
| 变量 | 服务 | 获取方式 | 启用的功能 |
|----------|---------|------------|-----------------|
| `VITE_CESIUM_TOKEN` | [Cesium Ion](https://ion.cesium.com) | 免费注册,创建一个 token | 使用 Google 逼真 Tiles 的 3D 地球仪 |
### 推荐(主要功能)
| 变量 | 服务 | 获取方式 | 启用的功能 |
|----------|---------|------------|-----------------|
| `VITE_AIRLABS_API_KEY` | [AirLabs](https://airlabs.co) | 免费注册(每月 1,000 次请求) | 非洲/欧洲地区的航班航线丰富 |
| `VITE_UCDP_TOKEN` | [UCDP](https://ucdpapi.pcr.uu.se) | 发送邮件至 mertcan.yilmaz@pcr.uu.se(免费) | 冲突事件图层(武装暴力数据) |
### 可选(后端 / 高级功能)
| 变量 | 服务 | 作用 |
|----------|---------|--------------|
| `VITE_ANTHROPIC_CLIENT_ID` | Anthropic | OAuth 登录流程(实验性) |
| `VITE_ALERT_ENDPOINT` | 你的 Cloudflare Worker | 电子邮件/webhook 警报发送 |
| `VITE_ALERT_SECRET` | — | 用于 Alert Worker 认证的共享密钥 |
| `VITE_API_GATEWAY_URL` | 你的 Cloudflare Worker | 生产环境 API 网关(本地开发请留空) |
### 无需 API 密钥(免费/开放 API)
这些数据源开箱即用,无需任何配置:
- **adsb.lol / airplanes.live** — ADS-B 航班位置
- **ADSBdb / OpenSky** — 航班航线丰富(美洲、亚洲)
- **NASA FIRMS** — 活跃火灾(VIIRS + MODIS)
- **NASA GIBS** — NDVI 植被切片 + 卫星图像
- **Open-Meteo** — 火灾天气(温度、湿度、土壤水分、风速、FWI)
- **Copernicus GWIS** — 火灾危险预测叠加层
- **USGS** — 实时地震信息
- **RainViewer** — 气象雷达叠加层
- **GDELT** — 媒体监测 + 地理定位
- **ReliefWeb** — UN OCHA 人道主义报告
- **rss2json** — 将 50+ 新闻源的 RSS 转换为 JSON
- **Nominatim** — OpenStreetMap 地理编码
- **CelesTrak** — 卫星 TLE 数据
### AI 提供商
AI 功能在应用程序内配置(不通过环境变量)。打开 AI 面板并输入任意提供商的 API 密钥:
| 提供商 | 获取密钥的地址 | 备注 |
|----------|-------------------|-------|
| [Anthropic Claude](https://console.anthropic.com) | console.anthropic.com | 支持多模态视觉 |
| [OpenAI GPT](https://platform.openai.com) | platform.openai.com | 支持多模态视觉 |
| [OpenRouter](https://openrouter.ai) | openrouter.ai | 300+ 种模型(Claude、GPT、Llama 等) |
| [DeepSeek](https://platform.deepseek.com) | platform.deepseek.com | — |
| [Kimi 2.5](https://platform.moonshot.cn) | platform.moonshot.cn | — |
| [Ollama](https://ollama.com) | 本地安装,无需密钥 | 在本地运行模型 |
## 命令
```
npm run dev # Start dev server (localhost:5173)
npm run build # Production build (type-check + bundle)
npm run preview # Preview production build
npm run test # Run unit tests (Vitest)
npm run test:e2e # Run end-to-end tests (Playwright)
npm run lint # Lint with ESLint
```
## 技术栈
| 层级 | 技术 |
|-------|-----------|
| 框架 | React 19 + TypeScript + Vite 7 |
| 3D 地球仪 | CesiumJS + Resium |
| 样式 | Tailwind CSS 4 |
| 视频 | hls.js (HLS streams) |
| 卫星计算 | satellite.js (SGP4 propagation) |
| PDF 导出 | jsPDF |
| 图表 | Recharts |
| Markdown | react-markdown |
| 测试 | Vitest + Playwright |
| 后端 | Cloudflare Workers (API Gateway, AI Proxy, Alert Worker) |
| 数据库 | Cloudflare D1 (SQLite) + KV |
## 架构
```
src/
App.tsx # Root layout
components/
AI/ # Intelligence engine UI (dashboard, chat, predictions, camera analysis)
Alerts/ # Alert rules + toast notifications
Assets/ # Asset monitoring (registration, briefs, history)
Feeds/ # Camera/sensor feed management + video player
Globe/GlobeViewer.tsx # CesiumJS globe with all overlays
HUD/TopBar.tsx # Classification banner, status indicators
Navigation/BottomBar.tsx # Region/country navigation
Search/SearchBar.tsx # Location search with autocomplete
Sidebar/ # Left panel (layers/feeds/assets) + Right panel (threat bars)
Threats/ # Threat drawer + feed + event cards
services/
ai/ # Multi-provider AI (streaming, vision, data fusion, threat scoring)
alerts/ # Alert rule engine + dispatch
assets/ # Asset CRUD + briefing engine
layers/ # 13+ data layers (flights, fires, conflicts, satellites, weather, etc.)
threats/ # Threat aggregation + notifications
export/ # PDF intelligence briefing export
data/
regions.ts # Regions, countries, layers, UI strings (EN/FR)
cities.ts # 180+ searchable locations
conflictLocations.ts # 784 sub-national conflict locations for geo-location
backend/
api-gateway/ # Cloudflare Worker — production API proxy
ai-proxy/ # Cloudflare Worker — AI provider proxy
alert-worker/ # Cloudflare Worker — email/webhook alerts
ingestion/ # Cloudflare Worker — data ingestion
event-processor/ # Cloudflare Worker — event processing
```
## 后端 (Cloudflare Workers)
后端 Worker 对于本地开发是可选的 —— Vite 的开发服务器会直接代理所有 API 请求。关于生产环境部署:
```
cd backend/api-gateway
npx wrangler secret put AIRLABS_API_KEY
npx wrangler secret put UCDP_TOKEN
npx wrangler deploy
cd backend/ai-proxy
npx wrangler secret put ANTHROPIC_API_KEY
npx wrangler secret put OPENAI_API_KEY
npx wrangler secret put DEEPSEEK_API_KEY
npx wrangler secret put OPENROUTER_API_KEY
npx wrangler deploy
```
## 许可证
MIT
标签:3D地球, AI分析, React, Syscalls, TypeScript, 威胁情报, 安全插件, 开发者工具, 特征检测, 程序员工具, 自动化攻击