LLM Proxy Skill

LLM API 代理服务,统一管理多个 LLM Provider,支持内容安全审计。

3,891 stars

Best use case

LLM Proxy Skill is best used when you need a repeatable AI agent workflow instead of a one-off prompt.

LLM API 代理服务,统一管理多个 LLM Provider,支持内容安全审计。

Teams using LLM Proxy Skill should expect a more consistent output, faster repeated execution, less prompt rewriting.

When to use this skill

  • You want a reusable workflow that can be run more than once with consistent structure.

When not to use this skill

  • You only need a quick one-off answer and do not need a reusable workflow.
  • You cannot install or maintain the underlying files, dependencies, or repository context.

Installation

Claude Code / Cursor / Codex

$curl -o ~/.claude/skills/llm-proxy/SKILL.md --create-dirs "https://raw.githubusercontent.com/openclaw/skills/main/skills/394286006/llm-proxy/SKILL.md"

Manual Installation

  1. Download SKILL.md from GitHub
  2. Place it in .claude/skills/llm-proxy/SKILL.md inside your project
  3. Restart your AI agent — it will auto-discover the skill

How LLM Proxy Skill Compares

Feature / AgentLLM Proxy SkillStandard Approach
Platform SupportNot specifiedLimited / Varies
Context Awareness High Baseline
Installation ComplexityUnknownN/A

Frequently Asked Questions

What does this skill do?

LLM API 代理服务,统一管理多个 LLM Provider,支持内容安全审计。

Where can I find the source code?

You can find the source code on GitHub using the link provided at the top of the page.

Related Guides

SKILL.md Source

# LLM Proxy Skill

LLM API 代理服务,统一管理多个 LLM Provider,支持内容安全审计。

## 功能

- 多 Provider 统一代理(22+ 提供商)
- 内容安全审计(恶意指令检测、敏感内容过滤)
- 流式响应实时检测
- 健康状态监控

---

## 使用方法

### 启动代理

```
启动llm-proxy
```

### 停止代理

```
停止llm-proxy
```

### 查看状态

```
llm-proxy状态
```

### 重启代理

```
重启llm-proxy
```

---

## 手动操作

进入 skill 目录后执行:

### 启动

```bash
./scripts/llm-proxy-ctl.sh start
```

### 停止

```bash
./scripts/llm-proxy-ctl.sh stop
```

### 状态

```bash
./scripts/llm-proxy-ctl.sh status
```

### 重启

```bash
./scripts/llm-proxy-ctl.sh restart
```

---

## 配置说明

配置文件:`scripts/llm-proxy-config.json`

### 基本配置

| 字段 | 默认值 | 说明 |
|------|--------|------|
| `listen_host` | `127.0.0.1` | 监听地址 |
| `proxy_port` | `18888` | 代理端口 |
| `read_timeout` | `60` | 读取超时(秒) |
| `max_body_size_mb` | `10` | 最大请求体(MB) |
| `max_threads` | `50` | 最大线程数 |

### 安全检测配置

| 配置项 | 说明 |
|--------|------|
| `rules_file` | 内容过滤规则文件 |
| `quick_check_keywords` | 快速检测关键词列表 |

### 修改端口

编辑 `llm-proxy-config.json` 中的 `proxy_port` 字段,重启服务生效。

---

## 支持的 Provider

### 免费/免费额度

- `ollama` - 本地 Ollama
- `gemini` - Google Gemini
- `groq` - Groq
- `cloudflare` - Workers AI
- `deepseek` - DeepSeek
- `moonshot` - 月之暗面
- `zhipu` - 智谱
- `siliconflow` - SiliconFlow

### 付费

- `openai` - OpenAI
- `anthropic` - Anthropic
- `openrouter` - OpenRouter
- `nvd` - NVIDIA NIM
- `bailian` - 阿里百炼
- `baidu` - 百度文心
- `spark` - 讯飞星火
- `minimax` - MiniMax
- `yi` - 零一万物
- `baichuan` - 百川
- `together` - Together AI
- `fireworks` - Fireworks AI
- `replicate` - Replicate

---

## 健康检查

```bash
curl http://127.0.0.1:18888/health
```

响应示例:

```json
{
  "status": "ok",
  "uptime": 3600,
  "rules_loaded": {
    "layer1": 10,
    "layer2": 7,
    "whitelist": 6
  },
  "stats": {
    "total_requests": 100,
    "total_responses": 98,
    "blocked": 0,
    "errors": 2
  }
}
```

---

## 安全检测机制

### 三层审核

1. **L1 - 恶意指令检测**:危险命令、提权操作、SQL注入、后门等
2. **L2 - 敏感内容检测**:个人身份信息、凭证密钥、违法内容
3. **快速关键词检测**:流式响应实时检测风险关键词

