aiterm-mcp AGENTS.md

aiterm-mcp AGENTS.md is an instructions file for Codex, OpenCode from kitepon/aiterm-mcp. It costs 1,735 tokens per session, scanned A, original, MIT.

Project instructions for aiterm-mcp, a tool that develops and runs Aiterm, including its terminal sessions, agent launches, configuration, diagnostics, and recovery rules. They define which parts of the product this repository owns.

In plain words
What is it for?
Use them when changing Aiterm installation, sessions, schemas, migrations, launchers, diagnostics, release documentation, or platform-specific behavior.
Why use it?
They prevent changes that break the project’s public contracts, platform support, or separation between the launcher and the agent harness.

Instructions file for CodexOpenCode

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 instructions/kitepon/aiterm-mcp/agents-md
Clone the repo
git clone --depth 1 https://github.com/kitepon/aiterm-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 aiterm-mcp AGENTS.md

README.md
[![agentmods](https://agentmods.dev/badge/instructions/kitepon/aiterm-mcp/agents-md.svg)](https://agentmods.dev/instructions/kitepon/aiterm-mcp/agents-md)
Your own site
<a href="https://agentmods.dev/instructions/kitepon/aiterm-mcp/agents-md"><img src="https://agentmods.dev/badge/instructions/kitepon/aiterm-mcp/agents-md.svg" alt="Measured on agentmods" height="20"></a>
Per session 1,735 This file is loaded in full into every session.
When invoked 1,735 The same file — it is already loaded in full.
Security scan A 0 findings. 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 $0.01735 $0.01735
Opus 5 $0.00868 $0.00868
Sonnet 5 $0.00347 $0.00347
Haiku 4.5 $0.00173 $0.00173

Measured today against content hash 3f251d610497, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

aiterm-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 today.

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 · 86 lines

How it starts

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

AGENTS.md

aiterm-mcpで働くAIのプロジェクト正典。利用者向け公開契約はREADME日本語README、設計はDESIGN、文書地図は docs overview、公開工程はRELEASEを正とする。 版別の変更と完了証拠はCHANGELOGdocs/adr/docs/archive/に置き、 このファイルへrelease日誌を複製しない。

製品と所有境界

本repositoryはAitermを単独で開発・導入・運用・診断・復旧・更新・releaseできる状態を所有する。 install、設定、PTY/session、agent相関state、schema、migration、diagnostics、recovery、公開物の正本は このrepository内に置く。dotagentsは任意の工場統合、host wire、製品間compatibilityと統合受入を担うが、 Aitermの製品判断・実行・releaseを制御せず、通常利用の必須依存でもない。

現行契約

  • Node.js 18以上。POSIXはtmux、Windows nativeはpsmux 3.3.8以上+Git for Windowsを使う。 Windowsの対話shellはPowerShell 7だけとし、Windows PowerShell 5.1、PowerShell 6、cmd.exe、 WSL bridgeへfallbackしない。
  • 公開面は16 tools。PTY 6、標準agent_launch 1、deprecated互換launcher 4、 agent_configureagent_steerclaude_turnclaude_approvaldiagnosticsである。
  • agent_launchはharnessとmodelを別軸にする。harnessはagent loop、認証、hook、session、 transcriptを所有し、modelはそのharness上で選ぶ。ComposerはGrok CLIのmodel presetである。
  • launcherは直接CLIと同じ通常HOME、project/user設定、MCP、plugin、skill、permission、trust、 memory、historyを使う。Aitermはlaunch相関、完了event、bounded result、cleanup metadataだけを所有し、 credential/設定をcopy、snapshot、filterしない。
  • agentへの送信は非ブロックdispatchで即返す。完了はreceiptのwait_processを別processとして起動し、 outcomeを判定する。親自身のturnをforeground waiterで止めない。回答回収は pty_read(agent_transcript:true)またはclaude_turn recoverを使い、timeout後にpromptを再送しない。
  • 公開復旧はpty_listで対象を確認し、該当sessionをpty_closeして同じIDで作り直す。 公開toolに全session一括停止はない。core.killAll()は内部test cleanupであり、利用者へ案内しない。
  • runtime error storeは製品所有のlocal stateで、network I/Oを持たない。工場reporter configによる収集は 明示opt-inの任意adapterであり、未設定でもPTY/agent/diagnosticsは単独で動く。prompt、transcript、 path、credential、生stack/stderrを保存・公開しない。

コード所有

  • src/index.ts: MCP toolとschema。
  • src/core.ts: PTY、入出力整形、出力削減、完了検出、harness共通進行。
  • src/harnesses/: Claude/Codex/Grok/Cursor固有の起動、ready、完了、transcript、catalog。
  • src/agent-shared.tssrc/state-root.ts: harness中立の相関state。
  • src/tmux-runtime.tssrc/psmux-send-worker.tssrc/agent-resolver.ts: OS・multiplexer差。
  • src/runtime-error-*.ts: 製品所有のoffline error aggregate。
  • src/rtk.ts: 自前reducer。pytestはrtk 0.42.0と一致し、FAILED理由全文保持だけ意図的に異なる。
  • prototype/python/: 旧MVPとreducer移植元。参照専用。

Read the full file on GitHub · 86 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. today Changed · +34 tokens per session 3f251d610497
  2. 3d ago Changed · +4 tokens per session 688305ccc7d7
  3. 4d ago First seen · 86 lines · 1,697 tokens per session scan A 6c8b9d9b212f

Subscribe to this mod's changes

aiterm-mcp AGENTS.md is an instructions file published in the GitHub repository kitepon/aiterm-mcp (5 stars, last pushed today), licensed MIT. It adds 1,735 tokens to every session, about $0.0087 per session on Opus 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.