ClaudeMods
☰
KO
● 0 명 접속 중 · 조회 0 회
후원프로젝트 제출
GitHub 저장소 · 작성자 ljmerza

prompt-spellcheck

모델이 읽기 전에 프롬프트의 철자 오류와 오타를 수정하는 Claude Code 플러그인입니다.

ljmerza@ljmerza

ljmerza/prompt-spellcheck/tree/main/plugins/prompt-spellcheck

번역 완료

이 mod 소개

모델이 프롬프트를 읽기 전에 철자 오류와 오타를 수정하는 Claude Code 플러그인입니다.

you type:     look uo claude code mods woth tests
model reads:  look up claude code mods with tests
toast:        ✎ spellcheck: uo→up, woth→with

Enter를 누르면 플러그인이 프롬프트를 작고 빠른 모델(Haiku)로 보내 철자만 수정하도록 합니다. 표현, 구두점, 코드, 경로, URL, 플래그와 티켓 키는 입력한 그대로 유지됩니다. 수정된 텍스트가 프롬프트를 대신하고 토스트에 변경 내용이 표시됩니다.

설치

마켓플레이스에서 설치:

/plugin marketplace add ljmerza/prompt-spellcheck
/plugin install prompt-spellcheck@prompt-spellcheck

클론한 저장소에서 설치:

git clone https://github.com/ljmerza/prompt-spellcheck.git
claude --plugin-dir prompt-spellcheck/plugins/prompt-spellcheck

플래그를 전달할 수 없는 곳(데스크톱 앱, SDK 호스트)에서는 CLAUDE_CODE_PLUGIN_DIRS=/path/to/prompt-spellcheck/plugins/prompt-spellcheck를 설정하면 같은 방식으로 작동합니다.

이 플러그인은 Claude Code의 function-hook API(hooks.json의 "modules")를 대상으로 작성되었습니다. 이 API는 얼리 액세스 상태라 릴리스마다 바뀔 수 있습니다. Claude Code 2.1.287에서 빌드하고 테스트했습니다.

사용법

입력하는 모든 프롬프트에서 검사가 실행됩니다. 다음 명령으로 전환합니다.

/spellcheck off
/spellcheck on
/spellcheck status

설정은 세션이 바뀌어도 유지됩니다.

건너뛰는 항목

  • 슬래시 명령(/…)과 셸 모드 입력(!…)
  • 코드 펜스를 포함한 프롬프트
  • 두 단어 미만이거나 4,000자를 초과하는 프롬프트
  • 사용자가 입력한 것이 아닌 프롬프트: 백그라운드 작업 알림, 예약 실행, 다른 세션의 메시지, 자동 계속

검사가 실패할 때

다음과 같은 경우 프롬프트는 수정 없이 통과합니다.

  • 모델이 8초보다 오래 걸린 경우
  • API가 오류를 반환한 경우
  • 응답이 <fixed> 태그로 감싸지지 않은 경우
  • 응답 길이가 원본과 20–25%보다 크게 다른 경우(모델이 수정 대신 프롬프트에 답하는 것을 막기 위한 보호 장치)

비용 및 개인정보 보호

검사하는 프롬프트마다 개인 Claude Code 계정에서 Haiku 요청이 1회 추가로 발생합니다. 세션의 나머지 부분과 같은 클라이언트와 제공자를 사용합니다. 제출할 때마다 해당 요청의 지연 시간이 더해집니다. 필요하지 않을 때는 /spellcheck off로 끄세요.

모델 변경

모델은 hooks/register.ts의 MODEL로 설정합니다. --model이 허용하는 별칭이나 모델 ID를 사용할 수 있습니다.

개발

claude plugin validate .
claude plugin test .

테스트는 모델을 가짜 model.complete hook으로 바꾸므로 API 호출이 발생하지 않습니다.

라이선스

MIT

설치

먼저 작성자의 README에서 marketplace와 플러그인 이름을 확인하세요. 저장소 구조에 따라 명령어가 달라질 수 있습니다.

claude plugin marketplace add ljmerza/prompt-spellcheck
claude plugin install prompt-spellcheck
원문 / README

prompt-spellcheck

A Claude Code plugin that fixes spelling mistakes and typos in your prompt before the model reads it.

you type:     look uo claude code mods woth tests
model reads:  look up claude code mods with tests
toast:        ✎ spellcheck: uo→up, woth→with

When you press Enter, the plugin sends the prompt to a small, fast model (Haiku) with instructions to fix spelling only. Wording, punctuation, code, paths, URLs, flags and ticket keys stay as typed. The corrected text replaces the prompt, and a toast lists what changed.

Install

From a marketplace:

/plugin marketplace add ljmerza/prompt-spellcheck
/plugin install prompt-spellcheck@prompt-spellcheck

From a clone:

git clone https://github.com/ljmerza/prompt-spellcheck.git
claude --plugin-dir prompt-spellcheck/plugins/prompt-spellcheck

CLAUDE_CODE_PLUGIN_DIRS=/path/to/prompt-spellcheck/plugins/prompt-spellcheck does the same where you can't pass a flag (desktop app, SDK hosts).

The plugin is written against Claude Code's function-hook API (hooks.json "modules"), which is in early access and can change between releases. Built and tested on Claude Code 2.1.287.

Usage

The check runs on every prompt you type. Toggle it with:

/spellcheck off
/spellcheck on
/spellcheck status

The setting persists across sessions.

What it skips

  • Slash commands (/…) and shell-mode input (!…)
  • Prompts containing a code fence
  • Prompts under two words or over 4,000 characters
  • Prompts that didn't come from you: background-task notifications, scheduled runs, messages from other sessions, auto-continuations

When the check fails

Your prompt goes through unchanged when:

  • the model takes longer than 8 seconds
  • the API returns an error
  • the reply isn't wrapped in <fixed> tags
  • the reply's length differs from the original by more than 20–25% (this guards against the model answering the prompt instead of correcting it)

Cost and privacy

Each checked prompt is one extra Haiku request on your own Claude Code account, through the same client and provider as the rest of the session. It adds that request's latency to every submit. Turn it off with /spellcheck off when you don't want it.

Changing the model

The model is set by MODEL in hooks/register.ts. Any alias or model ID that --model accepts works there.

Development

claude plugin validate .
claude plugin test .

The tests replace the model with a fake model.complete hook, so they make no API calls.

License

MIT

비슷한 프로젝트