### 流式响应检测

- 每 100 字符检测一次
- 发现风险关键词时注入警告提醒
- 严重违规时阻断响应

### 自定义关键词

编辑 `llm-proxy-config.json` 中的 `quick_check_keywords` 数组添加新关键词。

---

## 日志

日志目录:`~/.openclaw/logs/llm-proxy/`

- `proxy-YYYY-MM-DD.jsonl` - 请求日志
- `ctl-service.log` - 服务日志(手动启动时)

---

## 注意事项

- 默认端口 `18888`
- 仅监听本地 `127.0.0.1`
- 无自动监控,需手动管理
- 修改配置后需重启服务

Related Skills

azure-proxy

3891
from openclaw/skills

Enable Azure OpenAI integration with OpenClaw via a lightweight local proxy. Use when configuring Azure OpenAI as a model provider, when encountering 404 errors with Azure OpenAI in OpenClaw, or when needing to use Azure credits (e.g. Visual Studio subscription) with OpenClaw subagents. Solves the api-version query parameter issue that prevents direct Azure OpenAI integration.

cliproxy-media

3891
from openclaw/skills

Analyze images (jpg, png, gif, webp) and PDFs via CLIProxyAPI — a Claude Max proxy that routes requests through your subscription at zero extra cost. Use this skill whenever you need to analyze, describe, or extract information from an image or photo ("analyze image", "describe photo", "what is in this picture"), read or summarize a PDF document ("read PDF", "summary of this document"), or process any media file via a CLIProxy-compatible endpoint ("process media via proxy", "cliproxy vision", "cliproxy media"). NEVER use the built-in `image` or `pdf` tools when using CLIProxyAPI — they fall back to direct Anthropic API which requires separate credits. Use this skill instead for all vision and document analysis tasks.

cpa-codex-auth-sweep-cliproxy

3891
from openclaw/skills

通过 CLI Proxy Management API 拉取 Codex 认证文件并高并发探活扫描。适用于「扫号」「清死号」「清理 Codex 401」场景;仅在用户明确确认后可删除 401。执行前必须提供 base_url 与 management_key。安全限制:默认仅允许 https://chatgpt.com 作为 probe 主机,非白名单目标需显式危险确认。

cliproxy-openclaw

3891
from openclaw/skills

Deploy and configure CLIProxyAPI, expose its dashboard safely, connect OAuth providers like Claude Code, Gemini, Codex, Qwen, and iFlow, generate a reusable API endpoint and API key, and integrate it with OpenClaw or other OpenAI-compatible tools. Use when the user wants one API layer from subscription-based CLI or OAuth accounts, multi-account routing, or CLIProxy setup on a VPS or local machine.

tpn-proxy

3891
from openclaw/skills

Make web requests through decentralized SOCKS5 proxies via the Tao Private Network (TPN). This skill is also known as "TPN", "TPN proxy", "subnet 65", or "SN65" — if the user asks to "run TPN", "use a proxy", "use TPN to open", or references "subnet 65", this is the skill they mean. Use when the user wants to route HTTP traffic through a proxy, make anonymous web requests, access geo-restricted content, use a decentralized VPN, fetch a URL through a SOCKS5 proxy, or needs residential proxy IPs. Supports both centralised API key authentication and decentralised x402 micropayments.

tg-ws-proxy-telegram-socks5

3831
from openclaw/skills

Local SOCKS5 proxy server that accelerates Telegram Desktop by routing traffic through WebSocket connections to Telegram DCs

---

3891
from openclaw/skills

name: article-factory-wechat

Content & Documentation

humanizer

3891
from openclaw/skills

Remove signs of AI-generated writing from text. Use when editing or reviewing text to make it sound more natural and human-written. Based on Wikipedia's comprehensive "Signs of AI writing" guide. Detects and fixes patterns including: inflated symbolism, promotional language, superficial -ing analyses, vague attributions, em dash overuse, rule of three, AI vocabulary words, negative parallelisms, and excessive conjunctive phrases.

Content & Documentation

find-skills

3891
from openclaw/skills

Helps users discover and install agent skills when they ask questions like "how do I do X", "find a skill for X", "is there a skill that can...", or express interest in extending capabilities. This skill should be used when the user is looking for functionality that might exist as an installable skill.

General Utilities

tavily-search

3891
from openclaw/skills

Use Tavily API for real-time web search and content extraction. Use when: user needs real-time web search results, research, or current information from the web. Requires Tavily API key.

Data & Research

baidu-search

3891
from openclaw/skills

Search the web using Baidu AI Search Engine (BDSE). Use for live information, documentation, or research topics.

Data & Research

agent-autonomy-kit

3891
from openclaw/skills

Stop waiting for prompts. Keep working.

Workflow & Productivity