ttok
A command-line token counting tool based on the tiktoken library that counts the number of tokens in text and supports zero-install execution via uvx.
Timeline (last 90 days)
Simon Willison's token counting tool ttok has officially released version 1.0.
As a command-line tool, ttok's main use is to quickly count the number of tokens in text within the terminal.
After releasing ttok 0.4, Simon Willison ran 'uv tool upgrade ttok' to upgrade the tool and found that the tool still used GPT-4's tokenizer by default.
ttok 0.4 版本修复了长期存在的 Click 警告并更新了 CI 流程。
ttok 支持通过 uvx 在不显式安装的情况下直接运行,例如 cat file.txt | uvx ttok。
Simon Willison 发布了 ttok 0.4 版本。
ttok 在 0.4 版本发布前已经约两年没有更新。
ttok 的模型列表更新往往滞后于 OpenAI 发布新模型,因为需要人工维护模型别名到 encoding 的映射表。
执行 uvx ttok 时,uv 会先解析 ttok 的最新版本,将其安装到隔离的、由 uv 统一管理的缓存环境中,然后运行入口脚本,不会污染当前项目的虚拟环境。
ttok 是一个基于 OpenAI 开源 tiktoken 库构建的命令行工具,用于统计文本的 token 数量。
1 more timeline events
All Facts (11)
As a command-line tool, ttok's main use is to quickly count the number of tokens in text within the terminal.
50%Unverifiedttok 是一个基于 OpenAI 开源 tiktoken 库构建的命令行工具,用于统计文本的 token 数量。
50%Unverifiedttok 的模型列表更新往往滞后于 OpenAI 发布新模型,因为需要人工维护模型别名到 encoding 的映射表。
50%Unverifiedttok 支持通过 uvx 在不显式安装的情况下直接运行,例如 cat file.txt | uvx ttok。
50%Unverified执行 uvx ttok 时,uv 会先解析 ttok 的最新版本,将其安装到隔离的、由 uv 统一管理的缓存环境中,然后运行入口脚本,不会污染当前项目的虚拟环境。
50%Unverifiedttok 在 0.4 版本发布前已经约两年没有更新。
50%Unverifiedttok 0.4 版本修复了长期存在的 Click 警告并更新了 CI 流程。
50%UnverifiedAfter releasing ttok 0.4, Simon Willison ran 'uv tool upgrade ttok' to upgrade the tool and found that the tool still used GPT-4's tokenizer by default.
50%UnverifiedSimon Willison's token counting tool ttok has officially released version 1.0.
50%Unverifiedttok 0.4 版本新增了 --list-models 命令,用于列出当前支持的模型列表。
50%UnverifiedSimon Willison 发布了 ttok 0.4 版本。
50%