Krave CLI

raw JSON →
2.1.1 verified Sat May 09 auth: no javascript

A terminal-native AI coding assistant CLI that connects to proprietary AI models (Krave 4.1 and Krave 4.2) for real-time code generation, debugging, file management, and system automation. Currently at version 2.1.1, released on npm with a focus on CLI-based development. It operates directly in the shell, providing real system access through tools like bash, writefile, spawn, webSearch, and webFetch. Key differentiators: dual-model architecture, autonomous subagents, persistent session management with auto-save/resume, and zero runtime dependencies. Requires Node.js >=18.0.0 and a terminal with Unicode/ANSI color support.

error ERR_REQUIRE_ESM: require() of ES Module not supported
cause Using CommonJS require() to import krave-cli, which is ESM-only since v2.
fix
Replace require('krave-cli') with dynamic import: const { default: krave } = await import('krave-cli');
error Error: KRAVE_API_KEY is not set
cause Missing API key environment variable.
fix
Set KRAVE_API_KEY in your shell: export KRAVE_API_KEY='your-api-key'
error Error: Node version must be >=18.0.0
cause Running krave-cli on an older Node.js version.
fix
Upgrade Node.js to version 18 or later using nvm or your package manager.
breaking ESM-only package — require() will throw ERR_REQUIRE_ESM
fix Use import statement instead of require(). If using CommonJS, use dynamic import: import('krave-cli').then(m => m.default(...)).
breaking Node.js >=18 required — older versions will fail to start
fix Update Node.js to version 18 or later.
deprecated krave-4.0 model is deprecated and may be removed in a future version
fix Switch to krave-4.1 or krave-4.2.
gotcha API key must be set via environment variable KRAVE_API_KEY or passed in options; otherwise CLI will exit with an authentication error.
fix Set KRAVE_API_KEY environment variable before running krave.
npm install krave-cli
yarn add krave-cli
pnpm add krave-cli

Demonstrates ESM import of Krave CLI, configuration with API key, model selection, session path, and tool enabling.

#!/usr/bin/env node
import krave from 'krave-cli';

const options = {
  apiKey: process.env.KRAVE_API_KEY ?? '',
  model: 'krave-4.2',
  sessionPath: './my-session.json',
  tools: ['bash', 'writefile', 'spawn']
};

krave(options).then(() => {
  console.log('Session ended.');
}).catch(err => {
  console.error('Krave error:', err.message);
  process.exit(1);
});