UNPKG

tokenx

Version:

Fast token estimation with 95%+ average accuracy in a 2kB bundle

69 lines (68 loc) • 1.62 kB
{ "name": "tokenx", "type": "module", "version": "2.2.0", "packageManager": "pnpm@12.14.0", "description": "Fast token estimation with 95%+ average accuracy in a 2kB bundle", "author": "Johann Schopplich <hello@johannschopplich.com>", "license": "MIT", "homepage": "https://github.com/johannschopplich/tokenx#readme", "repository": { "type": "git", "url": "git+https://github.com/johannschopplich/tokenx.git" }, "bugs": { "url": "https://github.com/johannschopplich/tokenx/issues" }, "keywords": [ "ai", "cli", "llm", "token", "tokenizer", "estimation", "tiktoken", "anthropic", "openai" ], "sideEffects": false, "exports": { ".": { "types": "./dist/index.d.mts", "default": "./dist/index.mjs" } }, "types": "./dist/index.d.mts", "bin": { "tokenx": "bin/tokenx.mjs" }, "files": [ "bin", "dist" ], "scripts": { "build": "tsdown", "dev": "node ./src/cli/entry.ts --help", "bench": "node scripts/generate-bench.ts && automd", "bench:png": "node scripts/render-bench.ts", "lint": "eslint .", "lint:fix": "eslint . --fix", "test": "vitest", "test:types": "tsc --noEmit", "release": "bumpp" }, "devDependencies": { "@antfu/eslint-config": "^9.5.1", "@types/node": "^26.6.5", "ansis": "^4.4.0", "automd": "^0.4.3", "bumpp": "^12.3.0", "eslint": "^10.12.0", "eslint-flat-config-utils": "^3.2.0", "gpt-tokenizer": "^4.0.3", "tsdown": "^0.23.1", "typescript": "^6.0.3", "utilful": "^3.5.1", "vitest": "^5.0.5" } }