Claude Token Counter

from blog Simon Willison's Weblog, | ↗ original
Claude Token Counter Anthropic released a token counting API for Claude a few days ago. I built this tool for running prompts, images and PDFs against that API to count the tokens in them. The API is free (albeit rate limited), but you'll still need to provide your own API key in order to use it. Here's the source code. I built this using two...