ExpertAI by AI Launchpad
OverviewWeb toolsHuman expertsPremiumAppsExpert Code
← Documentation

Expert Code in your IDE

Expert Code is an autonomous coding agent that runs in your terminal — so it works inside any IDE’s integrated terminal (VS Code, JetBrains, Cursor, and more). Point it at a project, describe a task, and it explores, edits, and runs commands with your approval.

On this page

  1. Prerequisites
  2. Install
  3. Choose how it runs the AI
  4. Set it up in your IDE
  5. Using Expert Code
  6. Configuration reference
  7. Troubleshooting
  8. Safety

Prerequisites

  • Node.js 18 or newer. Check with node --version; install from nodejs.org if needed.
  • Either your own AI provider API key (Anthropic, OpenAI, Gemini, Groq, OpenRouter, DeepSeek, or Z.ai) or an ExpertAI account for hosted sign-in. You choose below.

Install

Install it globally so the `expert` command is available everywhere:

npm install -g @ai-launchpad-v1/expert-code

Confirm it installed:

expert --version

Prefer not to install globally? Run it on demand with npx @ai-launchpad-v1/expert-code.

Choose how it runs the AI

Pick one. You can switch at any time.

Option A — Bring your own key (BYOK)

Use your own provider API key. Inference bills to your key and nothing goes through our backend. Run the one-time setup:

expert setup

Pick a provider, paste your key, and optionally a model. It’s saved to ~/.expertcode/config.json. To script it instead:

expert setup --provider anthropic --key sk-ant-... --model claude-sonnet-4-6

You can also set a key in your shell for a single session, which overrides the saved config — e.g. ANTHROPIC_API_KEY, OPENAI_API_KEY, GEMINI_API_KEY, GROQ_API_KEY, or OPENROUTER_API_KEY (plus AI_PROVIDER to choose and <PROVIDER>_MODEL to pin a model).

On OpenRouter, pick a model that supports tool-calling, or the agent can’t read or edit files. Most Anthropic/OpenAI/Gemini slugs and many free models do; check the “Tools” capability on the model’s page.

Option B — Hosted sign-in (no API key)

Sign in and run on the ExpertAI backend — no key to manage:

expert login

Enter your email, then the one-time code we email you. Sign out any time with expert logout.

Hosted inference requires a Premium account. If you sign in without Premium, tasks return a payment-required notice — use BYOK instead, or upgrade.

Which one runs

If you’re signed in, Expert Code uses the hosted backend; otherwise it uses BYOK. Force a lane with EXPERT_LANE=byok or EXPERT_LANE=managed, and check the current state with expert whoami.

Set it up in your IDE

Expert Code runs in your IDE’s integrated terminal. Open it, change into your project, and run expert — the current folder becomes the workspace.

