10router-dev

10router-dev is a skill for Claude Code, Codex from techysy/10router. It costs 77 tokens per session (2,216 once invoked), scanned B, original, MIT.

A development and troubleshooting guide for 10Router, a local AI routing gateway that sends client requests to models. It covers its Next.js deployment on a network-attached storage device (NAS).

In plain words
What is it for?
Use it to troubleshoot third-party client compatibility, build and deploy 10Router to a NAS, or decide whether to fix or work around an upstream bug.
Why use it?
It explains how to diagnose client and model failures, apply source changes correctly, and deploy updates through the required build and restart process.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: mentions Claude Code; mentions Codex.

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/techysy/10router/10router-dev
Any agent
npx skills add techysy/10router --skill 10router-dev
Clone the repo
git clone --depth 1 https://github.com/techysy/10router

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for 10router-dev

README.md
[![agentmods](https://agentmods.dev/badge/skills/techysy/10router/10router-dev.svg)](https://agentmods.dev/skills/techysy/10router/10router-dev)
Your own site
<a href="https://agentmods.dev/skills/techysy/10router/10router-dev"><img src="https://agentmods.dev/badge/skills/techysy/10router/10router-dev.svg" alt="Measured on agentmods" height="20"></a>
Per session 77 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,216 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 1 finding. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00077 $0.02216
Opus 5 $0.00039 $0.01108
Sonnet 5 $0.00015 $0.00443
Haiku 4.5 $0.00008 $0.00222

Measured yesterday against content hash 64c38c364348, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-06, from the pricing page.

Security

Grade B, and why

10router-dev scanned grade B with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Asks for rootmediumPrivilege escalation

A mod that escalates privileges can change anything on the machine, not only the project.

sudo mkdir -p /tmp/10router-new; sudo tar -xzf /tmp/*.tar.gz -C /tmp/10router-new
skills/10router-dev/SKILL.md · 134 lines

How it starts

The opening of the file, as written. The whole thing — 134 lines — stays where its author put it; the contents beside it link to each section on GitHub.

10Router — Dev & Troubleshooting 开发排障

Gateway: local AI routing proxy. NAS 上是 Next.js standalone 编译产物(server/.next/),不是源码。改逻辑必须 build + 部署 + 重启才生效。

部署循环(改源码 → 构建 → 部署 → 重启)

cd ~/projects/10router
npm run build    # 2-4 分钟
S=.next/standalone
cp -r open-sse $S/ 2>/dev/null; cp -r src/mitm $S/src/ 2>/dev/null; cp -r node_modules/node-forge $S/node_modules/ 2>/dev/null
cat $S/.next/BUILD_ID
tar -czf /tmp/10router-standalone.tar.gz -C $S .; scp /tmp/10router-standalone.tar.gz [email protected]:/tmp/

NAS 上(走 fnOS 生命周期,不能手动 kill):

SERVER=/vol4/@appcenter/10router/server
sudo mkdir -p /tmp/10router-new; sudo tar -xzf /tmp/*.tar.gz -C /tmp/10router-new
sudo cp -a $SERVER/.env /tmp/10router-new/.env      # 必须保留 .env
sudo cp -a $SERVER /vol4/@appcenter/10router/server.bak_vXXX   # 备份可回滚
sudo find $SERVER -mindepth 1 -delete; sudo cp -a /tmp/10router-new/. $SERVER/
sudo chown -R 10router:10router $SERVER
sudo appcenter-cli stop 10router; sudo appcenter-cli start 10router

验证:sudo cat $SERVER/.next/BUILD_ID 确认新 ID。重启会短暂断开当前 Hermes 会话(本会话经 10router 代理)——重启前告知用户。

第三方客户端兼容问题排查方法论("XX 用不了")

适用于:用户报某个第三方客户端(mirasim/dsh/codex/Claude Code 等)经 10router 调某模型报错,但同一模型其他客户端可能正常。先定位责任环节(客户端 / 网关 / 上游),再决定是否适配。

第一步:跨环境对比定位责任环节(最重要)

让用户在不同环境 + 客户端测同一个模型,做对照矩阵:

环境 结果 → 结论
NAS 直连客户端(独立安装,不经 mirasim) 正常 → 10router + 上游都正常
经 mirasim 的同一客户端 异常 → 嫌疑在 mirasim
经 mirasim 的另一个客户端(codex) 正常 → mirasim 本身没大问题
Claude Code → 10router 正常 → 10router translator 正确
同一客户端 + 官方 DeepSeek 报错更清晰 → 拿明确报错定位

多个"正常"锁定 10router 无责;一个"异常"锁定源头。

第二步:看网关日志确认请求到达 + 路由

sudo grep -nE "cbcn/deepseek|11133|ERROR" /vol4/@appdata/10router/10router.log | tail -20

请求行 POST <模型> → <provider/model> · FMT: <src>→<dst> · N MSG · N TOOL · ACC:<账号>

  • FMT 关键openai→openai = 原样透传(客户端发什么 10router 转发什么);claude→openai = 经 translator 转换(会重建 tool_calls)。
  • N TOOL 是客户端特征(mirasim+dsh=25,Claude Code=53)。
  • 确认请求真的到了(有时用户以为触发了但没到网关,日志空白)。

Read the full file on GitHub · 134 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday First seen · 134 lines · 77 tokens per session scan B 64c38c364348

Subscribe to this mod's changes

10router-dev is a skill published in the GitHub repository techysy/10router (20 stars, last pushed today), licensed MIT. It adds 77 tokens to every session and 2,216 once invoked, about $0.0004 per session on Opus 5. A static security scan graded it B with 1 finding (asks for root). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-04.

Related

Other skills, from other repositories

cli-backup-sync

Backup and restore OmniRoute data from the CLI. Trigger incremental snapshots, sync to cloud storage, manage backup schedules, and restore from archive files.

diegosouzapw/OmniRoute · 34 tokens

omni-sync-cloud

Synchronise OmniRoute configuration, provider connections, and settings to/from cloud storage. Manage cloud worker authentication and remote backup targets.

diegosouzapw/OmniRoute · 30 tokens

cli-tunnel

Start and stop tunnel connections (ngrok, Cloudflare, custom) from the CLI. Inspect active tunnel URLs, configure authentication, and test external reachability.

diegosouzapw/OmniRoute · 36 tokens

omni-tunnels

Create and manage secure tunnels (ngrok, Cloudflare Tunnel, custom) to expose OmniRoute to the internet or share access with remote agents and CI pipelines.

diegosouzapw/OmniRoute · 37 tokens

nginx-to-higress-migration

Migrate from ingress-nginx to Higress in Kubernetes environments. Use when (1) analyzing existing ingress-nginx setup (2) reading nginx Ingress resources and ConfigMaps (3) installing Higress via helm with proper ingressClass (4) identifying unsupported nginx annotations (5) generating WASM plugins for nginx…

higress-group/higress · 99 tokens

higress-openclaw-integration

Deploy and configure Higress AI Gateway for OpenClaw integration. Use when: (1) User wants to deploy Higress AI Gateway, (2) User wants to configure OpenClaw to use more model providers, (3) User mentions 'higress', 'ai gateway', 'model gateway', 'AI网关', (4) User wants to set up model routing or auto-routing, (5) User…

higress-group/higress · 103 tokens