Reading Deduction Cert logo

Reading Deduction Cert

Community
kazukinagata
reading-deduction-cert

控除証明書(生命保険料・地震保険料等)の画像を読み取り構造化データを返す。 他のスキルから呼び出されるほか、直接ユーザーが呼び出すことも可能。

Overview

Publisherkazukinagata
Repositoryshinkoku
Skill namereading-deduction-cert
Stars
366
Forks
32
Bundled files
Instructions only
LicenseMIT
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • Self-contained

    Everything the model needs lives in the instructions — no extra files to sync.

  • Open source

    Published by kazukinagata on GitHub. Read the source before you install it.

Installation

Install the Reading Deduction Cert AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
    https://github.com/kazukinagata/shinkoku/tree/main/skills/reading-deduction-cert
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/kazukinagata/shinkoku.git /tmp/shinkoku
mkdir -p .claude/skills
cp -r /tmp/shinkoku/skills/reading-deduction-cert .claude/skills/reading-deduction-cert
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Reading Deduction Cert in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Reading Deduction Cert on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Reading Deduction Cert is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

控除証明書 画像読み取り

控除証明書(生命保険料控除証明書、地震保険料控除証明書、社会保険料控除証明書等)の画像を読み取り、構造化データとして返すスキル。

PDF ファイルの場合

ファイルが PDF(.pdf)の場合、画像 OCR の前にテキスト抽出を試みる。

  1. shinkoku pdf extract-text --file-path <path> を実行する
  2. 抽出テキストに必要な情報(保険料額・証明額等)が含まれていれば、テキストから構造化データを生成する
  3. テキストが不十分(スキャン PDF 等)の場合は shinkoku pdf to-image --file-path <path> --output-dir <dir> で PNG に変換し、以下の画像読み取りフローに進む

画像読み取り方法

推奨: デュアル検証(並列2コンテキスト)

精度を高めるため、同じ画像を2つの独立したコンテキストで並列に読み取り、結果を照合する。

  1. 2つの独立した読み取りを実行する: サブエージェントが使える環境では、2つのサブエージェントを並列で起動し、それぞれ独立に画像を読み取る。 各サブエージェントには以下の「基本ルール」と「出力フォーマット」をプロンプトとして渡し、画像ファイルパスを指定する。

  2. 結果照合: 両方の読み取り結果から主要フィールド(金額等)を比較する。

  3. 一致の場合: そのまま採用。「2つの独立した読み取りで結果が一致しました」と報告する。

  4. 不一致の場合: ユーザーに元画像パスと両方の結果を提示し、正しい方を選択してもらう:

    • 差異のあるフィールドを明示する
    • A を採用 / B を採用 / 手動入力 の3択を提示する

フォールバック(サブエージェント非対応の場合)

サブエージェントが利用できない環境では、以下の手順で読み取る:

  1. 画像ファイルを直接 Read ツールで読み取る
  2. 以下の「基本ルール」と「出力フォーマット」に従ってデータを抽出する
  3. 抽出結果をユーザーに提示し、必ず目視確認を依頼する

⚠ デュアル検証が利用できないため、必ずユーザーに目視確認を依頼してください。

基本ルール

  • 画像ファイルは Read ツールで読み取る(Claude Vision が自動的に画像を認識する)
  • 金額は必ず int(円単位の整数)で返す。カンマや「円」は除去する
  • 日付は YYYY-MM-DD 形式で返す
  • 和暦は西暦に変換する(令和7年 → 2025、令和6年 → 2024、平成31年 → 2019)
  • 読み取れないフィールドは UNKNOWN(文字列)または 0(金額)とする

対象書類

  • 生命保険料控除証明書
  • 地震保険料控除証明書
  • 社会保険料(国民年金保険料)控除証明書
  • 小規模企業共済等掛金払込証明書(iDeCo含む)

出力フォーマット

JSON オブジェクトとして返す。金額は必ず int(円単位の整数)とする。

生命保険料控除証明書

json
{
  "certificate_type": "life_insurance",
  "policy_type": "新制度 or 旧制度",
  "category": "一般 or 介護医療 or 個人年金",
  "company_name": "保険会社名",
  "policy_number": "証券番号",
  "annual_premium": 120000,
  "dividend": 0
}

地震保険料控除証明書

json
{
  "certificate_type": "earthquake_insurance",
  "company_name": "保険会社名",
  "policy_number": "証券番号",
  "annual_premium": 50000,
  "is_old_long_term": false
}

社会保険料控除証明書

json
{
  "certificate_type": "social_insurance",
  "insurance_type": "national_pension",
  "annual_premium": 200000,
  "period": "対象期間"
}

小規模企業共済等掛金払込証明書

json
{
  "certificate_type": "small_business_mutual_aid",
  "sub_type": "ideco or small_business or disability",
  "annual_contribution": 276000
}

抽出のポイント

  • 書類の種別(生命保険料/地震保険料/社会保険料/小規模企業共済等)を最初に判定する
  • 生命保険料控除は新旧制度の区別と、3区分(一般/介護医療/個人年金)の分類を確認する
  • 地震保険料控除は旧長期損害保険かどうかの区別を確認する
  • 金額は「証明額」「申告額」が異なる場合、「申告額」を使用する
  • 保険会社名・証券番号は確認用に抽出する

Frequently asked questions

What does the Reading Deduction Cert AI skill do?

控除証明書(生命保険料・地震保険料等)の画像を読み取り構造化データを返す。 他のスキルから呼び出されるほか、直接ユーザーが呼び出すことも可能。

Why use Reading Deduction Cert on TypingMind?

Because you install it once and use it with any model. Reading Deduction Cert is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Reading Deduction Cert in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/kazukinagata/shinkoku/tree/main/skills/reading-deduction-cert. TypingMind reads its SKILL.md and installs it as a skill you can enable per chat.

Which AI models can use Reading Deduction Cert?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Reading Deduction Cert?

As many as you like. As long as a model supports skills, you can use Reading Deduction Cert with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Reading Deduction Cert AI skill free?

Yes. It is published on GitHub by kazukinagata under the MIT license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