Skip to content

Overview

The Cosine CLI (command cos) is a powerful terminal interface that brings Cosine’s AI capabilities directly to your local development environment. With the CLI, you can have intelligent conversations about your code, automate tasks, and leverage external tools.

  • Interactive AI sessions — Start a terminal user interface (TUI) session where you can chat with Cosine about your codebase
  • One-shot tasks — Run single prompts without entering interactive mode
  • Repository analysis — Automatically analyse your repo structure and get AI-generated context files
  • Git-based change review — When Cosine edits files in a Git repository, it can create per-turn Agent Commits so changes stay visible, reviewable, and reversible
  • Quickstart — Install the CLI, sign in, and run your first task
  • Common Terms — Learn the key CLI terms used across the docs
  • Commands — Learn the main commands and look up global flags
  • Install & Authenticate — Full install methods, dependencies, and sign-in options
CommandUse it when
cos startYou want to open the TUI or run a one-shot task
cos loginYou need to sign in to your Cosine account
cos initYou want to set up repo-local CLI config files
cos mcpYou want to add or manage MCP servers
cos skillsYou want to install or manage reusable skills

For command syntax and examples, see Commands.

Terminal window
cos start
Terminal window
cos start --prompt "Explain the main function in main.go"

The CLI reads configuration from multiple sources (in order of precedence):

  1. Command-line flags (highest priority)
  2. Repository config (.cosine.toml or cosine.toml)
  3. User config (~/.cosine.toml)
  4. Environment variables
  5. Defaults (lowest priority)

You can create profile-specific configs:

  • cosine.<profile>.toml in repo (project-specific)
  • ~/.cosine.<profile>.toml in home (user-specific)

Use with: cos --profile <profile> start

The CLI shares the same customisation primitives as all other Cosine surfaces:

  • Skills — Reusable instruction packages
  • Plugins — Lua scripts that hook into agent events
  • Hooks — Automatic commands after file edits
  • Memory — Persistent project context
  • Modes — Manual, Auto, Plan, Swarm
  • Reasoning — Control depth and speed
  • Browser automation — Chrome DevTools Protocol
  • LSP manager — Install language servers
  • MCP — Connect external tools and APIs