# MyCoder-Mini

> A minimal TypeScript command-line agentic coder in under 200 lines that uses Anthropic's Claude to run shell commands for a given prompt.

MyCoder-Mini is an open-source, MIT-licensed experiment by Ben Houston in building a minimalist agentic coder. It is a TypeScript command-line tool that sends a user's prompt to Anthropic's Claude and lets the model run shell commands until the task is finished. The author describes it as less than 200 lines of code in a single file.

## What It Is

MyCoder-Mini is a command-line agent loop built on the Anthropic Claude SDK with native tool calling. The user supplies a prompt, Claude decides which shell commands to run, and the tool returns the results to the model. The author's blog post presents it as a way to show the foundational principles of agentic coding, and the README points to the full MyCoder project for a full-featured agentic coder.

## How the Agent Loop Works

The tool exposes two tools to the model: `shellCommand`, which runs shell commands, and `finished`, which signals completion. The loop repeats until Claude calls `finished`. Shell commands have a 10-second timeout to prevent hangs, and Claude's thinking process and command execution are displayed in real time. The blog post's example uses the claude-3-7-sonnet model.

## Setup Path

Users clone the repository, run `npm install` and `npm run build`, and can link the tool globally with `npm link`. An `ANTHROPIC_API_KEY` environment variable is required. The tool is then run as `mycoder-mini "your prompt"`, or via `npm start` or Node directly.

## Documented Limitations

The blog post lists these limitations: commands run synchronously, so long-running or interactive CLI processes are not handled; there is no browser integration; and the toolset is limited to shell commands.

## Features
- Uses Anthropic Claude SDK with native tool calling
- shellCommand tool for running shell commands
- finished tool to signal task completion
- 10-second timeout on shell commands
- Real-time display of Claude's thinking and command execution
- Under 200 lines of TypeScript
- MIT licensed

## Integrations
Anthropic Claude

## Platforms
API, CLI

## Pricing
Open Source

## Links
- Website: https://ben3d.ca/blog/minimal-agentic-coder
- Documentation: https://github.com/bhouston/mycoder-mini
- Repository: https://github.com/bhouston/mycoder-mini
- EveryDev.ai: https://www.everydev.ai/tools/mycoder-mini
