Error Message Qualityのロゴ

Error Message Quality

コミュニティ
adamentwistle
error-message-quality

Write errors and log lines that name the failing thing, the offending value, and the likely fix, for a reader with no context. Use whenever writing a throw/raise, catch/except block, log statement, validation message, assertion, CLI exit message, or API error response, and when reviewing a diff that adds any of these. Not for user-facing copy unrelated to failures.

概要

公開者adamentwistle
リポジトリfable-skills
スキル名error-message-quality
スター
98
フォーク
11
同梱ファイル
指示のみ
ライセンスMIT
リンク
  • Markdown形式の指示

    モデルが必要に応じて読み込むSKILL.mdファイルです。関連するリクエストがあったときだけトークンを消費します。

  • どのLLMでも利用可能

    AIスキルはプロバイダー固有のコードではなく、通常のMarkdownなので、GPT、Claude、Gemini、Grok、ローカルモデルで利用できます。

  • 指示だけで完結

    モデルに必要なものはすべて指示に含まれているため、別途同期するファイルはありません。

  • オープンソース

    adamentwistleがGitHubで公開しています。インストールする前にソースを確認してください。

インストール

AIスキルError Message QualityをTypingMindにインストールすれば、どのLLMでも利用できます。SKILL.mdを読み取れる別のAIエージェントに追加することもできます。

1

TypingMindにインストール

TypingMindはGitHubフォルダから直接スキルをインストールします。SKILL.mdを読み取り、リソースファイルをまとめてローカルに保存します。

  1. アプリを開き、「プラグイン」→「スキル」に移動します。
  2. 「GitHubからインストール」を選択します。
  3. 以下のスキルフォルダのURLを貼り付けて確定します。
    https://github.com/adamentwistle/fable-skills/tree/main/error-message-quality
  4. スキルを利用したいチャットごとに、そのスキルを有効にしてください。
「プラグイン」→「スキル」→「スキルを追加」→「GitHubのURLから」を選択し、フォルダのURLを貼り付けて「続行」を押します。
2

別のAIエージェントにインストール

Agent Skills形式を読み取れるAIエージェントなら、このスキルを利用できます。フォルダをそのAIエージェントのスキルディレクトリにコピーしてください。

Claude Code — .claude/skills
git clone --depth 1 https://github.com/adamentwistle/fable-skills.git /tmp/fable-skills
mkdir -p .claude/skills
cp -r /tmp/fable-skills/error-message-quality .claude/skills/error-message-quality
コピー後、新しいスキルを読み込むためにClaude Codeを再起動してください。

TypingMindで使用

TypingMindのチャットでError Message Qualityを有効にするだけで、あとはモデルが対応します。名前と説明がシステムプロンプトに含まれ、関連するリクエストがあると、モデルが指示の全文を自動で読み込みます。手動で呼び出す必要はなく、実際に使用されるまでトークンを消費しません。

関連するリクエストがあると、モデルが自動的にError Message Qualityを読み込みます。

どのAIモデルでも利用可能

AIスキルはプロバイダー固有のコードではなく、通常のMarkdownで書かれた指示です。そのため、Error Message Qualityは作成時に想定されたモデルに縛られません。TypingMindに一度インストールすれば、ご自身のAPIキーを使って、GPT-5、Claude、Gemini、Grok、DeepSeek、Mistral、Llama、またはご自身で実行するローカルモデルで利用できます。

  • 必要なときだけ読み込み

    システムプロンプトには名前と説明だけが含まれます。関連するリクエストが初めてあったときに指示を取得するため、未使用のスキルにはコストがかかりません。

  • チャットの途中でモデルを切り替え

    スキルはコードではなく指示なので、モデルを切り替えてもそのまま使えます。次のモデルも同じSKILL.mdを読み込みます。

スキルの指示

モデルが読み込むSKILL.mdの内容です。スキルはモデルが従う指示なので、インストールする前に確認してください。

error-message-quality

