יום שישי, 9 באוקטובר 2026 LIVE
AI־INFO

כתבה Simon Willison ·

ttok 0.4

יצאה גרסה 0.4 של ttok, כלי קו-מפקד לספירת טוקנים המשתמש בספריית tiktoken של OpenAI. הגרסה החדשה כוללת תיקון לאזהרת Click ותמיכה בפקודה --list-models.
תקציר מקורי באנגלית<p><strong>Release:</strong> <a href="https://github.com/simonw/ttok/releases/tag/0.4">ttok 0.4</a></p> <p><code>ttok</code> is my CLI tool for counting tokens, using OpenAI's open source <a href="https://github.com/openai/tiktoken">tiktoken</a> library.</p> <p>It hasn't been in updated in a couple of years, but I finally fixed a Click warning, updated CI, and added a <code>--list-models</code> command to list available models.</p> <p>It works with <code>uvx</code>, so you can count tokens in anything like this:</p> <pre><code>cat file.txt | uvx ttok </code></pre> <p>Tags: <a href="https://simonwillison.net/tags/projects">projects</a>, <a href="https://simonwillison.net/tags/ai">ai</a>, <a href="https://simonwillison.net/tags/openai">openai</a>, <a href="https://simonwillison.net/tags/gene
קרא במקור המקורי