Metadata-Version: 2.4
Name: axemere-gateway-langchain
Version: 0.1.0
Summary: Axemere AI Gateway LangChain integration — ChatAiGateway BaseChatModel
License: MIT
Requires-Python: >=3.11
Requires-Dist: axemere-gateway>=0.1.0
Requires-Dist: httpx>=0.27.0
Requires-Dist: langchain-core>=0.3.0
Description-Content-Type: text/markdown

# axemere-gateway-langchain

LangChain `BaseChatModel` integration for the [Axemere AI Gateway](https://axemere.ai). Drop `ChatAiGateway` into any LangChain chain or agent — the gateway adds cost controls, policy enforcement, and an append-only audit ledger to every call.

## Install

```bash
pip install axemere-gateway-langchain
```

## Usage

```python
from axemere.gateway.langchain import ChatAiGateway

llm = ChatAiGateway(provider="openai", model="gpt-4o-mini")
# reads AXEMERE_GATEWAY_URL + AXEMERE_WORKLOAD_TOKEN from env

response = llm.invoke("Hello")
print(response.content)
```

Works anywhere a LangChain `BaseChatModel` is accepted — chains, agents, LCEL pipelines.

## Configuration

| Env var | Description |
|---------|-------------|
| `AXEMERE_GATEWAY_URL` | Gateway base URL, e.g. `http://localhost:7080` |
| `AXEMERE_WORKLOAD_TOKEN` | Workload token issued by the gateway |

## Links

- [Axemere AI Gateway](https://axemere.ai)
- [Documentation](https://axemere.ai/docs)
- [GitHub](https://github.com/Axemere-LLC/axemere-python)

## License

MIT
