LangChain integrations for the TokenSqueezer x402 LLM token compression API
Project description
tokensqueezer-tools
PyPI client for TokenSqueezer — x402-gated LLM token compression.
pip install "tokensqueezer-tools[x402,langchain]"
# also available via monorepo:
# pip install "nodeproxy-tools[tokensqueezer]"
export EVM_PRIVATE_KEY=0x...
from tokensqueezer_tools import TokenSqueezerClient
client = TokenSqueezerClient()
result = client.compress("Long noisy agent feed text…", aggressive=True)
print(result.stats.tokens_saved, result.compressed[:200])
from tokensqueezer_tools.langchain import TokenSqueezerTool
tool = TokenSqueezerTool()
tool.invoke({"text": "Raw RSS firehose blob…"})
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file tokensqueezer_tools-0.1.0.tar.gz.
File metadata
- Download URL: tokensqueezer_tools-0.1.0.tar.gz
- Upload date:
- Size: 4.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fef9177d210620e31b95b898ec657011543ca15e3409ca01f6256397656d1fe1
|
|
| MD5 |
edd7308ac8bc28be69e878ce727b7491
|
|
| BLAKE2b-256 |
c18ff93f11790eb2df3883edd6960f4123532cad04d20e704b0db7bc69240f9f
|
File details
Details for the file tokensqueezer_tools-0.1.0-py3-none-any.whl.
File metadata
- Download URL: tokensqueezer_tools-0.1.0-py3-none-any.whl
- Upload date:
- Size: 6.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9bb118e63488650c760db8e514a716f93870d265eb6b5739ab87f4cc9dbf8e99
|
|
| MD5 |
d2af06a1203fc0efd998e575f354f1cc
|
|
| BLAKE2b-256 |
4263d52461ddb69c72be84f677b255874cadb33c836885061f6225a7975bed44
|