IronHive CLI - Universal CLI Agent Core for AI-powered automation
Install
No framework information available.
README
ironhive-cli
Universal CLI Agent Core
A foundation tool for AI-powered automationβnot just coding, but any task that benefits from intelligent command execution.
Philosophy
Do one thing well.
Receive a command. Plan. Execute. Return.
βββββββββββββββββββββββββββββββββββββββββββ
β External Systems β
β CI/CD Β· Schedulers Β· Orchestrators β
ββββββββββββββββββββββ¬βββββββββββββββββββββ
β invoke
βΌ
βββββββββββββββββββββββββββββββββββββββββββ
β ironhive-cli β
β Command β Plan β Execute β Done β
ββββββββββββββββββββββ¬βββββββββββββββββββββ
β MCP
βΌ
βββββββββββββββββββββββββββββββββββββββββββ
β Plugins (MCP Servers) β
β code-beaker Β· memory-indexer Β· ... β
βββββββββββββββββββββββββββββββββββββββββββ
Installation
# Install as dotnet tool
dotnet tool install -g IronHive.Cli
# Or build from source
git clone https://github.com/iyulab/ironhive-cli
cd ironhive-cli
git submodule update --init --recursive
dotnet build
Quick Start
# Interactive mode
ironhive
# Single command
ironhive -p "Write a README for this project"
# JSON output (for programmatic use)
ironhive -p "Hello" --output json
# Streaming JSON Lines
ironhive -p "Hello" --output jsonl
# Plain text (no ANSI)
ironhive -p "Hello" --plain
Session Management
# Continue most recent session
ironhive -c
# Resume specific session
ironhive -r <session-id>
# List sessions
ironhive sessions list
ironhive sessions list --output json
Model Configuration
# Environment variables
export GPUSTACK_ENDPOINT=http://localhost:8080/v1
export GPUSTACK_API_KEY=your-key
export GPUSTACK_MODEL=gpt-4o-mini
# Or OpenAI
export OPENAI_API_KEY=sk-xxx
Configuration
Configuration is merged in order (later overrides earlier):
- Global:
~/.ironhive/config.yaml - Project:
.ironhive/config.yaml - Environment:
IRONHIVE_*,GPUSTACK_*,OPENAI_* - .env file: Project root
.env
# .ironhive/config.yaml
limits:
maxSessionTokens: 100000
maxSessionCost: 10.00
context:
compactionThreshold: 0.92
goalReminderEnabled: true
CLAUDE.md Support
Place a CLAUDE.md file in your project root for automatic agent instructions.
Core Library Integration
Use IronHive.Cli.Core for direct .NET integration:
// Add to your project
<PackageReference Include="IronHive.Cli.Core" />
// Configure with DI
services.AddIronHiveWithOpenAI(apiKey, "gpt-4o-mini");
// Or
services.AddIronHiveWithOllama("llama3.2");
// Use
var agentLoop = serviceProvider.GetRequiredService<IAgentLoop>();
var response = await agentLoop.RunAsync("Hello");
// Streaming
await foreach (var chunk in agentLoop.RunStreamingAsync("Hello"))
{
Console.Write(chunk.TextDelta);
}
See samples/console-chat for a complete example.
Samples
| Sample | Path | Description |
|---|---|---|
| Console Chat | samples/console-chat/ |
Core library direct integration |
| Web Chat | samples/web-ai-chat/ |
Next.js + CLI subprocess |
# Console Chat
cd samples/console-chat
dotnet run
# Web Chat
cd samples/web-ai-chat
npm install && npm run dev
Development
Requirements
- .NET 10 SDK
- Git (with submodules)
Build & Test
git submodule update --init --recursive
dotnet build
dotnet test
Project Structure
ironhive-cli/
βββ src/
β βββ IronHive.Cli.Core/ # Core library (NuGet)
β β βββ Agent/ # AgentLoop, modes
β β βββ Extensions/ # DI helpers
β β βββ Session/ # Session management
β β βββ Tools/ # Built-in tools
β βββ IronHive.Cli/ # CLI application
βββ samples/
β βββ console-chat/ # .NET Core integration
β βββ web-ai-chat/ # Next.js + subprocess
βββ tests/
βββ submodules/
βββ TokenMeter/ # Token counting
βββ ToolCallParser/ # tool_call parsing
Related Projects
- ironhive β LLM abstraction
- ironbees β Multi-agent management
- memory-indexer β Semantic memory MCP
- code-beaker β Code execution platform
License
MIT
Changes from Previous Version
Adoption Assessment
Assess this package against its supported frameworks, license, maintenance signals and dependency graph before making it a project standard.
Related Guides & Workflows
Learn how to evaluate, integrate, or audit this package in your .NET project.