Clawd-Code  by GPT-AGI

Python CLI agent reimplementing Claude Code

Created 3 weeks ago

New!

278 stars

Top 93.2% on SourcePulse

GitHubView on GitHub
Project Summary

Summary

Clawd-Code is a Python reimplementation of the Claude Code agent, meticulously ported from its original TypeScript architecture. It targets developers and power users seeking a functional, Python-native AI agent with capabilities like tool-calling, streaming REPL, and session history. The project offers a production-oriented CLI agent, enabling users to fork, modify, and extend its functionality, providing a flexible platform for AI-driven workflows.

How It Works

The project employs a high-fidelity porting strategy, preserving the core architecture of Claude Code while adapting it to idiomatic Python. Its key components include a "Token Streaming + Tool-Aware Agent Loop" that manages tool execution and multi-turn conversations, and a "Programmable Skill Runtime" that allows extensibility via Markdown-defined skills (SKILL.md). This approach offers a familiar Claude Code experience within a Python environment, enhanced by a robust CLI and a flexible, declarative skill system.

Quick Start & Requirements

  • Primary install / run command: Clone the repository, create a Python 3.11+ virtual environment (e.g., using uv), activate it, and install dependencies with pip install -r requirements.txt. Configuration is done via python -m src.cli login, which guides users through setting up API keys for supported LLM providers. The REPL is started with python -m src.cli.
  • Non-default prerequisites and dependencies: Python 3.10+ (venv example uses 3.11). Requires API keys for LLM providers such as Anthropic, OpenAI, or Zhipu GLM.
  • Estimated setup time or resource footprint: Startup time is under 1 second, with memory usage under 50MB. Setup involves cloning, environment setup, dependency installation, and API key configuration.
  • Links: SETUP_GUIDE.md, CONTRIBUTING.md, TESTING.md, FEATURE_LIST.md.

Highlighted Details

  • Streaming Agent Experience: Features live token streaming for direct replies and richer output during tool-driven agent loops, with commands like /stream and /render-last.
  • Markdown-Based Skills: A programmable skill runtime uses SKILL.md files for defining slash commands, supporting arguments, tool limits, and both project-local and user-level skills.
  • Multi-Provider Support: Integrates with Anthropic Claude, OpenAI GPT, and Zhipu GLM, with an architecture designed for easy extension to other providers.
  • Extensive Tool System: Implements over 30 tools across categories like file operations, system commands, web fetching, and agent-specific tasks.

Maintenance & Community

The project is under "Active Development" with "New Features Weekly." Contributions are welcomed, with guidelines provided in CONTRIBUTING.md. While a "Real Community" is mentioned, specific links to community platforms like Discord or Slack are not present in the README.

Licensing & Compatibility

The project is released under the MIT License, which permits commercial use and integration into closed-source projects.

Limitations & Caveats

Development is ongoing for advanced features. Context building, including deeper project understanding beyond basic prompt injection, and the permission system are marked as "in progress" (Phase 3). Later phases (4 and 5) related to extensibility and Python-native differentiators are also in progress.

Health Check
Last Commit

2 weeks ago

Responsiveness

Inactive

Pull Requests (30d)
12
Issues (30d)
3
Star History
280 stars in the last 26 days

Explore Similar Projects

Starred by Chip Huyen Chip Huyen(Author of "AI Engineering", "Designing Machine Learning Systems") and Elvis Saravia Elvis Saravia(Founder of DAIR.AI).

DeepCode by HKUDS

0.3%
15k
AI agents transform ideas into production-ready code
Created 11 months ago
Updated 5 days ago
Feedback? Help us improve.