nanocode  by 1rgs

Agentic CLI for file operations and shell commands

Created 2 weeks ago

New!

1,710 stars

Top 24.6% on SourcePulse

GitHubView on GitHub
Project Summary

Minimalist agentic coding assistant, serving as a direct alternative to more complex Claude Code setups. It empowers developers with a zero-dependency tool for integrated file management, code searching, and shell command execution directly within their terminal, streamlining development workflows.

How It Works

Nanocode operates as a self-contained Python script, ingeniously built using Claude Code itself and then capable of self-replication. It implements a full agentic loop, parsing user input to determine intent and orchestrating a suite of integrated tools. This allows for direct file manipulation (read, write, edit), directory traversal and searching (glob, grep), and execution of arbitrary shell commands (bash). Its core advantage lies in its extreme minimalism and zero-dependency nature, making it highly portable and easy to deploy.

Quick Start & Requirements

  • Installation: No installation required; download the single nanocode.py file.
  • Prerequisites: An Anthropic API key must be set as an environment variable (export ANTHROPIC_API_KEY="your-key").
  • Usage: Run the script using python nanocode.py.
  • Tools: read, write, edit, glob, grep, bash.

Highlighted Details

  • Extreme Minimalism: A single Python file, approximately 250 lines of code, with zero external dependencies.
  • Self-Referential Development: Initially built with Claude Code, it can then be used to build itself, showcasing a meta-development capability.
  • Full Agentic Loop: Supports conversational interaction and task execution via an integrated toolset.
  • Comprehensive Toolset: Includes file I/O (read, write, edit), file system searching (glob, grep), and shell command execution (bash).
  • User Experience: Features colored terminal output for improved readability and command feedback.

Maintenance & Community

No information available in the provided text.

Licensing & Compatibility

  • License: MIT License.
  • Compatibility: Permissive MIT license generally allows for commercial use and integration into closed-source projects.

Limitations & Caveats

Relies heavily on the Anthropic API, requiring an API key and incurring potential costs. Functionality is limited to the tools provided within the single script. The "must be unique" constraint for the edit tool could be a limitation for complex edits.

Health Check
Last Commit

1 week ago

Responsiveness

Inactive

Pull Requests (30d)
9
Issues (30d)
2
Star History
1,729 stars in the last 16 days

Explore Similar Projects

Feedback? Help us improve.