Skip to content

docs: anticipate unseen variations in Prime Claude; $dev and $silent run-mode variables - #217

Merged
ddehilster merged 2 commits into
VisualText:mainfrom
ddehilster:docs/prime-claude-anticipate-variations
Sep 14, 2026
Merged

ddehilster merged 2 commits into
VisualText:mainfrom
ddehilster:docs/prime-claude-anticipate-variations

Conversation

@ddehilster

Copy link
Copy Markdown
Member

Two documentation changes, neither yet on main.

1. Prime Claude: anticipate unseen variations (Help/markdown/vscode/prompts/00-prime-claude.md)

Two new Rules of thumb, beside "Look in the libraries before you write a vocabulary", and the summary line updated:

  • Write the vocabulary for the text you have not seen yet. When an entry goes into a word list, dictionary or knowledge base, its family goes in with it: abbreviations and acronyms ("BC", "SSN", "DOB"), synonyms ("ID card" / "identification card", "legal name" / "full name"), spelling, spacing and hyphenation variants, singular and plural, and qualified forms that mean something different ("foreign nursing license"). Where the variation is productive, a pattern rather than a list of strings ("city and state of birth").
  • Keep a set of inputs you never tune on, with its expected results written down before the analyzer runs on it, and report that score as the honest one.

Found building a reader of outbound client messages: tuned on 40 messages it scored 100%; on 40 it had never seen, written down beforehand, it found 81% of the asks. The misses were names the vocabulary had never been given ("BC", "SSN", "basic life support certification", "city and state of birth").

2. $dev and $silent run-mode special variables (cherry-picked from ddehilster/visualtext-files PR #4, 6d61811)

New pages Help/markdown/$dev.md and $silent.md, their rows in NLP_PP_Stuff/Special_Variables.md, and entries in index.md. They were merged into the fork but never reached main.

Not included: the fork's analyzer-templates submodule updates (main already points at the same commit, 6723c69), and uncommitted local work on feat/english-lemmas (not commits).

🤖 Generated with Claude Code

ddehilster and others added 2 commits September 14, 2026 11:32
A vocabulary built only from the test inputs fits the test inputs. When an entry goes
into a word list, dictionary or knowledge base, its family goes in with it --
abbreviations, synonyms, spelling and spacing variants, plurals, and qualified forms
that mean something different -- and a pattern replaces a list where the variation is
productive. An analyzer tuned to 100% on the 40 messages it was built from found about
80% of what the next 40 asked.

And keep a set of inputs that is never tuned on, with expected results written down
before the analyzer runs on it: that score is the honest one.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Documents the two engine globals added in nlp-engine 3.8.4
(VisualText/nlp-engine PR: feat/run-mode-globals).

NLP++ previously had no way to ask which mode the engine was run in, so
analyzers hardcoded their diagnostic flags and no engine switch could
reach them. $dev lets a grammar gate its own debug passes on the caller's
intent:

    G("verbose") = G("$dev");

On parse-en-us that one line cut analysis time 40% in default mode while
leaving -DEV output intact.

Both pages record two things that are easy to get wrong:

  * -SILENT is not the opposite of -DEV. It selects the engine's quietest
    configuration, which suppresses the analyzer's OWN output files too,
    so a -SILENT run writes no out.txt at all. "Run fast but still write
    my results" is default mode plus $dev-gated diagnostics.

  * -SILENT is not a speed switch -- measured against default mode it made
    no difference (8.39 vs 8.41 sec), because the default already writes
    no dump files. The switch that costs real time is -DEV, at ~3.6x,
    because it dumps a full parse tree per pass (137 files / 44 MB for a
    9 KB input).

Added: Help/markdown/$dev.md, Help/markdown/$silent.md
Updated: the Special Variables table, and index.md under both the
Special Variables tree and the flat reference list.

check-help-docs.ps1: 0 broken links, 0 broken images, 0 table/index drift.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
(cherry picked from commit 6d61811)
@ddehilster
ddehilster merged commit 84a6d12 into VisualText:main Sep 14, 2026
1 check 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.

1 participant