perplexity-improver

perplexity-improver is a skill for Claude Code from ThomasHoussin/Claude-Book. It costs 31 tokens per session (893 once invoked), scanned A, original, MIT.

A writing tool that rewrites sentences in story chapters when analysis suggests they resemble predictable AI-generated wording.

In plain words
What is it for?
Use it after drafting chapters, especially when a perplexity check raises a warning. It supports English and French chapters.
Why use it?
It helps reduce detectable writing patterns while keeping the chapter's story and meaning intact.

Skill for Claude Code

Written for Claude Code: installed under .claude/.

Not installable on its own: it reads a path above its own folder, which only exists inside its repository. The line is cd scripts/detection && uv run python detection.py ../../<path/to/chapter.md>.

Install

Getting it into your agent

There is no command for this one: it runs only inside a plugin, and the catalogue could not identify which plugin ships it. The source is linked below.

Made for: Claude Code.

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 perplexity-improver

README.md
[![agentmods](https://agentmods.dev/badge/skills/thomashoussin/claude-book/perplexity-improver.svg)](https://agentmods.dev/skills/thomashoussin/claude-book/perplexity-improver)
Your own site
<a href="https://agentmods.dev/skills/thomashoussin/claude-book/perplexity-improver"><img src="https://agentmods.dev/badge/skills/thomashoussin/claude-book/perplexity-improver.svg" alt="Measured on agentmods" height="20"></a>
Per session 31 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 893 The whole file, excluding the scripts and references it only reads on demand.
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.1 $0.00031 $0.00893
Opus 5 $0.00015 $0.00447
Sonnet 5 $0.00006 $0.00179
Haiku 4.5 $0.00003 $0.00089

Measured 6d ago against content hash 3e967d9b3d4f, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-06, from the pricing page.

Security

Grade A, and why

perplexity-improver 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 6d 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/skills/perplexity-improver/SKILL.md · 120 lines

How it starts

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

Perplexity Improver Skill

Reduce AI-detectable patterns in chapters by rewriting low-perplexity sentences while preserving narrative integrity.

Quick Start

/perplexity-improver story/chapters/chapitre-05.md

Multiple chapters can be analyzed in one run:

/perplexity-improver story/chapters/chapitre-01.md story/chapters/chapitre-02.md

Performance Warning

⚠️ The analysis script is SLOW (several minutes for model loading and analysis).

  • Accumulate several corrections before re-running
  • Use at the end of a writing session, not after each edit

When to Use

  • After writing a chapter, before final validation
  • When perplexity analysis shows a warning (⚠️)

Supported Languages

Code Language Techniques File
fr Français references/rewriting-techniques-fr.md
en English references/rewriting-techniques-en.md

Workflow

Phase 1: Analyze Chapter

1. Detect language from chapter content (first 500 characters):

  • Identify language code (fr, en, etc.)
  • Load corresponding techniques file: references/rewriting-techniques-{lang}.md
  • If language not supported → report error and exit

2. Run perplexity analysis from the script directory (required for uv to find dependencies):

cd scripts/detection && uv run python detection.py ../../<path/to/chapter.md>

Important: The uv run command must be executed from scripts/detection/ where the pyproject.toml is located.

3. Extract from output:

  • Median perplexity score
  • Warning status (median below threshold)
  • Suspect rate (percentage of suspect sentences)
  • List of suspect sentences sorted by ascending perplexity

Phase 2: Evaluate Need

The script flags sentences using multiple criteria:

  • low_perplexity: individually predictable sentence
  • low_std: passage with uniform perplexity (no surprises)
  • adjacent_low: extended stretch without friction
  • low_ppl_density: cumulative boredom signal
  • forbidden_word: AI-signal vocabulary

Read the full file on GitHub · 120 lines

Files

What ships with it

2 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

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. 6d ago First seen · 120 lines · 31 tokens per session scan A 3e967d9b3d4f

Subscribe to this mod's changes

perplexity-improver is a skill published in the GitHub repository ThomasHoussin/Claude-Book (112 stars, last pushed 7mo ago), licensed MIT. It adds 31 tokens to every session and 893 once invoked, about $0.0002 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.

Related

Other skills, from other repositories

story-import

逆向导入已有小说。将已写好的小说(半成品或完本)反向解析为标准项目目录结构,兼容 story-long-write / story-short-write 后续写作流程;内部复用 story-long-analyze / story-short-analyze 的拆解管道,按篇幅自动分流。触发方式:/story-import、「导入小说」「反向解析」「导入」「把我的书导进来」。.

zenstory-ai/oh-story-claudecode · 98 tokens

story-deslop

网文去AI味。检测并清除文本中的AI写作痕迹,让文字回归自然、非模板化。触发方式:/story-deslop、/去AI味、「去AI味」「这篇太AI了」「网文去AI味」。.

zenstory-ai/oh-story-claudecode · 62 tokens

story-long-analyze

长篇网文拆文。深度拆解爆款长篇小说的黄金三章、人设架构、爽点设计、节奏控制。单一深度拆解管道:跑完黄金三章(Stage 1)后产出快速预览报告并询问是否继续全量拆解,确认后从 Stage 2 续跑逐章摘要、聚合分析、设定关系、汇总报告,全程产物落盘 拆文库/{书名}/。触发方式:/story-long-analyze、/长篇拆文、「帮我拆这本书」「拆这本书」「分析黄金三章」「深度拆解」「完整拆解」「系统拆解」或提供小说文本文件路径——全部进入同一管道。.

zenstory-ai/oh-story-claudecode · 173 tokens

story-long-write

长篇网文写作。从大纲到正文,辅助长篇网络小说的创作,包括世界观、人物、情节线管理。触发方式:/story-long-write、/写长篇、「帮我开书」「写大纲」「日更」「续写」「继续写」「修改第X章」「回炉」「重写第X章」。.

zenstory-ai/oh-story-claudecode · 81 tokens

story-short-analyze

短篇网文拆文。拆解爆款短篇小说(番茄短篇 / 故事会 / 知乎盐选 / 追妻 / 世情 / 重生 / 虐渣等通俗题材)的故事核、结构、情感线、反转设计、写作手法、共鸣层次。单一全量拆解管道:跑完 Stage 2-6 产出完整拆文报告,落盘到 拆文库/{书名}/,下游 story-short-write 同时读拆文报告 + 情节节点 + 写作手法 + 原文 + meta.json 写下一篇。触发方式:/story-short-analyze、/短篇拆文、「拆短篇」「拆这篇短文」「短篇拆文」「精细拆解短篇」「8000 字短篇拆解」「番茄短篇拆文」「故事会拆解」「盐言故事拆解」「分析这篇短篇」——均进入同一管道。.

zenstory-ai/oh-story-claudecode · 226 tokens

story

网络小说工具箱主入口。根据用户需求自动路由到对应 skill,并可管理作者习惯、启动本地 Dashboard。触发方式:/story、$story、/story dashboard、/网文、「我想写小说」「记住我的写作习惯」「打开工作台」「检查更新」。.

zenstory-ai/oh-story-claudecode · 68 tokens