Skip to main content

Getting Started

Cody CLI is AINative Studio's AI-powered terminal coding assistant. It runs in your terminal and uses AI to help you write, refactor, and understand code.

Installation

npm (recommended)

npm install -g @ainative/cody-cli

npx (no install)

npx @ainative/cody-cli

curl installer (macOS / Linux)

curl -fsSL https://ainative.studio/install-cody.sh | sh

Homebrew

brew tap AINative-Studio/tap
brew install AINative-Studio/tap/cody

Authentication

Sign in with your AINative account:

cody auth login

Or set an API key directly:

export AINATIVE_API_KEY=your-sk-key
export AINATIVE_BASE_URL=https://api.ainative.studio

First Run

Interactive mode

cody

Single prompt

cody -p "Explain this codebase"

Print mode (pipe-friendly)

cody --print "What does this function do?"

Specify a model

cody --model qwen-coder-7b -p "Fix this bug"

Key Concepts

  • Tools — Cody can read/write files, run bash commands, search codebases, and more.
  • MCP Servers — Connect external tools via the Model Context Protocol.
  • Memory — Cody persists context across sessions automatically.
  • CODY.md — Place instructions for Cody in a CODY.md file at your project root.

Next Steps