Skip to main content

Terminus CLI

Terminus CLI is a CLI agent for terminal-based task execution. It can be used as a standalone tool, although it was primarily designed as a research-preview agent for evaluating the abilities of language models to power autonomous agents in the terminal.

Note that Terminus CLI is a fork of Terminus-2 agent, which is a built-in agent in terminal-bench. Terminus CLI 2.0.0 shows slightly better performance than Terminus-2 agent with openai/gpt-5 model on terminal-bench@2.0.0 benchmark. Different from Terminus-2, which by design runs its control logic outside task's container, Terminus CLI is a standalone library that runs entirely inside task's container.

Installation

Prerequisites

  • Python >=3.12
  • tmux (required for terminal session management)

Installing tmux

Terminus requires tmux to manage terminal sessions. Install it using your system's package manager:

macOS:

brew install tmux

Ubuntu/Debian:

sudo apt-get install tmux

Fedora:

sudo dnf install tmux

Arch Linux:

sudo pacman -S tmux

Install Terminus

uv tool install terminus-ai

or

pip install terminus-ai

Usage

Command Line Interface

Terminus provides a CLI for quick testing and demonstration:

# Basic usage
terminus "Create a file hello.txt with Hello World"

# With options
terminus "Create a file hello.txt" \
  --model openai/gpt-4o \
  --logs-dir ./logs \
  --parser json \
  --temperature 0.7

# Show help
terminus --help

Note:

  • The CLI runs directly on your local system using tmux (no Docker required)
  • Perfect for quick tasks, testing, and automation

Programmatic Usage

You can also use Terminus programmatically in Python:

from terminus import Terminus
from pathlib import Path

agent = Terminus(
    logs_dir=Path("./logs"),
    model_name="anthropic/claude-sonnet-4",
    parser_name="json",  # or "xml"
    temperature=0.7,
    max_turns=100,
    enable_summarize=True,
)

Configuration Options

  • model_name: The LLM model to use (required)
  • parser_name: Response format - "json" or "xml" (default: "json")
  • temperature: Sampling temperature (default: 0.7)
  • max_turns: Maximum number of agent turns (default: 1000000)
  • enable_summarize: Enable context summarization when limits are reached (default: True)
  • api_base: Custom API base URL (optional)
  • collect_rollout_details: Collect detailed token-level rollout data (default: False)

Metadata

Release files for terminus-ai 2.0.4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for terminus-ai 2.0.4
File Size Uploaded
terminus_ai-2.0.4.tar.gz 34.0 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for terminus-ai 2.0.4
File Interpreter ABI Platform
terminus_ai-2.0.4-py3-none-any.whl Python 3 none any Details

Total release size: 72.3 kB

Release files / terminus_ai-2.0.4.tar.gz

Download URL terminus_ai-2.0.4.tar.gz
Size 34.0 kB
Tags Source
SHA-256 checksum
How to use checksums
261e40aa7a82bfc9fc38cfdc057e32d423889b2602485d4bdd2aa8ab949c5dc7
BLAKE2b-256 checksum
How to use checksums
8be636c6da8ec7cd44762bc4dad3737a3e3f03be0dd9f0cea2a5bb2e0e9d0b01
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.9.8

Release files / terminus_ai-2.0.4-py3-none-any.whl

Download URL terminus_ai-2.0.4-py3-none-any.whl
Size 38.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
6298a78fdf85418e132674157132311ea26f14fd7891baae71c1d84186e921ac
BLAKE2b-256 checksum
How to use checksums
15fb31488e5a3b081017e729b185f40ab9846dad1b1b68b13cb954785e36d7f4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.9.8

Release history Release notifications | RSS feed

This release

2.0.4 This release

2 release files

2.0.3

2 release files

2.0.2

2 release files

2.0.1

2 release files

2.0.0

2 release files

1.0.0

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page