Tier 1: CLI Usage Guide

Command-line interface for the full Ralph Loop.


Basic Usage

cd src/tier1-ralph-loop
python ralph_loop.py

Command Options

# Custom task file
python ralph_loop.py --tasks my_tasks.json

# Add a task and run
python ralph_loop.py --add "Write a function to calculate factorial"

# Set confidence threshold (default: 0.7)
python ralph_loop.py --confidence 0.8

# Set max iterations (default: 50)
python ralph_loop.py --max-iterations 100

# Quiet mode
python ralph_loop.py --quiet

# Show stats only
python ralph_loop.py --stats-only

Adding Tasks

Via CLI

python ralph_loop.py --add "Explain quicksort"

Via Python

from task_manager import TaskManager

tm = TaskManager("tasks.json")
tm.add_task("Write a haiku about coding")

Viewing Status

python ralph_loop.py --stats-only

Output:

Task Statistics:
  Total: 5
  Pending: 2
  In Progress: 1
  Completed: 2
  Failed: 0

Example Session

$ python ralph_loop.py --add "Write a limerick about Python"
Added task: Write a limerick about Python

$ python ralph_loop.py
=== Starting Ralph Loop ===
Processing: Write a limerick about Python
...
Confidence: 0.95 - Accepted!
=== Complete: 1 done, 0 failed ===

Next Steps


← Back to Tutorials

Back to top

8me Showcase - AI Agent Orchestration Learning Platform

This site uses Just the Docs, a documentation theme for Jekyll.