Weak errors say "invalid config" or "something went wrong" and log error occurred with no stack. Strong errors let a stranger at 3am with no source access know what to look at first.

  1. Three parts: what failed, with what value, what to do. "config error: 'timeout' must be a positive integer, got '-5' in deploy.yaml" beats "invalid config" by an hour of debugging. Include the identifiers that distinguish this failure from its siblings: which file, record ID, endpoint, which of the twelve retries, which loop item.
  2. Never swallow the cause. When wrapping or re-raising, chain the original (raise X from e, %w, cause). When logging-and-continuing, log the exception with its stack, not just a string. A catch block that neither re-raises nor logs the exception needs a comment saying why, or it's a bug.
  3. Match the message to the audience. User-facing messages say what the user can do ("file too large, max 10MB") and never leak internals (paths, SQL, stack traces, hostnames). Operator-facing logs carry the internals precisely so nobody has to reproduce. If one failure needs both, produce both: a safe message outward, a detailed log inward.
  4. Redact secrets at the source. Tokens, passwords, keys, full connection strings, and auth headers never enter a message or log, including via wrapped exceptions or dumped request objects. Mask or truncate before formatting.
  5. Make messages greppable and unique. Stable constant text with the variable parts as values ("payment declined: code=%s order=%s"), so on-call can search logs and code for the same string. Don't assemble the constant part dynamically, and don't reuse the same wording in two places: a grep on the message should land on one line of code.
  6. Follow the codebase's logging conventions. Before adding a log line, look at how neighboring code logs: which logger, structured fields or format strings, existing field names (request_id, user_id, order_id). Reuse those names; attach the correlation or request ID when one is in scope.
  7. Log at the decision points you'd want during the outage: the request that entered, the branch taken, the external call and its outcome. If a bug just cost you an hour because nothing logged the crucial value, add the log line that would have saved you.
  8. Right level: errors are actionable problems; warnings are tomorrow's errors; info is narrative. Expected conditions (a cache miss, a client retrying) logged as errors train everyone to ignore errors.
  9. Trigger it once. Before finishing, cause the failure (a test, a bad input, a forced exception) and read the actual rendered output as the 3am reader. If you can't trigger it, paste the exact rendered message in your report so a reviewer can judge it.

Test: with only this message and no source access, could someone tell what to look at first? If not, it's missing a part.

よくある質問

AIスキル「Error Message Quality」では何ができますか?

Write errors and log lines that name the failing thing, the offending value, and the likely fix, for a reader with no context. Use whenever writing a throw/raise, catch/except block, log statement, validation message, assertion, CLI exit message, or API error response, and when reviewing a diff that adds any of these. Not for user-facing copy unrelated to failures.

TypingMindでError Message Qualityを使うメリットは何ですか?

一度インストールすれば、どのモデルでも使えるからです。Error Message Qualityはプロバイダー固有のコードではなく、通常のMarkdownで記述されているため、同じスキルをGPT-5、Claude、Gemini、Grok、ローカルモデルで利用できます。チャットの途中でモデルを切り替えても、そのまま使い続けられます。TypingMindは自分のAPIキーで動作するため、シート単位のサブスクリプションではなく、プロバイダーに直接料金を支払います。スキルとチャットは自分のストレージに保持されます。

TypingMindにError Message Qualityをインストールするにはどうすればよいですか?

TypingMindで「プラグイン」→「スキル」→「GitHubからインストール」を開き、https://github.com/adamentwistle/fable-skills/tree/main/error-message-qualityを貼り付けてください。TypingMindがSKILL.mdを読み込み、チャットごとに有効にできるスキルとしてインストールします。

Error Message Qualityを使えるAIモデルはどれですか?

TypingMindに接続したどのモデルでも利用できます。AIスキルはプロバイダー固有のコードではなく、通常のMarkdownで書かれた指示です。そのため、GPT、Claude、Gemini、Grok、ローカルモデルのいずれも、リクエストが合致したときにこのスキルを読み込めます。

Error Message Qualityは何個のAIモデルで使えますか?

数に制限はありません。スキルに対応したモデルであれば、GPT、Claude、Gemini、Grok、DeepSeek、Mistral、Llamaなど、どのモデルでもError Message Qualityを利用できます。すべてTypingMind上で、自分のAPIキーを使って利用できます。

AIスキル「Error Message Quality」は無料ですか?

はい。adamentwistleがGitHubでMITライセンスの下で公開しています。支払いが必要なのは、利用したトークンに対する、ご自身が契約するAIプロバイダーへの料金だけです。

AIスキルとは何ですか?

AIスキルは、特定のタスクの実行方法をAIモデルに教える、再利用可能な指示のセットです。オープンなAgent Skills形式に従い、名前と説明を含むSKILL.mdファイルに加え、モデルが必要とするスクリプト、テンプレート、参照ファイルで構成されます。モデルはリクエストがスキルに合致したときだけ指示を読み込むため、インストール済みのスキルも、使うまでは費用がかかりません。

AIスキルは、プラグインやMCPサーバーとどう違いますか?

プラグインやMCPサーバーは、モデルが呼び出せる新しいツールを提供します。ツールとは、どこかで実行され、結果を返すコードです。一方、AIスキルは、タスクへの取り組み方、従うべき手順、望ましい出力の例といった知識や進め方をモデルに伝えます。スキルは通常のMarkdownで記述されているため、サーバー、APIキー、実行環境は不要で、どのモデルでも利用できます。

すべて見る

今すぐ自分専用のAIワークスペースを作成

ニュースレターに登録すると、新機能や今後のプレゼント企画のお知らせが届きます👇