Metadata-Version: 2.4
Name: leaxp
Version: 0.0.2
Summary: Agentic experience kit — package and distribute agent skills as portable .xp files.
Project-URL: Homepage, https://leaxp.com
Project-URL: Repository, https://github.com/vunone/leaxp
Project-URL: Issues, https://github.com/vunone/leaxp/issues
Author: Leaxp Authors
License-Expression: Apache-2.0
License-File: LICENSE.txt
Keywords: agent,ai,experience,llm,mcp,rag,skill
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: Apache Software License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
Classifier: Topic :: Software Development :: Libraries
Classifier: Typing :: Typed
Requires-Python: >=3.11
Requires-Dist: anyio>=4.7.0
Requires-Dist: fastmcp>=2.0.0
Requires-Dist: httpx>=0.28.0
Requires-Dist: litellm>=1.55.0
Requires-Dist: platformdirs>=4.3.0
Requires-Dist: pydantic>=2.10.0
Requires-Dist: rich>=13.9.0
Requires-Dist: tomli-w>=1.1.0
Requires-Dist: typer>=0.15.0
Provides-Extra: all
Requires-Dist: chromadb>=0.5.0; extra == 'all'
Requires-Dist: lancedb>=0.16.0; extra == 'all'
Requires-Dist: qdrant-client>=1.12.0; extra == 'all'
Requires-Dist: sentence-transformers>=3.3.0; extra == 'all'
Provides-Extra: chroma
Requires-Dist: chromadb>=0.5.0; extra == 'chroma'
Provides-Extra: lancedb
Requires-Dist: lancedb>=0.16.0; extra == 'lancedb'
Provides-Extra: local-embed
Requires-Dist: sentence-transformers>=3.3.0; extra == 'local-embed'
Provides-Extra: qdrant
Requires-Dist: qdrant-client>=1.12.0; extra == 'qdrant'
Description-Content-Type: text/markdown

# Leaxp

![Leaxp](https://raw.githubusercontent.com/vunone/leaxp/main/docs/assets/hero.png)

[![CI](https://github.com/vunone/leaxp/actions/workflows/ci.yml/badge.svg)](https://github.com/vunone/leaxp/actions/workflows/ci.yml)
[![codecov](https://codecov.io/gh/vunone/leaxp/branch/main/graph/badge.svg)](https://codecov.io/gh/vunone/leaxp)
[![PyPI](https://img.shields.io/pypi/v/leaxp.svg)](https://pypi.org/project/leaxp/)
[![Python](https://img.shields.io/pypi/pyversions/leaxp.svg)](https://pypi.org/project/leaxp/)
[![License](https://img.shields.io/pypi/l/leaxp.svg)](https://github.com/vunone/leaxp/blob/main/LICENSE.txt)

> **Lea**rn -> e**xp**erience — an agentic experience kit. Package and distribute agent skills as portable, deduplicated, model-agnostic `.xp` files.

Leaxp learns agent skills from examples (text, code, images) and packages them into `*.xp` files that any agent can load and recall via MCP. Smaller context, cheaper inference, model-agnostic.

> Status: pre-alpha bootstrap.

## Install

```bash
# minimal
pip install leaxp

# with the local-first stack (Chroma + sentence-transformers)
pip install "leaxp[chroma,local-embed]"

# everything
pip install "leaxp[all]"
```

## Quickstart

```bash
exp init                                    # configure providers + create leaxp.toml
exp learn ./docs --goal "use leaxp"         # extract records, embed, store
exp try ./docs/index.md --goal "use leaxp"  # debug a single doc
exp forge                                   # cluster, consolidate, dedupe (optional)
exp build my-skill.xp                       # export to a portable .xp
exp load my-skill.xp                        # load + locally re-embed
exp mcp --port 8822                         # serve via MCP for any agent
exp use --local 8822 --claude               # wire MCP into Claude Code
```

## Concepts

- **Claim** — undisputable fact the agent must know but cannot modify.
- **Hint** — adjustable best-practice the agent can adapt to context.
- **Recall** — the MCP tool agents call; returns records grouped by `Useful WHEN: <condition>`.
- **`.xp` file** — zip with a manifest + JSONL of raw records (no embeddings). Embeddings are computed locally on `exp load` so the same pack works with any embedding model.

## Project structure

See [CLAUDE.md](https://github.com/vunone/leaxp/blob/main/CLAUDE.md) for the package architecture overview.

## Development

```bash
uv sync                                  # create venv, install deps
uv run pre-commit install                # enable hooks
uv run ruff check . && uv run pyright    # lint + typecheck
uv run pytest --cov                      # tests with coverage
uv run exp --help
```

## License

Apache-2.0 — see [LICENSE.txt](https://github.com/vunone/leaxp/blob/main/LICENSE.txt).
