GitHunt
HI

hissain/mini-agent

A mini agent with working agentic loop

mini-agent

Minimal implementation of a coding assistant, capable of reading, writing, and editing files, as well as running shell commands.

Requirements

  • Python 3.x
  • An API key for one of the supported providers:
    • Google Gemini
    • Anthropic
    • OpenRouter

Installation

  1. Clone the repository:

    git clone https://github.com/hissain/mini-agent.git
    cd mini-agent
  2. Install dependencies (standard library only, no external pip packages required).

Configuration

Set the environment variable for your chosen provider:

  • For Google Gemini:

    export GEMINI_API_KEY="your-key-here"
  • For Anthropic:

    export ANTHROPIC_API_KEY="your-key-here"
  • For OpenRouter:

    export OPENROUTER_API_KEY="your-key-here"

Optionally, you can specify the model:

export MODEL="gemini-2.0-flash"

Usage

Run the agent:

python agent.py

Commands

  • /q or exit: Quit the application.
  • /c: Clear the conversation history.
  • /i: Show system information.

Inspired by nanocode

Languages

Python100.0%

Contributors

MIT License
Created January 15, 2026
Updated January 15, 2026