Getting Started

Installation

How to install AI Developer Assistant in your project.

Installation

AI Developer Assistant can be installed globally via npm or used locally in your project. Choose the installation method that best fits your workflow.

Install AI Developer Assistant globally to use it across all your projects:

npm install -g kg6-codex
You can also use pnpm, yarn, or bun instead of npm.

Local Installation

For project-specific usage, install locally:

# Clone the repository
git clone https://github.com/kg6-oss/kg6-codex.git
cd ai-developer-assistant

# Install dependencies
npm install

# Build the project
npm run build

Verify Installation

Check if the installation was successful:

ai-dev --version

You should see the version number and available commands.

Quick Setup

Option 1: OpenAI (Cloud)

# Set your OpenAI API key
export OPENAI_API_KEY="your-openai-api-key"

# Test the connection
ai-dev review --help

Option 2: Ollama (Local)

# Install Ollama (if not already installed)
curl -fsSL https://ollama.ai/install.sh | sh

# Pull a model
ollama pull llama2

# Test the connection
ai-dev review --help

Option 3: Gemini (Google AI)

# Get your API key from Google AI Studio
# https://makersuite.google.com/app/apikey

# Set your Gemini API key
export GEMINI_API_KEY="your-gemini-api-key"

# Test the connection
ai-dev review --help

First Command

Try your first AI Developer Assistant command:

# Review your latest changes
ai-dev review

# Or review specific files
ai-dev review --file-patterns "src/**/*.ts"

Configuration

Create a configuration file for persistent settings:

cp ai-dev.config.yaml ai-dev.config.local.yaml

Edit ai-dev.config.local.yaml with your preferences:

llm:
  provider: "gemini"  # or "openai" or "ollama"
  model: "gemini-2.0-flash"
  temperature: 0.7

gemini:
  apiKey: "${GEMINI_API_KEY}"

output:
  format: "console"
  colorize: true
  verbose: false
You're now ready to use AI Developer Assistant! Check out the Quick Start Guide for your first commands.