claudette  by AnswerDotAI

SDK for Anthropic Claude automation, extending the Python SDK

Created 1 year ago
308 stars

Top 87.3% on SourcePulse

GitHubView on GitHub
Project Summary

Claudette is a Python wrapper designed to simplify interactions with Anthropic's Claude API. It addresses the verbosity and manual effort often required by the base SDK, offering an automated, high-level interface for developers. Key features include stateful chat management, simplified tool use, image handling, and prefill capabilities.

How It Works

Claudette leverages a "literate nbdev" approach, where the source code is embedded within detailed Jupyter Notebooks. This methodology aims to make the code more understandable and educational, explaining the "why" behind the implementation. The library provides a Chat class for conversational state management and a Client for structured output generation, abstracting away much of the boilerplate associated with API calls.

Quick Start & Requirements

  • Install via pip: pip install claudette
  • Requires an ANTHROPIC_API_KEY environment variable.
  • Supports Anthropic's models (e.g., Claude 3 Opus, Sonnet, Haiku).
  • Detailed documentation and source code are available in the project's Jupyter Notebooks.

Highlighted Details

  • Stateful Chat class for managing conversation history.
  • Streamlined support for Claude's Tool Use API with docments for ergonomic function definition.
  • structured client method for extracting specific data types from LLM responses.
  • Image handling capabilities, allowing prompts with both text and image data.
  • Optional "extended thinking" feature (maxthinktok) for enhanced reasoning on complex tasks.

Maintenance & Community

The project is presented as the first "literate nbdev" project, emphasizing educational code. Further community or maintenance details are not explicitly detailed in the README.

Licensing & Compatibility

The README does not specify a license. Compatibility for commercial use or closed-source linking would require clarification on licensing terms.

Limitations & Caveats

The README does not specify any limitations or known issues. The project's novelty as the first "literate nbdev" project might imply a smaller community or less battle-testing compared to more established libraries.

Health Check
Last Commit

3 days ago

Responsiveness

1+ week

Pull Requests (30d)
2
Issues (30d)
2
Star History
7 stars in the last 30 days

Explore Similar Projects

Starred by Chip Huyen Chip Huyen(Author of "AI Engineering", "Designing Machine Learning Systems") and Yaowei Zheng Yaowei Zheng(Author of LLaMA-Factory).

AstrBot by AstrBotDevs

1.1%
15k
LLM chatbot/framework for multiple platforms
Created 3 years ago
Updated 14 hours ago
Feedback? Help us improve.