{"library":"tokencost","type":"library","category":null,"description":"tokencost is a Python library that provides client-side token counting and USD cost estimation for over 400 Large Language Models (LLMs) from providers like OpenAI, Anthropic, Google, and AWS Bedrock. It helps AI agents and LLM applications accurately track and manage API expenses by offering up-to-date pricing and model-specific tokenization, released frequently to reflect changing LLM provider costs.","language":"python","status":"active","version":"0.1.26","tags":["llm","cost-estimation","token-counting","openai","anthropic","aws-bedrock","ai-agents","llm-ops"],"last_verified":"Fri May 22","install":[{"cmd":"pip install tokencost","imports":["from tokencost import calculate_prompt_cost","from tokencost import calculate_completion_cost"]}],"homepage":null,"github":"https://github.com/AgentOps-AI/tokencost","docs":null,"changelog":null,"pypi":"https://pypi.org/project/tokencost/","npm":null,"openapi_spec":null,"status_page":null,"smithery":null,"compatibility":{"summary":{"python_range":"3.10–3.9","success_rate":100,"avg_install_s":8.4,"avg_import_s":2.51,"wheel_type":"wheel"},"url":"https://checklist.day/v1/registry/tokencost/compatibility"}}