Skip to content

Add word-level analysis to the style generator - #1

Merged
shreyashankar merged 8 commits into
mainfrom
cursor/style-lexical-analysis-3c09
Aug 25, 2026
Merged

Add word-level analysis to the style generator#1
shreyashankar merged 8 commits into
mainfrom
cursor/style-lexical-analysis-3c09

Conversation

@shreyashankar

@shreyashankar shreyashankar commented Aug 25, 2026

Copy link
Copy Markdown
Contributor

Summary

The generator was missing a word-level measurement step. This adds the
bundled analyzer, then a multi-agent pass over words, sentences, and
passages — the original three parallel Agent forks.

  • Bundle analyze-style.mjs and run it with --words --measured
  • Multi-agent pass: words, sentences, passages
  • Copy scripts/ and references/metrics.json into the generated skill

Test plan

  • node tests/lexical-analysis.mjs
  • --words keeps the word-level slice
  • GitHub Actions test workflow

The generator skill previously jumped from sources to qualitative
word/sentence/passage forks. Bundle DocWriter's checklist analyzer and
require a measured lexical pass (A1–A5) before specialists write
propositions. Multi-source CLI flags keep hapax and signature n-grams
honest across the full sample.
GitHub rejected the first push because creating .github/workflows/test.yml
requires the workflow scope. Keep the lexical analyzer and tests; npm test
still runs locally.
The updated token should include workflow scope, so the test workflow
can live in the plugin repo again.
The plugin is one skill. It measures word-level habits with the bundled
script, then reads the same prose at the word, sentence, and passage
level. It does not spawn lexis, grammar, or discourse agents, and it
should not talk about Leech and Short families.
@shreyashankar shreyashankar changed the title Add lexical analysis to the style generator Add word-level analysis to the style generator Aug 25, 2026
Words, sentences, and passages are parallel Agent forks. Say that, instead
of explaining what they are not.
Install, invoke, and the generated skill. The generator already runs
the analyzer; nobody needs the CLI or the test command in the README.
Write samples to ~/.claude/skills/my-writing-style/sources/ and the
measurement report to references/metrics.json. /tmp is not part of the
style.
The generator used to offer only rebuild or keep. Adding a piece of
writing now keeps confirmed habits and existing sources; updating
propositions re-reads the samples already in the style skill.
@shreyashankar
shreyashankar merged commit 1f535d4 into main Aug 25, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants