Skip to main content

llm-tools-shodo

PyPI Changelog Tests License

An llm plugin that proofreads Japanese text with the Shodo AI proofreading API. We use this plugin to proofread Japanese text in our Kafkai Blog, Kafkai AI Media and PuchiDen Blog as part of our editorial pipeline.

The plugin is a simple Python script that uses the llm API to add a new command and tool.

Features

It adds two things:

  • llm shodo: a command that reads text and prints the corrected text. No model is involved, so only Shodo's fixes change the text. Every other byte, including CRLF line endings, stays as it was.
  • shodo_proofread: an llm tool, for when you want a model to proofread and then discuss or rework the text.

Both apply every Shodo suggestion that has a replacement and a score of at least 0.5. The official shodo lint command hides suggestions below 0.5, so the plugin lists them as issues instead of applying them. Both also list the issues that have no automatic fix. Empty input never reaches the API.

Installation

Install this plugin in the same environment as LLM. You need LLM 0.33 or newer and Python 3.10 or newer.

llm install llm-tools-shodo

To install the latest code from GitHub before a release reaches PyPI:

llm install https://github.com/kafkaigiken/llm-tools-shodo/archive/refs/heads/main.zip

Credentials

  1. In Shodo, open the project, then API連携 (API settings), and create a token.
  2. Store the token and set the API root:
llm keys set shodo        # paste the token
export SHODO_API_ROOT="https://api.shodo.ink/@your-org/your-project/"

The root and the token always come from the same source, so a token is never sent to another project's root. The plugin uses the first complete pair it finds:

  1. SHODO_API_ROOT and SHODO_API_TOKEN, both set. These override a stored key.
  2. SHODO_API_ROOT and the token stored with llm keys set shodo.
  3. The default profile in ~/.config/shodo/credentials, the file that the official shodo login command writes. The plugin reads ~/.shodo/credentials when that file does not exist.

Usage

To fix a file, run llm shodo. The input must be UTF-8. The corrected text goes to stdout, and the fix report goes to stderr:

cat article.md | llm shodo > fixed.md
llm shodo article.md -q          # -q: no report
llm shodo page.html --html       # HTML input

To proofread inside a model conversation, use the tool:

cat article.md | llm -T shodo_proofread "Proofread this, then explain the main issues." --td

(Omit --td if you don't want to see the tool call details.)

This repository also ships a template, templates/shodo.yaml. It tells the model to call the tool and return the corrected text unchanged. To install it as the shodo template:

cp templates/shodo.yaml "$(llm templates path)/shodo.yaml"
cat article.md | llm -t shodo

Development

To set up this plugin locally, first check out the code. Then create a new virtual environment:

cd llm-tools-shodo
python -m venv venv
source venv/bin/activate

Now install the dependencies and test dependencies:

llm install -e '.[test]'

To run the tests:

python -m pytest

The tests use httpx2.MockTransport in place of the real API, so they need no Shodo token.

Metadata

Release files for llm-tools-shodo 0.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for llm-tools-shodo 0.1.1
File Size Uploaded Provenance Actions
llm_tools_shodo-0.1.1.tar.gz 13.3 kB With provenance Details for llm_tools_shodo-0.1.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for llm-tools-shodo 0.1.1
File Interpreter ABI Platform Actions
llm_tools_shodo-0.1.1-py3-none-any.whl Python 3 none any Details for llm_tools_shodo-0.1.1-py3-none-any.whl

Total release size: 24.4 kB

Release files / llm_tools_shodo-0.1.1.tar.gz

Download URL llm_tools_shodo-0.1.1.tar.gz
Size 13.3 kB
Tags Source
SHA-256 checksum
How to use checksums
e8355c3b60c0b2817e5ec559d67d57e913190f3e4c88ada521ddd70a6ac53408
BLAKE2b-256 checksum
How to use checksums
5d471369579d3c52e755236d0b080c6146a7149b8d30b1e85542c3d09b3e9117
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 19, 2026.

Transparency log

Release files / llm_tools_shodo-0.1.1-py3-none-any.whl

Download URL llm_tools_shodo-0.1.1-py3-none-any.whl
Size 11.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
6f2d201d7f765677ff1894c4ba8776facc24a0894b9e1dfced89aabac152460e
BLAKE2b-256 checksum
How to use checksums
1a6cff92443cf603ac1c43a9f0f99b223fd3ab73fbaa3af5b8c8c2bc44a83d09
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 19, 2026.

Transparency log

Security for llm-tools-shodo 0.1.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for llm_tools_shodo-0.1.1.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 19, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.1.1 This release

2 release files Full provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page