Skip to main content
Archived

This project has been archived by its maintainers, and is no longer receiving any updates.

Loadout — selects the skills each turn needs from a larger catalog

Per-turn skill selection for LangChain and deepagents agents: the model sees the few skills it needs, not a catalog of hundreds.

CI PyPI Python License: MIT

Quick start · Results · Documentation · Contributing


Why Loadout

Large skill catalogs take up context on every model call. Loadout ranks and verifies skills for each user turn, then loads the relevant instructions or suggests candidates. The agent can also search the catalog with find_skill.

Focused context
Confidence determines what gets loaded or suggested. Every threshold is configurable.

Independent turns
No skill state to carry between turns. No checkpointer or additional storage required.

Your choice of judge
Use the included Jev adapter or implement the small Judge interface.

Graceful fallback
Decision timeouts and transient judge failures restore the full catalog. Configuration errors surface explicitly.

Quick start

1. Install. Requires Python 3.11+. The jev extra includes the judge adapter and its SDK.

pip install "langchain-loadout[jev]"

2. Connect your skills. Place them in ./skills/<name>/SKILL.md with name and description in YAML front matter. Set TYPESAFE_API_KEY and your model provider's credentials (ANTHROPIC_API_KEY for this example).

from deepagents import create_deep_agent
from deepagents.backends import FilesystemBackend

from langchain_loadout.langchain import LoadoutSkillsMiddleware
from langchain_loadout.providers.jev import JevJudge

backend = FilesystemBackend(root_dir=".", virtual_mode=True)
loadout = LoadoutSkillsMiddleware(backend=backend, sources=["/skills/"], judge=JevJudge())

agent = create_deep_agent(
    model="anthropic:claude-sonnet-4-5",
    backend=backend,
    skills=["/skills/"],
    middleware=[loadout],
)
await agent.ainvoke({"messages": [{"role": "user", "content": "I need a statement for the embassy"}]})

Run the example in an async context. Selection runs on ainvoke and astream; synchronous calls use the ordinary skills middleware. Tune thresholds and questions through Settings.

The public API is evolving: minor releases may introduce breaking changes while the version is 0.x.

Results

Measured on a bank-statement assistant using deepagents: 236 skills, 250 turns.

Metric With Loadout Full catalog
Correct skill selected 86% 57%
Skills section 5,648 characters 89,150 characters
Input tokens per turn 34,131 111,864
Answer accuracy 86% 86%

These results use generated data, one judge and one agent model. Selection added roughly 3 seconds on this catalog; total cost per turn was slightly higher because changing prompts reduced cache reuse. Fit thresholds to your own data. Measurement context and limits →

Documentation

Read Covers
How it works Selection flow, judge interface, settings and trade-offs
Development guide Architecture, Python conventions and testing
Contributing Local setup, checks, issues and pull requests
Changelog Release history

License

MIT © 2026 Ivan Deyna

Release files for langchain-loadout 0.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for langchain-loadout 0.1.1
File Size Uploaded
langchain_loadout-0.1.1.tar.gz 16.1 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for langchain-loadout 0.1.1
File Interpreter ABI Platform
langchain_loadout-0.1.1-py3-none-any.whl Python 3 none any Details

Total release size: 37.6 kB

Release files / langchain_loadout-0.1.1.tar.gz

Download URL langchain_loadout-0.1.1.tar.gz
Size 16.1 kB
Tags Source
SHA-256 checksum
How to use checksums
903b6b2fe267e39499f425ca61ca74c82433e9918c36e3ba0513f86d6854b4de
BLAKE2b-256 checksum
How to use checksums
bea2f8c0a3c285d8c9510134072f76379451c2a19e249a9c5530dc3a10a0d2c7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 20, 2026.

Transparency log

Release files / langchain_loadout-0.1.1-py3-none-any.whl

Download URL langchain_loadout-0.1.1-py3-none-any.whl
Size 21.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
1ef6b0280aec44decc03f3b009024f04f73fb506ca6aaff348b2017fcc4a56fa
BLAKE2b-256 checksum
How to use checksums
b7e5827a67523f65611e36ca512d787209c97b37998ef5521312686298e17264
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 20, 2026.

Transparency log
Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page