rigol-oscilloscope-mcp: Instructions file for Codex

AGENTS.md

rigol-oscilloscope-mcp AGENTS.md is an instructions file for Codex, OpenCode from zinntikumugai/rigol-oscilloscope-mcp. It costs 1,733 tokens per session, scanned A, original, MIT.

A project instruction file for agents working on a Python server that controls Rigol oscilloscopes, electronic test instruments, through SCPI commands.

In plain words
What is it for?
Use it when developing, testing, or reviewing the server, including simulated tests and optional tests against a real oscilloscope.
Why use it?
It tells coding agents which commands, architecture rules, safety checks, and hardware-test conditions the project expects.

Instructions file for CodexOpenCode

Written for Codex and OpenCode: the file is AGENTS.md. Also seen: reads .claude/ paths; mentions .claude-plugin; mentions AGENTS.md.

This is zinntikumugai/rigol-oscilloscope-mcp's own configuration. It tells Codex and OpenCode how to work on rigol-oscilloscope-mcp itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything rigol-oscilloscope-mcp configures →

Reuse

Borrowing it

Nothing to install: this file belongs to zinntikumugai/rigol-oscilloscope-mcp. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/zinntikumugai/rigol-oscilloscope-mcp/main/AGENTS.md
Clone the repo
git clone --depth 1 https://github.com/zinntikumugai/rigol-oscilloscope-mcp

Made for: Codex, OpenCode.

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 rigol-oscilloscope-mcp AGENTS.md

