copy-tuner-ruby-client CLAUDE.md

copy-tuner-ruby-client CLAUDE.md is an instructions file for coding agents from SonicGarden/copy-tuner-ruby-client. It costs 1,005 tokens per session, scanned A, original, MIT.

Project instructions for a Ruby client gem that synchronizes a Rails application's translated text with a CopyTuner server. They also document commands, architecture, testing, and coding rules such as TDD, meaning tests are written before the implementation.

In plain words
What is it for?
Use them when running tests, linting, building or releasing the gem, working on its Rails integration, or fixing bugs and adding features.
Why use it?
They give contributors the project's expected commands and development process, reducing guesswork and inconsistent changes.

Instructions file

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/sonicgarden/copy-tuner-ruby-client/claude-md
Clone the repo
git clone --depth 1 https://github.com/SonicGarden/copy-tuner-ruby-client

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 copy-tuner-ruby-client CLAUDE.md

README.md
[![agentmods](https://agentmods.dev/badge/instructions/sonicgarden/copy-tuner-ruby-client/claude-md.svg)](https://agentmods.dev/instructions/sonicgarden/copy-tuner-ruby-client/claude-md)
Your own site
<a href="https://agentmods.dev/instructions/sonicgarden/copy-tuner-ruby-client/claude-md"><img src="https://agentmods.dev/badge/instructions/sonicgarden/copy-tuner-ruby-client/claude-md.svg" alt="Measured on agentmods" height="20"></a>
Per session 1,005 This file is loaded in full into every session.
When invoked 1,005 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.01005 $0.01005
Opus 5 $0.00502 $0.00502
Sonnet 5 $0.00201 $0.00201
Haiku 4.5 $0.00101 $0.00101

Measured 5d ago against content hash 23d83e9d7b0d, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

copy-tuner-ruby-client CLAUDE.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 5d 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.

CLAUDE.md · 42 lines

How it starts

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

CLAUDE.md

CopyTuner の Ruby クライアント gem。Rails アプリの I18n を CopyTuner サーバと同期する。

コマンド

  • テスト: bundle exec rspec(単一ファイル: bundle exec rspec spec/copy_tuner_client/cache_spec.rb
  • 特定の Rails バージョンでテスト: BUNDLE_GEMFILE=gemfiles/8.0.gemfile bundle exec rspec
  • Lint: bundle exec rubocopsgcop を継承)
  • フロントエンドビルド: pnpm build(開発: pnpm dev
  • フロントエンド Lint/Format: pnpm check(Biome)
  • gem リリース: bundle exec rake build|install|release

Node.js / pnpm は mise(mise.toml)で管理。フロントエンドのツールチェーンは pnpm + Biome + Vite + TypeScript。

アーキテクチャ

Configuration#apply(lib/copy_tuner_client/configuration.rb)が全コンポーネントを組み立てる起点:

  • Client — CopyTuner サーバ / S3 との HTTP 通信
  • Cache — Mutex で保護された blurb ストア。Hash のように振る舞う。アップロードキューを管理
  • I18nBackend — デフォルトの I18n backend を置き換える(I18n.backend = ...)。lookup で Cache を参照
  • Poller / ProcessGuard — バックグラウンド同期スレッド
  • Rack middleware RequestSync / CopyrayMiddleware — 開発環境でのリクエスト毎同期とオーバーレイ Rails 統合は engine.rb のイニシャライザ経由(ヘルパー/SimpleForm フック、アセット precompile)。

開発スタイル

  • RED/TDD で進める: 実装前に必ず失敗するテストを書き、テストが RED になることを確認してから実装する
  • 新機能・バグ修正ともに「テスト追加 → RED 確認 → 実装 → GREEN」のサイクルを守る
  • テストを書かずに実装を先行させない
  • コメントは WHY のみ日本語で書く: 識別子やコードから読み取れる WHAT は書かない (例外: RuboCop Style/Documentation 対応でクラス/モジュール直前に追加する一行の説明コメントは、名前だけでは把握しづらいクラスの役割を一目で示す目的のため、WHAT の説明も可)
  • テストの describe / context / it の説明文は日本語で書く: 識別子(クラス名・メソッド名など)はそのまま

Gotchas

  • フロントエンドは src/*.ts を編集する。app/assets/* は Vite のビルド成果物なので直接編集しない (vite.config.ts が src/main.tsapp/assets/javascripts/copytuner.js を出力)。
  • local_first_key_regexp — locale を除いたキー対象・lookup 時に作用(ローカル YAML 優先)。 local_first キーのアップロード抑止は Cache#[]= に集約されている。
  • アップロード抑止の新ルールは Cache#[]= に足す。I18nBackend の書き込み経路(lookup / default / store_item)ごとに個別ガードを足さない (理由: cache への書き込みは全経路が最終的に Cache#[]= を通る単一の関門。経路ごとにガードを足すと付け忘れの穴が生まれ、同じチェックが分散して保守負担になる。実際 local_first の抑止は当初 default 個別に足したが穴が残り、Cache#[]= への集約に作り直した)。

Claude Code スキル

skills/copy-tuner/ に i18n キー操作支援スキルがある(SKILL.md 参照)。

Read the full file on GitHub · 42 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. 5d ago First seen · 42 lines · 1,005 tokens per session scan A 23d83e9d7b0d

Subscribe to this mod's changes

copy-tuner-ruby-client CLAUDE.md is an instructions file published in the GitHub repository SonicGarden/copy-tuner-ruby-client (11 stars, last pushed today), licensed MIT. It adds 1,005 tokens to every session, about $0.0050 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-30.