{"_id":"openai-gpt-token-counter","_rev":"23-f495172e6099382b39dff71eb034519a","name":"openai-gpt-token-counter","dist-tags":{"latest":"1.1.2"},"versions":{"1.0.0":{"name":"openai-gpt-token-counter","version":"1.0.0","keywords":["openai","gpt","gpt3","openai tokens","tokens","gpt3 tokens","gpt3 token counter","openai token counter","token gpt3"],"author":{"name":"CoderGautamYT"},"license":"ISC","_id":"openai-gpt-token-counter@1.0.0","maintainers":[{"name":"codergautam","email":"gautamgxtv@gmail.com"}],"dist":{"shasum":"d84835fd4740b0eba48ab99009a882bad2fbd37c","tarball":"https://registry.npmjs.org/openai-gpt-token-counter/-/openai-gpt-token-counter-1.0.0.tgz","fileCount":7,"integrity":"sha512-G8fylfeMOkvr0TRV/OPrm1bmr534ulIkqXIwuC+CXa9/l0v+g2fJdxTnHeUct9GWBBYIHfI/mgzGDADRJQraNg==","signatures":[{"sig":"MEYCIQD5JqFwu8hsSJ/aD6+Ma5/ovg5fDz6d+m3qkmFoWEH97wIhALsy36vFCOnkU1ADBAVyt0NH9n1aYLjj79AXM68EmAUK","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":9779,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjt19hACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmrElg//bjwNbydDKWlBieHrI0ASOIV8MDxmWHp9W2/qNP2VF9o9z4Lu\r\nWZFt3VuOMgxUaH3HBv1PR6NhzE7w3D5x1yCkHOXPj1rv24YzeBSV64//5EqV\r\nDA0CD1zDSbM2PaGs4dDubmVHmAAbtLCbSeKqtBZzIGy5U6RS+MFix2rulh09\r\nBHWB8CrhxpPDUNHibGIHS+hFhxJ96iLkJPKtWL9xFuHogEGbQSQI8YGhckDh\r\nzl5BJWe+EiUQEHyLvJvgB381GzbyIwiMD3Zxgbz04JbdKKY0Wab12ZSYKGEu\r\n5cdnVV4ubv9mgXBuu1sVCiT2fS8j+EoL5x4t5xAluB5n7j7qxqiBvdFeZjov\r\nNll5zjhGHj7EchD0gZ0rPnJLdTbVUYef2FQfI4NvLDQgpElvGM1tWUB1/wRw\r\nlQgiWAFrm4KXeKIaEc9eP+IbTWUx/7am6gBtmM0GCNxY/MFE6Z++7TEovhN5\r\nU5JykQvVqDMk/adI7VQOPa2EpumMo9OD6iev2FWWs6QWYQp3mJ62sBhuVhxL\r\nsLZWF9A//AZQbg9vegXpzHKTImYLVKTXS3wbYNWhwm+mJ9OTkNEES6MMDXmr\r\nKxV01Y9eqxcYtHB07cs8k9gWlHTL/0ahYuKOYexJqc9fKyRjKorNnELmx5NW\r\nZuBsKiym70C8ZZT15/qVfkky3mG8pUR7Vrk=\r\n=AKs6\r\n-----END PGP SIGNATURE-----\r\n"},"main":"src/index.js","gitHead":"bfca17783e73dc832b1442ca629be91eb17d3d5c","scripts":{"test":"node test"},"_npmUser":{"name":"codergautam","email":"gautamgxtv@gmail.com"},"deprecated":"Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.","_npmVersion":"8.19.2","description":"Find the highest value in an array!","directories":{},"_nodeVersion":"16.18.1","dependencies":{"gpt-3-encoder":"^1.1.3"},"_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/openai-gpt-token-counter_1.0.0_1672961889321_0.1802424400776086","host":"s3://npm-registry-packages"}},"1.0.1":{"name":"openai-gpt-token-counter","version":"1.0.1","keywords":["openai","gpt","gpt3","openai tokens","tokens","gpt3 tokens","gpt3 token counter","openai token counter","token gpt3"],"author":{"name":"CoderGautamYT"},"license":"ISC","_id":"openai-gpt-token-counter@1.0.1","maintainers":[{"name":"codergautam","email":"gautamgxtv@gmail.com"}],"dist":{"shasum":"3d1f0f1f278c94d50891b81ccbdd8ad1f52d53c1","tarball":"https://registry.npmjs.org/openai-gpt-token-counter/-/openai-gpt-token-counter-1.0.1.tgz","fileCount":7,"integrity":"sha512-eHXD2xot6Q8W3RnmmCaMoQoZbfH5aLvKPtsb33Md+G2rmeZxr0SjWVmO+CBPjFZKt29O3JtqSLqiktxJYqsMwg==","signatures":[{"sig":"MEQCIALkd3blAGAHynqvafQfglRAkowqAf2n2+50hGATd1KfAiBrAOeuhxyqCK5sCXHXgmbaXsgpytFg/sHJaAHZoPLfUQ==","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":9793,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjt1+XACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmr4FA//Q+h3jBMYuGnffAaG+bODcS1U6ccdxERhJ34oLGFEMWukfByJ\r\n8TQ7K7rwCL2EP+pVakY41Cjh5aXLQsZqdyY9dCqZ/rpdf2cbUhwfelyZMxcN\r\n5kg+p8f5fRjIXxcsc+YJp/qODqGUOSdGHRJ0RTwOX6nyQt2WNIoxZDnAXlRg\r\ndpOKn35nMOLWn26n2oxJkcTFUnw65sm3MDOjuQ6ygNpAAbDJGMj/KYPRcKpg\r\nm0oeV7o5x5Cz3NVC4hXSKgv6m9bqN2zBE8v15niVdpOdnB1YybbJ2t7jaTid\r\ngbwlU42NZGs/PD92h2hN4APZLfCK9+8IUzwyEL62ZakT8d8Xgkbl1qrNk7Xc\r\n+/q2SBSBANn/CkzNTY4UvpuHG7JRJF9562FdV/Cm2Y1z2xYa6TTKKwboq8L/\r\nfviNaAySWc5eJ9nVYGUUb/uN/Ksley2ALIczJMeEdggTqo0JrlpjGbaVmZeM\r\nta5W75Q1oNTiXgvTJbcDSEBIdWgzqQ1qcE/90sgy9FMGsGebgOrMNQDM6t48\r\n7Y9wdIcZGpySGSvicQ+htuRs3gGi0e7GDs5V6CA1OeqaGoDPEE+xANW5jMln\r\n4vvd2BaPdp793aYh+7N41ENOGjfIlexF/ytHTrr+ZuCRSq0vDVyFItL9lEuI\r\nl2OJKwVfB0TfiCTYhWQMT3vDF4o50qIvlCg=\r\n=WDOL\r\n-----END PGP SIGNATURE-----\r\n"},"main":"src/index.js","gitHead":"bfca17783e73dc832b1442ca629be91eb17d3d5c","scripts":{"test":"node test"},"_npmUser":{"name":"codergautam","email":"gautamgxtv@gmail.com"},"deprecated":"Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.","_npmVersion":"8.19.2","description":"Count the number of OpenAI GPT tokens in a string","directories":{},"_nodeVersion":"16.18.1","dependencies":{"gpt-3-encoder":"^1.1.3"},"_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/openai-gpt-token-counter_1.0.1_1672961943136_0.7682812097207232","host":"s3://npm-registry-packages"}},"1.0.2":{"name":"openai-gpt-token-counter","version":"1.0.2","keywords":["openai","gpt","gpt3","openai tokens","tokens","gpt3 tokens","gpt3 token counter","openai token counter","token gpt3"],"author":{"name":"CoderGautamYT"},"license":"ISC","_id":"openai-gpt-token-counter@1.0.2","maintainers":[{"name":"codergautam","email":"gautamgxtv@gmail.com"}],"dist":{"shasum":"6256ca0390277554f62f3f64a8bd0117ac7139df","tarball":"https://registry.npmjs.org/openai-gpt-token-counter/-/openai-gpt-token-counter-1.0.2.tgz","fileCount":7,"integrity":"sha512-WCfmH9+qo8MULndWrYdstn6N+/DzYSC7ZuQ9K0eqreiOurZiuDpg1ohiuLLVVVaB/dBbYhOGam3S22lYbf+ZIg==","signatures":[{"sig":"MEYCIQDbqFjXm58YAYTSjSuCIXXyUkofRiNbPe63PF7JTjL1FQIhAKI0GSI9SFzUlefWf50/7uKq4piN25DC2QIwUzkY3ZTR","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":9800,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjt1+9ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmrTRA//dLiRZQbNGqJ7i1YbtAsVJ2cS40JFz5GlD9LjqfkCmv4agRo4\r\nWUfWOuJWPS6TUvxYnXAalu0occupgDL7eDee8A1zEJ3jPeEBX8uI/F1sazsT\r\nl054gcPi0Ff7QqtAqTyjMBpyrjChYL11JHoUoDLuiY9oVYWZBioYCpO2806Q\r\noDQdjQq/NG24wYsCRsLmaIDQFCpomVDLL98LKqY199bB3nHQQIOvSAzBkXXk\r\nxRj/rr7SYTyEI0DJ3/tT8c3HUg6hObAGOzxwr4Ho8rSE0Ciy1aQ+QVr/ZZ5b\r\njUKGimJbMnty0XGRlx7LtOr2YXty4A7Ksha47vQu9uoxin8r8PKsLIzPU+tr\r\nNdmK4khr9ZvIyeGgCRvJ6ACPb4k4Hqd1rVD1mLj5C3WQRTkQEbIJCeaBUAwh\r\nCJkcXiktGj2j59TJTePAokv3F/Egyrn3P/BFv4acYZnmAk0MaT0YeiZP7N28\r\ngwbB8pfo+dsaSJaTEetqnnFRMVu0d/1NsNrhUhjPQcAcYSqeSPxZiwUWpeo9\r\ncSkFuYH093w+4q9kZllc8UC1VIzB4tCsRbz+SbZMJSVbJky8XbB3YlxEn/0x\r\n/xsc8R3s+05UpMRErj4kFqJ8lNwYwvx2M9Fvx8/RXnIpHllq79UcRvVeXK+F\r\nTBRPbyUPn21mxoD2Qylw9+Z/B2gJUmmPg3o=\r\n=LtSf\r\n-----END PGP SIGNATURE-----\r\n"},"main":"src/index.js","gitHead":"bfca17783e73dc832b1442ca629be91eb17d3d5c","scripts":{"test":"node test"},"_npmUser":{"name":"codergautam","email":"gautamgxtv@gmail.com"},"deprecated":"Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.","_npmVersion":"8.19.2","description":"Count the number of OpenAI GPT tokens in a string","directories":{},"_nodeVersion":"16.18.1","dependencies":{"gpt-3-encoder":"^1.1.3"},"_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/openai-gpt-token-counter_1.0.2_1672961981636_0.08839379169280015","host":"s3://npm-registry-packages"}},"1.0.3":{"name":"openai-gpt-token-counter","version":"1.0.3","keywords":["openai","gpt","gpt3","openai tokens","tokens","gpt3 tokens","gpt3 token counter","openai token counter","token gpt3"],"author":{"name":"CoderGautamYT"},"license":"ISC","_id":"openai-gpt-token-counter@1.0.3","maintainers":[{"name":"codergautam","email":"gautamgxtv@gmail.com"}],"dist":{"shasum":"9ca5ae5edf647343b795b01f7ccafbceacdc47e5","tarball":"https://registry.npmjs.org/openai-gpt-token-counter/-/openai-gpt-token-counter-1.0.3.tgz","fileCount":7,"integrity":"sha512-HJPY8rAvXQs+4n7RyP4kJXGHEKVvr7OL5khiIEHgqymosIY3lQKBH9SsX+BC2fg2h8Q61s1xxhEMhVI1uCL+cQ==","signatures":[{"sig":"MEYCIQC+lrM63Nz+6vSmAkgqbzPu/6IT4vZ6xYrTCsbLpMptKQIhAMe+3iUFOnKLyxB8QR8gvQS1Ow756lV+nzkC5YLXx7oO","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":9713,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjt2ASACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqhTw/+NSoiivJrdwbVGe1MVsDb2U1ccU7vmzKqm4wHiDtmebdz8RRY\r\njFHeMru1bDjFRMYYD6USTa9f6ffoWYYQOD1hxgH5K23RvGNb/oZ/TxX4Vfpw\r\nnP0bSKuB4IQDnNfPT+BnR2uPgAwnQ9Hgb3AH8a8kjm3ZxC+tM9wJdA5ZL9gU\r\nXEamRT/5JaDJXD4m3WzrzjPwEL+7Z1OuhJIuFzqeO71SY8MWVN0n0NEN2tnS\r\n15qidvUf5wTtJk0I8TC0hS1mr96DDZXhazx4YD3XEUMUvoZt9qzJ5kKk2KGl\r\nvBPi3+R51PNz4lAVXQjIWFp0Ale7EIlttIP5whuhfybWD/Plxv1F/ZZGXZA4\r\nM1lmvqHfCgMR3jP1XRGQOcZNq9pSXOCW/o1ZfL90Oz6HtGUfeWb3c5ODbq2w\r\nqH1U2gozU/z6c+O1CqhDYXG6Q/bVIThhmcxSQh/OGXXLU/U2hp3/rrD8HB+U\r\n/2q474Rz/Hx9si5TnxjDqynXuYnxES8RIQ77QC0+5lrqTFWmOzt4Adf0QvGe\r\nt4RLBWuUgvSqN32eYloMNEgFt/+BpzV3bPIt5rtM63Vqo01XJO0sWlcB73Fd\r\nOcOGmhiO6oRorOJW3UOVMBAxlkqoycRcr73uFueedCm3VgQyZ8azLfLT7Sez\r\nDRLBw5qo7NzA9m9qZ2kJAQBK3ZIS9WTCBSc=\r\n=aHk7\r\n-----END PGP SIGNATURE-----\r\n"},"main":"src/index.js","gitHead":"bfca17783e73dc832b1442ca629be91eb17d3d5c","scripts":{"test":"node test"},"_npmUser":{"name":"codergautam","email":"gautamgxtv@gmail.com"},"_npmVersion":"8.19.2","description":"Count the number of OpenAI GPT tokens in a string","directories":{},"_nodeVersion":"16.18.1","dependencies":{"gpt-3-encoder":"^1.1.3"},"_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/openai-gpt-token-counter_1.0.3_1672962065916_0.31768434535172707","host":"s3://npm-registry-packages"}},"1.0.4":{"name":"openai-gpt-token-counter","version":"1.0.4","keywords":["openai","gpt","gpt3","openai tokens","tokens","gpt3 tokens","gpt3 token counter","openai token counter","token gpt3"],"author":{"name":"CoderGautamYT"},"license":"ISC","_id":"openai-gpt-token-counter@1.0.4","maintainers":[{"name":"codergautam","email":"gautamgxtv@gmail.com"}],"dist":{"shasum":"b686fc263e2c326bd0230038523b36e91a4d0e6e","tarball":"https://registry.npmjs.org/openai-gpt-token-counter/-/openai-gpt-token-counter-1.0.4.tgz","fileCount":5,"integrity":"sha512-ETG3jTVNCQbVkVjhV0NcxoX17LAwI6QykIF75otuuGKvsPmYak0gPJVZpXo7sWIprrA75oqFpwuEW5szFjQNSA==","signatures":[{"sig":"MEUCIEiMrpgAew/TuG42XIJvD6PFQguQ7v/tpxvBvBZOzyn7AiEAzawFPnGRzzBhzwASdZvKa2WeGnZz1zu34egHiIrslBU=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":7244},"main":"src/index.js","gitHead":"d68ceedd2576afa6763fc5e6ad37832d54202c90","scripts":{"test":"node test"},"_npmUser":{"name":"codergautam","email":"gautamgxtv@gmail.com"},"deprecated":"Please use a newer version for better support and bug fixes.","_npmVersion":"9.5.1","description":"Count the number of OpenAI GPT tokens in a string","directories":{},"_nodeVersion":"18.16.0","dependencies":{"tiktoken":"^1.0.10","node-fetch":"^3.2.6","@types/node":"^18.0.6","gpt-3-encoder":"^1.1.4"},"_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/openai-gpt-token-counter_1.0.4_1690133163595_0.9141240482356936","host":"s3://npm-registry-packages"}},"1.0.5":{"name":"openai-gpt-token-counter","version":"1.0.5","keywords":["openai","gpt","gpt3","openai tokens","tokens","gpt3 tokens","gpt3 token counter","openai token counter","token gpt3"],"author":{"name":"CoderGautamYT"},"license":"ISC","_id":"openai-gpt-token-counter@1.0.5","maintainers":[{"name":"codergautam","email":"gautamgxtv@gmail.com"}],"homepage":"https://github.com/codergautam/openai-gpt-token-counter#readme","bugs":{"url":"https://github.com/codergautam/openai-gpt-token-counter/issues"},"dist":{"shasum":"98494cd485fb33a487695c9270bd59829d879f35","tarball":"https://registry.npmjs.org/openai-gpt-token-counter/-/openai-gpt-token-counter-1.0.5.tgz","fileCount":5,"integrity":"sha512-OESUhWb9rmD+qJSyfe0M03iZEeMRf9OQlXvucBC84g78tlWQMJHk9ApJhXi+2jd3FqPmFhbcWGxHhLZZTArrtQ==","signatures":[{"sig":"MEQCIDorELrFUyEohyL3faK6SmhqbBu7xe/XI7G7mTTPzoPIAiAylNWpvvZN6z3tE4gDOcWGg4onhg75OQNR3MTreAmGCw==","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":7359},"main":"src/index.js","gitHead":"ffc23b01c598c8962464fc68ea242bdcbb83b923","scripts":{"test":"node test"},"_npmUser":{"name":"codergautam","email":"gautamgxtv@gmail.com"},"deprecated":"Please use a newer version for better support and bug fixes.","repository":{"url":"git+https://github.com/codergautam/openai-gpt-token-counter.git","type":"git"},"_npmVersion":"9.5.1","description":"Count the number of OpenAI GPT tokens in a string","directories":{},"_nodeVersion":"18.16.0","dependencies":{"tiktoken":"^1.0.10","node-fetch":"^3.2.6","@types/node":"^18.0.6","gpt-3-encoder":"^1.1.4"},"_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/openai-gpt-token-counter_1.0.5_1690133229789_0.15508528233927898","host":"s3://npm-registry-packages"}},"1.0.6":{"name":"openai-gpt-token-counter","version":"1.0.6","keywords":["openai","gpt","gpt3","openai tokens","tokens","gpt3 tokens","gpt3 token counter","openai token counter","token gpt3"],"author":{"name":"CoderGautamYT"},"license":"ISC","_id":"openai-gpt-token-counter@1.0.6","maintainers":[{"name":"codergautam","email":"gautamgxtv@gmail.com"}],"homepage":"https://github.com/codergautam/openai-gpt-token-counter#readme","bugs":{"url":"https://github.com/codergautam/openai-gpt-token-counter/issues"},"dist":{"shasum":"d080e1437f9babf2d7f260d7f84e6eddaaecbfa8","tarball":"https://registry.npmjs.org/openai-gpt-token-counter/-/openai-gpt-token-counter-1.0.6.tgz","fileCount":5,"integrity":"sha512-E5PouPFYDJ+PWxajPAiiKB7/BIB8uOiwZE2PyBuqYE4T1sMNpneUczdjY8ZntlSEOWvzb7YMjrK/4qy4pFKiyA==","signatures":[{"sig":"MEQCIE7L8lPnG8MDZ6ahIw/cuhqSj5UdL7DSjsUcZ/fn/E7cAiArh5WAA2MpHE4ZXoQ1A7Lnl4+Rb7BYDQjr6E0Y1sfoLw==","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":7485},"main":"src/index.js","gitHead":"f40029c53a63718dc588b5054d31027043b4d8f9","scripts":{"test":"node test"},"_npmUser":{"name":"codergautam","email":"gautamgxtv@gmail.com"},"deprecated":"Please use a newer version for better support and bug fixes.","repository":{"url":"git+https://github.com/codergautam/openai-gpt-token-counter.git","type":"git"},"_npmVersion":"9.5.1","description":"Count the number of OpenAI GPT tokens in a string","directories":{},"_nodeVersion":"18.16.0","dependencies":{"tiktoken":"^1.0.10","node-fetch":"^3.2.6","@types/node":"^18.0.6","gpt-3-encoder":"^1.1.4"},"_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/openai-gpt-token-counter_1.0.6_1690133514489_0.34525076894490825","host":"s3://npm-registry-packages"}},"1.0.7":{"name":"openai-gpt-token-counter","version":"1.0.7","keywords":["openai","gpt","gpt3","openai tokens","tokens","gpt3 tokens","gpt3 token counter","openai token counter","token gpt3"],"author":{"name":"CoderGautamYT"},"license":"ISC","_id":"openai-gpt-token-counter@1.0.7","maintainers":[{"name":"codergautam","email":"gautamgxtv@gmail.com"}],"homepage":"https://github.com/codergautam/openai-gpt-token-counter#readme","bugs":{"url":"https://github.com/codergautam/openai-gpt-token-counter/issues"},"dist":{"shasum":"2fafe355fe51778a546b2ccfd5ba49e77cf271cf","tarball":"https://registry.npmjs.org/openai-gpt-token-counter/-/openai-gpt-token-counter-1.0.7.tgz","fileCount":5,"integrity":"sha512-A+zszCDyvl8VowAe2EQQPeGZspq8OssG0/3ipW5XMcrCjUqMHoahTKZsvgus4LRYAwk8Pwy1ZyRXqR2ZpsJAlg==","signatures":[{"sig":"MEUCIQCd+Xi+qLjLI0/UQVvIBblNCJGvThJTmSftd8cPtb3FfAIgFkemSANJ2pNbU84fMRiS3kS6TW1LRHD6ElBlaliE3fI=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":7438},"main":"src/index.js","gitHead":"df1baaf501456a2c7bfc5dafed8cb9fe2c9b24de","scripts":{"test":"node test"},"_npmUser":{"name":"codergautam","email":"gautamgxtv@gmail.com"},"deprecated":"Please use a newer version for better support and bug fixes.","repository":{"url":"git+https://github.com/codergautam/openai-gpt-token-counter.git","type":"git"},"_npmVersion":"9.5.1","description":"Count the number of OpenAI GPT tokens in a string","directories":{},"_nodeVersion":"18.16.0","dependencies":{"tiktoken":"^1.0.10","node-fetch":"^3.2.6","@types/node":"^18.0.6","gpt-3-encoder":"^1.1.4"},"_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/openai-gpt-token-counter_1.0.7_1690133678784_0.166926957803619","host":"s3://npm-registry-packages"}},"1.0.8":{"name":"openai-gpt-token-counter","version":"1.0.8","keywords":["openai","gpt","gpt3","openai tokens","tokens","gpt3 tokens","gpt3 token counter","openai token counter","token gpt3","gpt4","gpt4 tokens","gpt4 token counter","openai gpt4","gpt-3.5-turbo","gpt-4","gpt-4-32k","gpt-3.5-turbo tokens","gpt-3.5-turbo token counter","openai gpt-3.5-turbo","openai gpt-4","openai gpt-4-32k","openai gpt models","natural language processing","NLP","text generation","chatbot development","AI development","machine learning","language model","gpt token count","gpt tokens"],"author":{"name":"CoderGautamYT"},"license":"ISC","_id":"openai-gpt-token-counter@1.0.8","maintainers":[{"name":"codergautam","email":"gautamgxtv@gmail.com"}],"homepage":"https://github.com/codergautam/openai-gpt-token-counter#readme","bugs":{"url":"https://github.com/codergautam/openai-gpt-token-counter/issues"},"dist":{"shasum":"04c0547bacdb3fbc807f0444606be66717b7bf40","tarball":"https://registry.npmjs.org/openai-gpt-token-counter/-/openai-gpt-token-counter-1.0.8.tgz","fileCount":5,"integrity":"sha512-bWwoINIdd/SBkdoY6xJNhzcXjB8Y8JvxlYHcVnhBYY+hpkhb5HwK3wwT8Ze7r2vUPY8P5f0SMorTr4bLhoCOOQ==","signatures":[{"sig":"MEUCIEBICdxcUYDmwo7dhnMwB0trgpqrBSwdY1IeTZn0pk6UAiEAmNX1P4lAAQ6nqsXHsF99ma0fW+tE7Ufw6A4BWlYLORg=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":7930},"main":"src/index.js","gitHead":"bbb12dba30a54805b2370dcadf62028d9c5fa993","scripts":{"test":"node test"},"_npmUser":{"name":"codergautam","email":"gautamgxtv@gmail.com"},"deprecated":"Please use a newer version for better support and bug fixes.","repository":{"url":"git+https://github.com/codergautam/openai-gpt-token-counter.git","type":"git"},"_npmVersion":"9.5.1","description":"Count the number of OpenAI GPT tokens in a string","directories":{},"_nodeVersion":"18.16.0","dependencies":{"tiktoken":"^1.0.10","node-fetch":"^3.2.6","@types/node":"^18.0.6","gpt-3-encoder":"^1.1.4"},"_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/openai-gpt-token-counter_1.0.8_1690134083306_0.6653809027018665","host":"s3://npm-registry-packages"}},"1.0.9":{"name":"openai-gpt-token-counter","version":"1.0.9","keywords":["openai","gpt","gpt3","openai tokens","tokens","gpt3 tokens","gpt3 token counter","openai token counter","token gpt3","gpt4","gpt4 tokens","gpt4 token counter","openai gpt4","gpt-3.5-turbo","gpt-4","gpt-4-32k","gpt-3.5-turbo tokens","gpt-3.5-turbo token counter","openai gpt-3.5-turbo","openai gpt-4","openai gpt-4-32k","openai gpt models","natural language processing","NLP","text generation","chatbot development","AI development","machine learning","language model","gpt token count","gpt tokens"],"author":{"name":"CoderGautamYT"},"license":"ISC","_id":"openai-gpt-token-counter@1.0.9","maintainers":[{"name":"codergautam","email":"gautamgxtv@gmail.com"}],"homepage":"https://github.com/codergautam/openai-gpt-token-counter#readme","bugs":{"url":"https://github.com/codergautam/openai-gpt-token-counter/issues"},"dist":{"shasum":"a8c614139799a6404706c840e7ed5196069b12f0","tarball":"https://registry.npmjs.org/openai-gpt-token-counter/-/openai-gpt-token-counter-1.0.9.tgz","fileCount":5,"integrity":"sha512-peDUkhUbZzT4G/DO7yEqBTSPY0OXOha8wNtfAgyfhlV4bUMb4tECqKj3ceQiDvgQH6vxphppMlPNd4P1Qf2Jfw==","signatures":[{"sig":"MEUCIEeBv+968f9CjRWf2eaQBV4/LdOLMSTvYGQPjnyyis3aAiEAs+w6k2KHgQGYKU+t3FTX8jpYae1dbQ4gYZA/vdAWLEQ=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":8966},"main":"src/index.js","gitHead":"d18e622f2219b3a7fa7d51cb164ae0f78d00da5a","scripts":{"test":"node test"},"_npmUser":{"name":"codergautam","email":"gautamgxtv@gmail.com"},"deprecated":"Please use a newer version for better support and bug fixes.","repository":{"url":"git+https://github.com/codergautam/openai-gpt-token-counter.git","type":"git"},"_npmVersion":"9.5.1","description":"Count the number of OpenAI GPT tokens in a string","directories":{},"_nodeVersion":"18.16.0","dependencies":{"tiktoken":"^1.0.10","node-fetch":"^3.2.6","@types/node":"^18.0.6","gpt-3-encoder":"^1.1.4"},"_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/openai-gpt-token-counter_1.0.9_1690151174010_0.53604975194138","host":"s3://npm-registry-packages"}},"1.0.9-fixed":{"name":"openai-gpt-token-counter","version":"1.0.9-fixed","keywords":["openai","gpt","gpt3","openai tokens","tokens","gpt3 tokens","gpt3 token counter","openai token counter","token gpt3","gpt4","gpt4 tokens","gpt4 token counter","openai gpt4","gpt-3.5-turbo","gpt-4","gpt-4-32k","gpt-3.5-turbo tokens","gpt-3.5-turbo token counter","openai gpt-3.5-turbo","openai gpt-4","openai gpt-4-32k","openai gpt models","natural language processing","NLP","text generation","chatbot development","AI development","machine learning","language model","gpt token count","gpt tokens"],"author":{"name":"CoderGautamYT"},"license":"ISC","_id":"openai-gpt-token-counter@1.0.9-fixed","maintainers":[{"name":"codergautam","email":"gautamgxtv@gmail.com"}],"homepage":"https://github.com/codergautam/openai-gpt-token-counter#readme","bugs":{"url":"https://github.com/codergautam/openai-gpt-token-counter/issues"},"dist":{"shasum":"14b89a96b660feaa0927e9cee5472ca5b7581a1c","tarball":"https://registry.npmjs.org/openai-gpt-token-counter/-/openai-gpt-token-counter-1.0.9-fixed.tgz","fileCount":5,"integrity":"sha512-eplrEl4CvabCRpcoigBqRM8Yo+gC8AskY8QpRd4QdgDKkSpSnXJZ9N9GZXxh2seteCQEwAjpzEJ7HQj+Xoafhg==","signatures":[{"sig":"MEUCIG3gEOUn9lFU2kbCErC7l3Y/OM1L3TkYHroQrJCXDStpAiEA/fJ1GSPcwUqgc42yVZLSmTu6njs/KECPGmD3IiWv5Js=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":9468},"main":"src/index.js","gitHead":"0d8234cecccd95a76f1d3fd9ee1f1f7f7d8507b4","scripts":{"test":"node test"},"_npmUser":{"name":"codergautam","email":"gautamgxtv@gmail.com"},"repository":{"url":"git+https://github.com/codergautam/openai-gpt-token-counter.git","type":"git"},"_npmVersion":"9.5.1","description":"Count the number of OpenAI GPT tokens in a string","directories":{},"_nodeVersion":"18.16.0","dependencies":{"tiktoken":"^1.0.10","node-fetch":"^3.2.6","@types/node":"^18.0.6","gpt-3-encoder":"^1.1.4"},"_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/openai-gpt-token-counter_1.0.9-fixed_1690168981132_0.5959339692507564","host":"s3://npm-registry-packages"}},"1.0.9-cleaned":{"name":"openai-gpt-token-counter","version":"1.0.9-cleaned","keywords":["openai","gpt","gpt3","openai tokens","tokens","gpt3 tokens","gpt3 token counter","openai token counter","token gpt3","gpt4","gpt4 tokens","gpt4 token counter","openai gpt4","gpt-3.5-turbo","gpt-4","gpt-4-32k","gpt-3.5-turbo tokens","gpt-3.5-turbo token counter","openai gpt-3.5-turbo","openai gpt-4","openai gpt-4-32k","openai gpt models","natural language processing","NLP","text generation","chatbot development","AI development","machine learning","language model","gpt token count","gpt tokens"],"author":{"name":"CoderGautamYT"},"license":"ISC","_id":"openai-gpt-token-counter@1.0.9-cleaned","maintainers":[{"name":"codergautam","email":"gautamgxtv@gmail.com"}],"homepage":"https://github.com/codergautam/openai-gpt-token-counter#readme","bugs":{"url":"https://github.com/codergautam/openai-gpt-token-counter/issues"},"dist":{"shasum":"da2895c6aa00d22b895e40424e06808c35896176","tarball":"https://registry.npmjs.org/openai-gpt-token-counter/-/openai-gpt-token-counter-1.0.9-cleaned.tgz","fileCount":8,"integrity":"sha512-NrxRyYCgwui42vS/1jcslJmEnxHUxht7kp1XKczFYV3QCbquiKbPHcZCXEMo3X6j6pShR2R55kh7Ey4XAj1+FQ==","signatures":[{"sig":"MEUCIGsq63i0NNFLmhdTKN/1kbq5uNLACcYE9enn3XRQ5JYXAiEAnvtJxEwfWPvfm/T5b+Pq7L60OLLGTSPKUvCKEucIbDc=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":1511955},"main":"src/index.js","gitHead":"5f0e5dda3517c08f45748cb1803d59b7bc304345","scripts":{"test":"node test"},"_npmUser":{"name":"codergautam","email":"gautamgxtv@gmail.com"},"repository":{"url":"git+https://github.com/codergautam/openai-gpt-token-counter.git","type":"git"},"_npmVersion":"9.5.1","description":"Count the number of OpenAI GPT tokens in a string","directories":{},"_nodeVersion":"18.16.0","dependencies":{"tiktoken":"^1.0.10"},"_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/openai-gpt-token-counter_1.0.9-cleaned_1690293902903_0.2023292565072341","host":"s3://npm-registry-packages"}},"1.1.0":{"name":"openai-gpt-token-counter","version":"1.1.0","keywords":["openai","gpt","gpt3","openai tokens","tokens","gpt3 tokens","gpt3 token counter","openai token counter","token gpt3","gpt4","gpt4 tokens","gpt4 token counter","openai gpt4","gpt-3.5-turbo","gpt-4","gpt-4-32k","gpt-3.5-turbo tokens","gpt-3.5-turbo token counter","openai gpt-3.5-turbo","openai gpt-4","openai gpt-4-32k","openai gpt models","natural language processing","NLP","text generation","chatbot development","AI development","machine learning","language model","gpt token count","gpt tokens"],"author":{"name":"CoderGautamYT"},"license":"ISC","_id":"openai-gpt-token-counter@1.1.0","maintainers":[{"name":"codergautam","email":"gautamgxtv@gmail.com"}],"homepage":"https://github.com/codergautam/openai-gpt-token-counter#readme","bugs":{"url":"https://github.com/codergautam/openai-gpt-token-counter/issues"},"dist":{"shasum":"d0d0c8f7b86e63862a21f19db79790dc60f6a59c","tarball":"https://registry.npmjs.org/openai-gpt-token-counter/-/openai-gpt-token-counter-1.1.0.tgz","fileCount":9,"integrity":"sha512-3YloTdqK+HaCAgIKdY5L7bAgLO7TWYIsZC/nF4XtRJRL0FkRZ7kbruUGCBgU8PDdYLdARhoqlYKUCwOOfnNUag==","signatures":[{"sig":"MEUCIB5a+Ewf7H0PVx8/w6cCtQ7HN566t+jZ/zibC6CXU9k0AiEAo6aBWAUyMFg64U8DU4HMCQWtCZRnxfrI0W+jRmhNMzs=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":1512746},"main":"src/index.js","types":"./src/index.d.ts","gitHead":"576fa2291c26cba759b0bdac86cf51a00bcbf475","scripts":{"test":"node test"},"_npmUser":{"name":"codergautam","email":"gautamgxtv@gmail.com"},"repository":{"url":"git+https://github.com/codergautam/openai-gpt-token-counter.git","type":"git"},"_npmVersion":"9.5.1","description":"Count the number of OpenAI tokens in a string. Supports all OpenAI Text models (text-davinci-003, gpt-3.5-turbo, gpt-4)","directories":{},"_nodeVersion":"18.16.0","dependencies":{"tiktoken":"^1.0.10"},"_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/openai-gpt-token-counter_1.1.0_1691343008611_0.1937196944386197","host":"s3://npm-registry-packages"}},"1.1.1":{"name":"openai-gpt-token-counter","version":"1.1.1","keywords":["openai","gpt","gpt3","openai tokens","tokens","gpt3 tokens","gpt3 token counter","openai token counter","token gpt3","gpt4","gpt4 tokens","gpt4 token counter","openai gpt4","gpt-3.5-turbo","gpt-4","gpt-4-32k","gpt-3.5-turbo tokens","gpt-3.5-turbo token counter","openai gpt-3.5-turbo","openai gpt-4","openai gpt-4-32k","openai gpt models","natural language processing","NLP","text generation","chatbot development","AI development","machine learning","language model","gpt token count","gpt tokens"],"author":{"name":"CoderGautamYT"},"license":"ISC","_id":"openai-gpt-token-counter@1.1.1","maintainers":[{"name":"codergautam","email":"gautamgxtv@gmail.com"}],"homepage":"https://github.com/codergautam/openai-gpt-token-counter#readme","bugs":{"url":"https://github.com/codergautam/openai-gpt-token-counter/issues"},"dist":{"shasum":"661749ade60ce421f3064096193bc875d15cc0e1","tarball":"https://registry.npmjs.org/openai-gpt-token-counter/-/openai-gpt-token-counter-1.1.1.tgz","fileCount":9,"integrity":"sha512-kR+igUKHR01Ygm2BmUITAEAmVsOFcHS0KOnkRNjJR0YeSczJ+PYFjUpnE6TNRoqNPVINECVe5VfkxDAf8MU3eA==","signatures":[{"sig":"MEUCICZ4BkAUAsF5NF8FTw3nCA0N4oGPhQyWw4h/NAjOe6mDAiEA3y8JLjI/oTpGf6UdRFvn35tx5FkkVNBloAIl37f3oXU=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":1563775},"main":"src/index.js","types":"./src/index.d.ts","gitHead":"6b6127d37e89eb4a4e6ed96ccffa78d9a390aa87","scripts":{"test":"node test"},"_npmUser":{"name":"codergautam","email":"gautamgxtv@gmail.com"},"repository":{"url":"git+https://github.com/codergautam/openai-gpt-token-counter.git","type":"git"},"_npmVersion":"8.19.2","description":"Count the number of OpenAI tokens in a string. Supports all OpenAI Text models (text-davinci-003, gpt-3.5-turbo, gpt-4)","directories":{},"_nodeVersion":"18.12.1","dependencies":{"tiktoken":"^1.0.10"},"_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/openai-gpt-token-counter_1.1.1_1709266253989_0.4484279531852764","host":"s3://npm-registry-packages"}},"1.1.2":{"name":"openai-gpt-token-counter","version":"1.1.2","description":"Count the number of OpenAI tokens in a string. Supports all OpenAI Text models including GPT-5, GPT-4, GPT-3.5-turbo, and specialized models","main":"src/index.js","types":"src/index.d.ts","scripts":{"test":"node test"},"keywords":["openai","gpt","gpt3","openai tokens","tokens","gpt3 tokens","gpt3 token counter","openai token counter","token gpt3","gpt4","gpt4 tokens","gpt4 token counter","openai gpt4","gpt-3.5-turbo","gpt-4","gpt-4-32k","gpt-5","gpt-5-mini","gpt-5-nano","gpt-3.5-turbo tokens","gpt-3.5-turbo token counter","openai gpt-3.5-turbo","openai gpt-4","openai gpt-4-32k","openai gpt-5","openai gpt-5-mini","openai gpt-5-nano","openai gpt models","natural language processing","NLP","text generation","chatbot development","AI development","machine learning","language model","gpt token count","gpt tokens"],"author":{"name":"CoderGautamYT"},"license":"ISC","dependencies":{"tiktoken":"^1.0.22"},"repository":{"type":"git","url":"git+https://github.com/codergautam/openai-gpt-token-counter.git"},"_id":"openai-gpt-token-counter@1.1.2","gitHead":"173bf6081a29aec9cc3a8bc03a9d9729d1315ae3","bugs":{"url":"https://github.com/codergautam/openai-gpt-token-counter/issues"},"homepage":"https://github.com/codergautam/openai-gpt-token-counter#readme","_nodeVersion":"22.14.0","_npmVersion":"10.9.2","dist":{"integrity":"sha512-RwDHlGu8RB6sQtNDv49dP37ETj/6qBl9tdWo8/5G6C7g+xFfOdCHvu18oZldlmp6GlCPGpYnUUpzkxceryoZWQ==","shasum":"e87cdfa9b837b2b2d3ea572f10e762bf175fb5a2","tarball":"https://registry.npmjs.org/openai-gpt-token-counter/-/openai-gpt-token-counter-1.1.2.tgz","fileCount":10,"unpackedSize":1568145,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEQCIDevl487x17i/AQjAx+gwYrX1BkCOF4G/9mfMjr7yGnTAiBEDVZF8UWJYRC091129kLwo4OlbPd4YtIG/WMmt8C1/Q=="}]},"_npmUser":{"name":"codergautam","email":"gautamgxtv@gmail.com"},"directories":{},"maintainers":[{"name":"codergautam","email":"gautamgxtv@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/openai-gpt-token-counter_1.1.2_1759702853914_0.37566861779254923"},"_hasShrinkwrap":false}},"time":{"created":"2023-01-05T23:38:09.320Z","modified":"2025-10-05T22:20:54.307Z","1.0.0":"2023-01-05T23:38:09.485Z","1.0.1":"2023-01-05T23:39:03.285Z","1.0.2":"2023-01-05T23:39:41.798Z","1.0.3":"2023-01-05T23:41:06.100Z","1.0.4":"2023-07-23T17:26:03.754Z","1.0.5":"2023-07-23T17:27:09.962Z","1.0.6":"2023-07-23T17:31:54.635Z","1.0.7":"2023-07-23T17:34:38.988Z","1.0.8":"2023-07-23T17:41:23.469Z","1.0.9":"2023-07-23T22:26:14.172Z","1.0.9-fixed":"2023-07-24T03:23:01.288Z","1.0.9-cleaned":"2023-07-25T14:05:03.221Z","1.1.0":"2023-08-06T17:30:08.849Z","1.1.1":"2024-03-01T04:10:54.199Z","1.1.2":"2025-10-05T22:20:54.108Z"},"bugs":{"url":"https://github.com/codergautam/openai-gpt-token-counter/issues"},"author":{"name":"CoderGautamYT"},"license":"ISC","homepage":"https://github.com/codergautam/openai-gpt-token-counter#readme","keywords":["openai","gpt","gpt3","openai tokens","tokens","gpt3 tokens","gpt3 token counter","openai token counter","token gpt3","gpt4","gpt4 tokens","gpt4 token counter","openai gpt4","gpt-3.5-turbo","gpt-4","gpt-4-32k","gpt-5","gpt-5-mini","gpt-5-nano","gpt-3.5-turbo tokens","gpt-3.5-turbo token counter","openai gpt-3.5-turbo","openai gpt-4","openai gpt-4-32k","openai gpt-5","openai gpt-5-mini","openai gpt-5-nano","openai gpt models","natural language processing","NLP","text generation","chatbot development","AI development","machine learning","language model","gpt token count","gpt tokens"],"repository":{"type":"git","url":"git+https://github.com/codergautam/openai-gpt-token-counter.git"},"description":"Count the number of OpenAI tokens in a string. Supports all OpenAI Text models including GPT-5, GPT-4, GPT-3.5-turbo, and specialized models","maintainers":[{"name":"codergautam","email":"gautamgxtv@gmail.com"}],"readme":"# OpenAI GPT Token Counter\n\n![npm](https://img.shields.io/npm/dt/openai-gpt-token-counter)\n![DT](https://img.shields.io/badge/TypeScript%20Support-DT-blue)\n\nThis NPM package is designed to count the number of OpenAI tokens in a given an input messages array for all OpenAI models including the GPT-5 series models, and has been verified for 100% accuracy.\n\n## Installation\n\nYou can install the package using npm:\n\n```bash\nnpm install openai-gpt-token-counter\n```\n\n## Usage\n\n### Importing the Module\n\nFor CommonJS:\n\n```javascript\nconst openaiTokenCounter = require('openai-gpt-token-counter');\n```\n\nFor ES6 Imports:\n\n```javascript\nimport openaiTokenCounter from 'openai-gpt-token-counter';\n```\n\n\n### Counting Tokens in Chat Messages\n\nTo count the number of tokens in chat messages for a specific OpenAI chat model, use the `chat` method:\n\n```javascript\nconst messages = [\n  { role: \"user\", content: \"Say this is a test!\" },\n  // Add more messages if needed\n];\n\nconst model = \"gpt-5\"; // Replace with your desired OpenAI chat model\n\nconst tokenCount = openaiTokenCounter.chat(messages, model);\nconsole.log(`Token count: ${tokenCount}`);\n```\n### Example Messages Array for Chat Models\n\nFor chat models, provide an array of messages, where each message is an object with the following structure:\n\n```javascript\nconst messages = [\n  { role: \"system\", content: \"System prompt to guide the AI\" },\n  { role: \"user\", content: \"Message content from the user\" },\n  { role: \"assistant\", content: \"AI response to the user's message\" },\n  // Add more messages as needed\n];\n```\n\nThe `role` property can be one of `\"user\"`, `\"system\"`, or `\"assistant\"`. The `content` property holds the actual text of the message.\n\n## Supported Models\n\nThis package supports **all OpenAI chat/text models including GPT-5 and specialized models**, but the official ones we tested on are:\n### Chat Models\n- GPT5: `\"gpt-5\"`\n- GPT5 Mini: `\"gpt-5-mini\"`\n- GPT5 Nano: `\"gpt-5-nano\"`\n- GPT OSS 120B: `\"gpt-oss-120b\"`\n- GPT OSS 20B: `\"gpt-oss-20b\"`\n- O3 Deep Research: `\"o3-deep-research\"`\n- O4 Mini Deep Research: `\"o4-mini-deep-research\"`\n- GPT3.5 Turbo: `\"gpt-3.5-turbo\"`\n- GPT3.5 16K: `\"gpt-3.5-turbo-16k\"`\n- GPT4: `\"gpt-4\"`\n- GPT4 32K: `\"gpt-4-32k\"`\n\n### Text Models (deprecated)\n\n- GPT3 (text-davinci-003, text-curie-001, text-babbage-001, text-ada-001)\n\n### Counting Tokens in Text (deprecated)\n\nTo count the number of tokens in a text for a specific OpenAI text model (e.g. text-davinci-003), use the `text` method:\n\n```javascript\nconst text = \"This is a test sentence.\";\nconst model = \"text-davinci-003\"; // Replace with your desired OpenAI model\n\nconst tokenCount = openaiTokenCounter.text(text, model);\nconsole.log(`Token count: ${tokenCount}`);\n```\n\n\n\n## FineTuned Models\nUse the base model system to calculate the token count for fine-tuned models. For example, if you have a fine-tuned model based on `gpt-4`, you can use the `gpt-4` model to calculate the token count. Please report on the Github repository if you find any issues with fine-tuned models.\n\n## Accuracy\n\nThis module has been tested and verified for 100% accuracy against the OpenAI API's token count. Don't take my word for it, run `test-gpt5-accuracy.js` to see the accuracy verification.\n\n\n## Note on Embeddings\n\nPlease note that this package does not support embeddings. It is specifically designed for counting the number of tokens in text or chat messages for OpenAI models. Though this is on our roadmap, we do not have an ETA for when this feature will be added.\n\n## Issues and Contributions\n\nIf you encounter any issues or have suggestions for improvements, please feel free to open an issue on the [GitHub repository](https://github.com/codergautam/openai-gpt-token-counter). Thanks to the great [tiktoken](https://www.npmjs.com/package/tiktoken?activeTab=readme) library for providing the base tokenization logic.\n\n Contributions through pull requests are also welcome!\n","readmeFilename":"README.md"}