Claude2-PyAPI  by wwwzhouhui

Python API for Claude 2

created 2 years ago
318 stars

Top 86.3% on sourcepulse

GitHubView on GitHub
Project Summary

This Python API provides programmatic access to Anthropic's Claude 2 model, enabling developers to integrate Claude's conversational AI capabilities into their applications. It allows for creating new chat sessions, sending messages with or without attachments, managing conversation history, and resetting all dialogues. The project also offers integrations for various messaging platforms like WeChat, QQ, DingTalk, Lark, and WeChat Official Accounts, facilitating chatbot development.

How It Works

The API interacts with Claude 2 by leveraging reverse-engineered web interfaces, requiring users to provide their Claude AI cookies for authentication. It utilizes the requests library for HTTP communication and curl_cffi to simulate browser behavior, addressing potential network access issues and permission errors. The project supports proxy configurations for users in regions with restricted access to Claude's services.

Quick Start & Requirements

Highlighted Details

  • Supports sending messages with file attachments (PDF, DOC).
  • Offers integrations for multiple IM platforms (WeChat, QQ, DingTalk, Lark).
  • Includes Docker support for easier deployment and cookie management.
  • Implements proxy support to circumvent regional access restrictions.

Maintenance & Community

  • Active development with frequent version updates.
  • WeChat technical exchange group available.
  • Project acknowledges contributions from Claude-API and chatgpt-on-wechat.

Licensing & Compatibility

  • No explicit license mentioned in the README.
  • Requires user's Claude AI cookies, implying reliance on Anthropic's terms of service.

Limitations & Caveats

Access issues may arise if the user's IP address is not in an authorized region (e.g., UK or US). The API relies on reverse-engineered interfaces, which are subject to change by Anthropic, potentially breaking functionality. Debugging network and permission errors can be complex.

Health Check
Last commit

1 year ago

Responsiveness

1 day

Pull Requests (30d)
0
Issues (30d)
0
Star History
3 stars in the last 90 days

Explore Similar Projects

Feedback? Help us improve.