Anonymize your writing style. Zig WASM engine detects authorship markers, fine-tuned LLM rewrites to remove them. Runs entirely in-browser. fantasma.qstorage.quilibrium.com/
wasm privacy qwen zig
Zig 65.9%
TypeScript 23.0%
CSS 4.3%
Python 3.6%
HTML 2.0%
Shell 0.7%
JavaScript 0.4%
13 2 0

Clone this repository

https://tangled.org/metaend.eth.xyz/fantasma https://tangled.org/did:plc:thuylqmisypnmekwzfgymm3z/fantasma
git@tangled.org:metaend.eth.xyz/fantasma git@tangled.org:did:plc:thuylqmisypnmekwzfgymm3z/fantasma

For self-hosted knots, clone URLs may differ based on your setup.

Download tar.gz
README.md

Fantasma#

Anonymize your writing style. Zig WASM engine detects authorship markers, fine-tuned LLM rewrites to remove them. Runs entirely in-browser.

How it works#

  1. Paste text — the Zig engine extracts your stylometric fingerprint (punctuation habits, sentence length, vocabulary richness, contraction rate, function word frequencies, etc.)
  2. Analyze — each feature is compared against a neutral baseline; deviations >1 sigma are flagged as markers
  3. Neutralize — a fine-tuned Qwen3.5-0.8B rewrites your text to flatten flagged markers while preserving meaning
  4. Verify — the engine re-extracts features from the rewrite to confirm markers were actually removed

No server. No data leaves your machine. The WASM profiler loads instantly (~27KB); model weights download once and persist in IndexedDB.

Build#

Requires Zig 0.15.

# Native CLI
zig build
./zig-out/bin/fantasma profile "your text here"

# WASM (for browser)
zig build wasm

# Tests
zig build test

Stylometric features#

Category Features
Lexical avg word length, vocabulary richness (TTR), hapax ratio, avg syllables/word
Syntactic avg sentence length, sentence length variance, passive voice ratio
Punctuation semicolon, comma, colon, dash, exclamation, ellipsis, parenthetical rates
Structural avg paragraph length, sentence-opening distribution, contraction rate
Idiosyncratic British spelling, Oxford comma, hyphenation rate

Project structure#

src/
  main.zig                  # WASM exports + native CLI
  stylometry/
    extractor.zig            # Feature extraction from text
    baseline.zig             # Neutral baseline profiles (EN, ES)
    comparator.zig           # Compare profile vs baseline, flag markers
    verifier.zig             # Re-extract after rewrite, measure delta
  neutralizer/
    rewrite.zig              # Extract → prompt → infer → verify pipeline
    parser.zig               # Parse model output
    chunker.zig              # Split long texts at paragraph boundaries
  utils/
    json.zig                 # JSON parser/emitter
    allocator.zig            # WASM-compatible allocator
    unicode.zig              # UTF-8 handling, language detection
web/
  index.html                 # Catppuccin Mocha dark theme PWA
  app.js                     # WASM integration, UI logic
  style.css                  # Oat UI + custom styles

License#

MIT