- examples/demo.mjs: live demo (5 single messages up to 5 people with rare auto-coined attributes + 5 escalating multi-turn conversations with long-range back-references); self-references the package via exports - examples/RESULTS.md: its generated output (10 examples) - examples/.env.example + examples/README.md; `npm run example` script - README: replace the long examples section with two representative examples (dense 5-person message + 6-turn conversation) and a badge/link to examples/RESULTS.md for the full set - eslint ignores examples/**, prettier ignores generated examples/RESULTS.md, .gitignore un-ignores .env.example Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
992 B
992 B
Live example
demo.mjs runs @mobiletic/anonymizer against a real
OpenAI-compatible LLM (built with Gemma 4 via Infomaniak) on a set of fictional
Swiss e-learning chats: 5 single messages of rising complexity (up to 5 people,
with rare attributes the model must coin itself) and 5 multi-turn conversations
(with long-range back-references across turns). It writes the formatted output to
RESULTS.md.
This is a live example, not a CI unit test — it needs an API key and calls a real endpoint. The deterministic test suite lives in
../test.
Run
cd ..
npm install
npm run build # examples/demo.mjs imports the built package
cp examples/.env.example examples/.env # then fill in your endpoint + key
npm run example # → regenerates examples/RESULTS.md
examples/.env is git-ignored. All personal data in the scripts and results is
fictional, generated for demonstration.