← Explore all skills

EVIDENCE AND EVALUATION / Undominated.ai

Undominated · Tokenizer density audit

Audit tokenizer vocabulary density, tokens-per-word / tokens-per-byte expansion ratios, and real effective text processing costs.

“Audit tokenizer vocabulary density, tokens-per-word / tokens-per-byte expansion ratios, and real effective text processing costs.”

01 / THE REASONING

Why this made the selection.

  • Pairs a bounded workflow with an offline Python checker and explicitly synthetic example inputs.
  • Created for recurring evidence and comparison failures: missing facts remain unknown and every conclusion keeps its scope.
  • It names a concrete failure mode: Tokenize corpus with candidate models' tokenizers, recording generated token counts.

02 / THE REVIEW RECORD

What we actually inspected.

Source review has boundaries.
A clear record is more useful than a “safe” badge.

Material inspected

  • skills/undominated-tokenizer-density-audit/SKILL.md
  • skills/undominated-tokenizer-density-audit/scripts/check.py
  • skills/undominated-tokenizer-density-audit/examples/synthetic.json

Our findings

  • First-party resource authored by Undominated.ai; this is our own verification record, not an independent endorsement.
  • The download preserves the complete source and supporting files. Its manifest hashes identify the exact bytes.
  • One input rule the file states is: `ratePerMillionTokens`: non-negative decimal string.
  • One condition that blocks a pass is: {item['model']}: tokensPerWord {tokens_per_word} exceeds maxTokensPerWord {max_tpw}.

Not established by this review

  • Model compliance with these instructions on arbitrary tasks
  • Native integration in every agent host
  • Public GitHub source identity
  • Remote installation through the standard Skills CLI
  • The new npm resource CLI installation

The review applies to the material and revision named here. A newer upstream release can change its behavior.

03 / PUT IT TO WORK

Add a skill to your workflow.

Upstream setup instructions ↗
  1. Download the complete bundle from https://undominated.ai/resources/skills/undominated-tokenizer-density-audit/bundle.zip and extract it into a new directory.
  2. Place the extracted directory at .agents/skills/undominated-tokenizer-density-audit/ or your host's documented skills directory. Preserve SKILL.md, scripts, examples and licence files together.
  3. Run the documented synthetic example from the skill directory with Python 3.10 or later before using your own evidence.

Before you start

  • An Agent Skills compatible host
  • Python 3.10 or later for the optional checker

THE COMPLETE REVIEWED DEFINITION

Read it before you reuse it.

Original source bytes, with attribution.
Review the host-specific setup notes above.

# Tokenizer Density Audit

Audit tokenizer vocabulary density, tokens-per-word / tokens-per-byte expansion ratios, and real effective text processing costs across different tokenizers (cl100k, o200k, Llama 3, Qwen, Claude BPE).

## Workflow

1. Measure raw corpus metrics: word count, character count, byte count.
2. Tokenize corpus with candidate models' tokenizers, recording generated token counts.
3. Compute density metrics:
   - Tokens per word: $D_w = \text{Tokens} / \text{Words}$
   - Bytes per token: $D_b = \text{Bytes} / \text{Tokens}$
4. Calculate effective text cost per million words:
   $$\text{Cost per Million Words} = D_w \times \text{Rate per Million Tokens}$$
5. Compare baseline vs candidate: reveal whether a nominally cheaper per-token model actually costs more to process the exact same text due to vocabulary inefficiency.

## Synthetic Input Format

JSON object with:
- `schemaVersion`: 1
- `benchmarkCorpus`:
  - `name`: string
  - `wordCount`: positive integer
  - `byteCount`: positive integer
- `evaluations`: list of objects, each containing:
  - `model`: string
  - `tokenizer`: string
  - `tokenCount`: positive integer
  - `ratePerMillionTokens`: non-negative decimal string
- `assertions`:
  - `maxTokensPerWord`: optional decimal string
  - `minBytesPerToken`: optional decimal string

## Exit Codes

- `0`: Validation passed and assertions satisfied.
- `1`: Assertion failed.
- `2`: Invalid input format or safety violation.

## Verification

```sh
python3 scripts/check.py examples/synthetic.json
```

The download contains SKILL.md. Extract the whole bundle; the supporting files are required. Inspect the included MANIFEST.json for file hashes.

By Undominated.ai. Exact upstream source ↗ · Licence · Attribution

SHA-256 943370e18040cb1fe3185dc5a42dd7101d0f6fb620f5ff7f4f459e6c11290a28

Read the applicable licence
MIT License

Copyright (c) 2026 Undominated.ai

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

04 / FOLLOW THE EVIDENCE

The source trail.

Our notes are separate from the original resource.
Check upstream before adopting a new version.

  1. https://undominated.ai/resources/skills/undominated-tokenizer-density-audit/definition.md

    Supports: Workflow and input requirements, Stated limitations

  2. MIT licence ↗Checked

    https://undominated.ai/resources/skills/undominated-tokenizer-density-audit/LICENSE.txt

    Supports: Redistribution terms and attribution

  3. Complete source bundle ↗Checked

    https://undominated.ai/resources/skills/undominated-tokenizer-density-audit/bundle.zip

    Supports: Full local source, supporting files and integrity manifest

Evidence & Ask