Reminix adapter for Anthropic
Project description
reminix-anthropic
Reminix Runtime adapter for the Anthropic API. Deploy Claude models as a REST API.
Installation
pip install reminix-anthropic
This will also install reminix-runtime as a dependency.
Quick Start
from anthropic import AsyncAnthropic
from reminix_anthropic import wrap
from reminix_runtime import serve
# Create an Anthropic client
client = AsyncAnthropic()
# Wrap it with the Reminix adapter
agent = wrap(client, name="my-claude", model="claude-sonnet-4-20250514")
# Serve it as a REST API
serve([agent], port=8080)
Your agent is now available at:
POST /agents/my-claude/invoke- Stateless invocationPOST /agents/my-claude/chat- Conversational chat
API Reference
wrap(client, name, model, max_tokens)
Wrap an Anthropic client for use with Reminix Runtime.
| Parameter | Type | Default | Description |
|---|---|---|---|
client |
AsyncAnthropic |
required | An Anthropic async client |
name |
str |
"anthropic-agent" |
Name for the agent (used in URL path) |
model |
str |
"claude-sonnet-4-20250514" |
Model to use |
max_tokens |
int |
4096 |
Maximum tokens in response |
Returns: AnthropicAdapter - A Reminix adapter instance
System Messages
The adapter automatically handles Anthropic's system message format. System messages in your request are extracted and passed as the system parameter to the API.
# This works automatically:
request = {
"messages": [
{"role": "system", "content": "You are a helpful assistant"},
{"role": "user", "content": "Hello!"}
]
}
Endpoint Input/Output Formats
POST /agents/{name}/invoke
Stateless invocation for task-oriented operations.
Request:
{
"input": {
"prompt": "Summarize this text: ..."
}
}
Or with messages:
{
"input": {
"messages": [
{"role": "system", "content": "You are a helpful assistant."},
{"role": "user", "content": "Hello!"}
]
}
}
Response:
{
"output": "Hello! How can I help you today?"
}
POST /agents/{name}/chat
Conversational chat with message history.
Request:
{
"messages": [
{"role": "system", "content": "You are a helpful assistant."},
{"role": "user", "content": "What is the capital of France?"}
]
}
Response:
{
"output": "The capital of France is Paris.",
"messages": [
{"role": "system", "content": "You are a helpful assistant."},
{"role": "user", "content": "What is the capital of France?"},
{"role": "assistant", "content": "The capital of France is Paris."}
]
}
Runtime Documentation
For information about the server, endpoints, request/response formats, and more, see the reminix-runtime package.
Links
License
Apache-2.0
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 reminix_anthropic-0.0.1.tar.gz.
File metadata
- Download URL: reminix_anthropic-0.0.1.tar.gz
- Upload date:
- Size: 6.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.9.25 {"installer":{"name":"uv","version":"0.9.25","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
da50ff477bce4bbd91af915828edbfd1feeb4855fc9da5c0527295e92a4a4da4
|
|
| MD5 |
7066909633e723ec74da1f95a469db20
|
|
| BLAKE2b-256 |
48d98780fa0d94d7b4d17d095602177144826564020b268ad502151ab5a36bf3
|
File details
Details for the file reminix_anthropic-0.0.1-py3-none-any.whl.
File metadata
- Download URL: reminix_anthropic-0.0.1-py3-none-any.whl
- Upload date:
- Size: 4.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.9.25 {"installer":{"name":"uv","version":"0.9.25","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
42e24322cbde5b13383e7c4bdb4168fd4280f8bca15f59b3948ff47c48a442a3
|
|
| MD5 |
0a333d9ee4dc1e24343e548a34a0d471
|
|
| BLAKE2b-256 |
02272eadcee013a72c32cc2052ff5cb8e91fb4de47940c892099151468c40466
|