LangChain tools for the Unstructured Transform MCP server: parse, enrich, chunk, and embed files for RAG and AI pipelines.
Project description
langchain-unstructured-transform
LangChain tools for the Unstructured Transform MCP server. Load the hosted Transform tools as native LangChain tools and hand them to any LangChain or LangGraph agent to parse, enrich, chunk, and embed files (PDF, DOCX, images, and 70+ file types) for RAG and AI pipelines.
This package is a thin, opinionated wrapper around
langchain-mcp-adapters: it fixes the
Transform MCP server URL and bearer-token authentication so you don't have to configure the
client by hand.
Installation
pip install -U langchain-unstructured-transform
Requirements
- Python 3.10 or later.
- An Unstructured API key. Get an API key.
Set your key as an environment variable (recommended):
export UNSTRUCTURED_API_KEY="<your-unstructured-api-key>"
Quickstart
import asyncio
from langchain.agents import create_agent
from langchain_unstructured_transform import aget_transform_tools
async def main() -> None:
tools = await aget_transform_tools() # reads UNSTRUCTURED_API_KEY
agent = create_agent("claude-sonnet-4-6", tools)
response = await agent.ainvoke(
{
"messages": [
{
"role": "user",
"content": (
"Use the Unstructured Transform tools to parse ./report.pdf. "
"Provide the results as JSON."
),
}
]
}
)
print(response["messages"][-1].content)
if __name__ == "__main__":
asyncio.run(main())
Toolkit
from langchain_unstructured_transform import UnstructuredTransformToolkit
toolkit = UnstructuredTransformToolkit(api_key="...") # or rely on the env var
tools = await toolkit.aget_tools()
Synchronous usage
For scripts and notebooks that are not already inside an event loop:
from langchain_unstructured_transform import get_transform_tools
tools = get_transform_tools()
Tools
The Transform MCP server exposes the following tools, which drive the full parsing lifecycle:
request_file_upload_url— get a URL to upload a source file.transform_files— start a transform job for uploaded files.check_transform_status— poll a running job.get_transform_results— fetch the partitioned/enriched/chunked/embedded output.
Limits
- Each file must be a supported file type.
- Each file must be 50 MB or less.
- Each request may contain 10 files or fewer.
- Only 5 requests can run at a time.
License
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 langchain_unstructured_transform-0.1.0.tar.gz.
File metadata
- Download URL: langchain_unstructured_transform-0.1.0.tar.gz
- Upload date:
- Size: 7.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.11.20 {"installer":{"name":"uv","version":"0.11.20","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d8ba8f744027376a36a483e7581134ef9cff521b6a9e2569c77d194b9e94c59c
|
|
| MD5 |
1941aed8da99750ec5024c159e97be01
|
|
| BLAKE2b-256 |
bb5c271bfd2250fdf1e2d3413788210a17dfc2c6d8fdc6b98b9180e531eb3739
|
File details
Details for the file langchain_unstructured_transform-0.1.0-py3-none-any.whl.
File metadata
- Download URL: langchain_unstructured_transform-0.1.0-py3-none-any.whl
- Upload date:
- Size: 5.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.11.20 {"installer":{"name":"uv","version":"0.11.20","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
48921ccb5fcee921f1ae811a3a12404d90186f769862be78fe504dc62f00b7a4
|
|
| MD5 |
19a55c691e2b120963a00ffc9f802957
|
|
| BLAKE2b-256 |
7a678949ce38e3ec5227430460064d1cde19be14e8e3ac8b31a2ff14864ebf29
|