Skip to main content

fastllm-claude-code

Use an authenticated Claude Code CLI as a FastLLM provider. The adapter runs models through fastclaude and supports streaming, non-streaming calls, and client-owned tool loops.

Your application executes tool requests and supplies the results in the next call. FastLLM replays canonical history after each tool round. fastclaude continues that history in a fresh process.

Usage

Installation

Install from PyPI:

pip install fastllm_claude_code

Or install from conda:

conda install -c AnswerDotAI fastllm_claude_code

For the latest source version:

pip install git+https://github.com/AnswerDotAI/fastllm-claude-code.git

Documentation

See the API documentation and source repository. Package listings are on PyPI and conda.

How to use

Installing the package registers the claude_code transport through FastLLM’s provider entry point. The Claude CLI must already be installed and authenticated for the current user.

Use the provider prefix in a FastLLM call:

from fastllm.acomplete import acomplete
from fastllm.types import sonn

answer = await acomplete('Answer briefly: what is 2+2?', model=f'claude_code/{sonn}')

For a client-owned tool loop, pass standard Responses API or Chat Completions function schemas. A response containing tool calls ends the turn. Execute the requests in your application, extend the history with their results, and call again.

Calls do not return a response id. Supply complete history each time and reuse prompt_cache_key to retain Claude’s account-context reminders:

first = await acomplete(messages, model=f'claude_code/{sonn}', tools=tools, prompt_cache_key='my-dialog')
assert first.tool_calls and first.response_id is None

final = await acomplete(messages_with_results, model=f'claude_code/{sonn}', tools=tools, prompt_cache_key='my-dialog')

Set stream=True for FastLLM’s normalized async stream. Non-streaming calls collect the same stream into one Completion. The adapter never executes tool requests.

Metadata

Release files for fastllm-claude-code 0.0.17

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

Source distribution (sdist)

Source distribution for fastllm-claude-code 0.0.17
File Size Uploaded Provenance Actions
fastllm_claude_code-0.0.17.tar.gz 9.5 kB Without provenance Details for fastllm_claude_code-0.0.17.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for fastllm-claude-code 0.0.17
File Interpreter ABI Platform Actions
fastllm_claude_code-0.0.17-py3-none-any.whl Python 3 none any Details for fastllm_claude_code-0.0.17-py3-none-any.whl

Total release size: 20.0 kB

Release files / fastllm_claude_code-0.0.17.tar.gz

Download URL fastllm_claude_code-0.0.17.tar.gz
Size 9.5 kB
Tags Source
SHA-256 checksum
How to use checksums
2e41e8f7085e483b30451e3ee0272baf9ebd438e0fe0de255b36d102caf893f1
BLAKE2b-256 checksum
How to use checksums
873efe50b3eace9590e0a4d3868835d31831d7f56521746b6ab0a17dcb29f4b8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.15

Release files / fastllm_claude_code-0.0.17-py3-none-any.whl

Download URL fastllm_claude_code-0.0.17-py3-none-any.whl
Size 10.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
1ed0cbe98cfcc8e3945c94e003c2c4057471e2814e4e9d06b0baecb3613b9d57
BLAKE2b-256 checksum
How to use checksums
961879e97034770cc9a5e168ace30347321a751ec07456bed3c9652aa3767853
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.15

Security for fastllm-claude-code 0.0.17

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.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

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