README.md
[![agentmods](https://agentmods.dev/badge/instructions/zinntikumugai/rigol-oscilloscope-mcp/agents-md/github.svg)](https://agentmods.dev/instructions/zinntikumugai/rigol-oscilloscope-mcp/agents-md)
Your own site
<a href="https://agentmods.dev/instructions/zinntikumugai/rigol-oscilloscope-mcp/agents-md"><img src="https://agentmods.dev/badge/instructions/zinntikumugai/rigol-oscilloscope-mcp/agents-md/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for rigol-oscilloscope-mcp AGENTS.md

Your own site · 80×15
<a href="https://agentmods.dev/instructions/zinntikumugai/rigol-oscilloscope-mcp/agents-md"><img src="https://agentmods.dev/badge/instructions/zinntikumugai/rigol-oscilloscope-mcp/agents-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 1,733 This file is loaded in full into every session.
When invoked 1,733 The same file — it is already loaded in full.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
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.01733 $0.01733
Opus 5.5 $0.00693 $0.00693
Sonnet 5.5 $0.00347 $0.00347
Haiku 4.5 $0.00173 $0.00173

Measured 2mo ago against content hash d6da19218428, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

rigol-oscilloscope-mcp AGENTS.md scanned grade A with 0 findings 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 2mo ago.

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.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

AGENTS.md · 60 lines

How it starts

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

AGENTS.md — エージェント向け開発ガイド

Rigol製オシロスコープをSCPI経由で操作するMCPサーバー(Python)。要件・仕様の規範は docs/README.md から辿ること(Requirements / tools / device-profiles / verification / roadmap)。

コマンド

mise install                  # Python + uv(バージョンはmise管理、依存はuv管理)
uv sync                       # 依存解決(dev含む)
uv run pytest                 # ユニットテスト全件(実機不要、FakeScopeで完結)
uv run pytest tests/test_xxx.py -v          # 単一ファイル
RIGOL_MCP_FAKE=1 uv run rigol-oscilloscope-mcp   # 実機なしでstdio起動(FakeScope接続)

# 実機テスト(env-gated。未設定なら自動skip)
RIGOL_TEST_ADDRESS=<実機IP> uv run pytest -m device                          # read-only
RIGOL_TEST_ADDRESS=<実機IP> RIGOL_TEST_ALLOW_WRITE=1 uv run pytest -m device_write  # write(復元付き)

mise外のシェルでは mise exec -- uv run ... を使う。

アーキテクチャ

server.py(FastMCP、38 Tool、同期def+lock直列化)
  → service/(connection / state / measurement / waveform / analysis / screenshot / control / decode / paths)
  → safety/(操作クラス表 / confirmトークン / 監査ログJSONL)
  → driver/(session: drain・set_and_verify / scope: プロファイル対応SCPI生成 / decode: :BUS変換表)
  → transport/(lan: raw socket 5555 / usb: PyVISA / blocks: IEEE488.2ブロック)
profiles/(YAML機種プロファイル: verified→family→guide→generic の解決順。guide=ガイド逐語解読のみ・実機未検証)
testing/(FakeScope: MHO98方言のフェイク機器。Transport層に差し込む)
skills/ + .claude-plugin/ + .codex-plugin/ + .agents/(Claude/Codex両プラグイン: 共有スキル+ホスト別マニフェスト。tests/test_plugin.py が整合を検証)
  • MCP SDKのimportは server.py に閉じ込める。Toolは全て同期defで、返却は bare dict 注釈(structured content回避、実測済みの仕様)
  • エラーは例外でなく {"error": true, "code": ..., "message": ..., "detail": ...} のJSONを正常contentで返す(デコレータが変換)

絶対に守るルール

  1. 実機のIPアドレス・シリアルをリポジトリ内のいかなるファイルにも書かない。 実機は RIGOL_TEST_ADDRESS 環境変数でのみ渡す。tests/test_ip_guard.py がlintしており、コミット前に git grep "172\.16\." が空であることを確認する。例示IPが必要なら TEST-NET(192.0.2.x)を使う
  2. プロファイルで確認されていないSCPIニモニックを実機に送らない。 実機MHO98は未定義ヘッダのクエリ1発でSCPIサーバー全体が沈黙する(再接続でも回復せず、空行1本で回復 — LanTransport.open() が対策済み)。未対応機能は送信前に UNSUPPORTED_FEATURE を返す。新しいコマンドは機種プロファイル(profiles/data/*.yaml)への宣言とセットで追加する。*OPT? はRigolオシロ全シリーズで未定義ヘッダ(ガイド確認済み)。オプション照会は :SYSTem:OPTion:STATus? +ガイド記載トークンのみを使う(リスト外トークンでも沈黙する)
  3. 設定系は set → エラーキュー確認 → read-back を必須とし、requested / applied の両値を返す(機器は1-2-5にスナップしない。yorigin等のプリアンブル値は動的なので必ずライブ値を使う)
  4. 実機で実行禁止: 50Ω設定(FIFT)、autoset、factory reset(confirmフローはFakeScopeテストのみで担保)。実機writeテストは必ず「現在値取得→set→readback→finallyで復元」パターン
  5. 新Toolの追加手順: safety/classes.py の TOOL_CLASSES へ分類を追記(未登録は起動失敗する)。RESTRICTED_WRITE / DANGEROUS_WRITE に分類したら confirm_token 引数が必須(起動時チェックが強制)。引数条件付きの昇格(configure_channelの50Ω等)は service/control.py の責務

Read the full file on GitHub · 60 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. 2mo ago First seen · 60 lines · 1,733 tokens per session scan A d6da19218428

Subscribe to this mod's changes

rigol-oscilloscope-mcp AGENTS.md is an instructions file published in the GitHub repository zinntikumugai/rigol-oscilloscope-mcp (0 stars, last pushed 2mo ago), licensed MIT. It adds 1,733 tokens to every session, about $0.0069 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

rigol-oscilloscope-mcp AGENTS.md compared with instructions from other repositories

rigol-oscilloscope-mcp AGENTS.md next to 6 instructions from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
rigol-oscilloscope-mcp AGENTS.mdzinntikumugai/rigol-oscilloscope-mcpInstructions file02mo agoMITA1,733Codex, OpenCode
vscode buildNext.instructions.mdmicrosoft/vscodeInstructions file195kyesterdayMITA9,719GitHub Copilot
next.js AGENTS.mdvercel/next.jsInstructions file143kyesterdayMITA7,461Codex, OpenCode
langchain AGENTS.mdlangchain-ai/langchainInstructions file149kyesterdayMITA4,680Codex, OpenCode
vscode oss-third-party-notices.instructions.mdmicrosoft/vscodeInstructions file195kyesterdayMITA5,516GitHub Copilot
vscode copilot-instructions.mdmicrosoft/vscodeInstructions file195kyesterdayMITA3,093GitHub Copilot
deepseek-harness AGENTS.mddeepseek-ai/deepseek-harnessInstructions file274k2d agoMITA4,313Codex, OpenCode