VS Code, Cursor, Windsurf

  • Open the terminal: View → Terminal, or press Ctrl + ` (backtick). It opens at your project root.
  • Run expert. (If your project isn’t the current folder, pass a path: expert ./path/to/project.)

JetBrains (IntelliJ IDEA, PyCharm, WebStorm, Rider, GoLand…)

  • Open the terminal tool window: View → Tool Windows → Terminal, or press Alt + F12.
  • Run expert.

Visual Studio

  • Open View → Terminal (the Developer PowerShell / Terminal window).
  • Run expert.

Neovim / Vim / Emacs / tmux

  • Use a terminal buffer (:terminal in Neovim/Vim) or a split/tmux pane, then run expert. Any terminal works.

Tip: each terminal tab is an independent session — open several to work on different projects at once.

Using Expert Code

At the › prompt, type a task in plain English — e.g. “Add input validation to the signup form and run the tests.” The agent explores the code, proposes and applies changes, and can run commands, showing diffs and live output as it goes.

Generate project context with /init

Run /init once in a project to have the agent write an EXPERT.md — a short orientation file (stack, layout, conventions, commands) that it auto-loads at the start of every future task. Run it again later to refresh it.

Approvals and autonomy

In the default auto mode, reads and file edits apply automatically, while risky or unfamiliar commands pause for approval — press y to run, n to skip, a to always allow that exact command for the session, or type a note to reject with guidance. Start with expert --manual (or type /manual) to approve every write, edit, and command. Press Ctrl-C once to stop the current task and return to the prompt.

At the prompt

  • ↑ / ↓ — recall your previous tasks.
  • Tab — complete a /command, or (at an empty prompt) accept the agent’s suggested next step, shown as a dim next: hint after a task finishes.
  • @path — attach a file to the task, e.g. “explain @src/auth.ts and compare the layout to @design/home.png”. Images and PDFs are read natively; text files are inlined. A mention that isn’t a real file is left as plain text.

Attach files, switch models, review changes

Beyond /init, the in-session slash commands let you steer a task without leaving the prompt:

CommandWhat it does
/model [provider] [model]Show or switch the BYOK provider/model without restarting
/login / /logoutSwitch to or from the hosted lane mid-session
/diffReview the file changes applied this task
/revertUndo the most recent change (restores the file, or deletes it if newly created)
/compactSummarize the conversation to shrink the context — the task continues and applied changes are kept
/clearStart a fresh task and clear the screen
/statusWorkspace, model, autonomy, change count, and token usage
/auto / /manualSwitch autonomy mode
/help / /exitShow help / quit (or Ctrl-D)

Token usage

After each task, Expert Code shows an estimated token count — ~N task · ~N session — also surfaced in the prompt frame and in /status. It’s an approximation (shown with a ~) for gauging context size and relative cost, not exact billing. When a conversation grows long, run /compact to summarize it and shrink the context the agent re-sends on each step.

CLI commands

CommandWhat it does
expert [dir] [--manual]Start the agent in a project (default: current directory)
expert setupConfigure your own provider key (BYOK)
expert login / expert logoutHosted sign-in / sign-out
expert whoamiShow sign-in and the active inference lane
expert config [set <k> <v>]Show or edit config (apiBase, provider, autoUpdate)
expert updateUpdate to the latest version now
expert --version / --helpVersion / help

Expert Code updates itself. On startup it checks for a newer version (at most once a day) and installs it in the background, so the next time you run expert you’re on the latest — no manual reinstall. Force it with expert update, or turn it off with expert config set autoUpdate false.

Configuration reference

Settings resolve in this order: shell environment → config file → built-in default. The config file lives at ~/.expertcode/config.json.

Environment variablePurpose
AI_PROVIDERanthropic | openai | gemini | groq | openrouter | deepseek | zai
<PROVIDER>_API_KEYYour key for that provider (e.g. ANTHROPIC_API_KEY)
<PROVIDER>_MODELPin a specific model (optional)
EXPERT_LANEForce a lane: byok or managed
EXPERT_API_BASEPoint the hosted lane at a different deployment

Troubleshooting

“expert is not recognized” / command not found

The global install directory isn’t on your PATH yet in this terminal. Open a new terminal window and try again. If it persists, confirm the install with npm list -g @ai-launchpad-v1/expert-code and that your npm global bin directory is on PATH.

“Managed sign-in is not available in this build”

You’re running a build without hosted sign-in configured (for example a local development build). Install the published package with npm install -g @ai-launchpad-v1/expert-code, or just use BYOK (expert setup).

Login email never arrives

Check spam, and that you entered the right address. If it keeps failing, use BYOK in the meantime — it needs no email or account.

Tasks return a “Premium required” notice

Hosted inference is Premium-only. Upgrade your account, or switch to BYOK with expert setup (and EXPERT_LANE=byok if you’re also signed in).

The agent won’t edit files (keeps only talking)

Your model probably doesn’t support tool-calling — common with some free OpenRouter slugs. Switch to a tool-capable model.

Safety

Every file operation is confined to the workspace folder you opened — checked both directly and after resolving symlinks — and writes inside .git/ are refused. Destructive, install, network, and outward-facing commands always require explicit approval, even in auto mode. You stay in control of what runs.

Need help? Email hello@ai-launchpad-v1.com.