CLI & scripting

Aider

AI pair-programming CLI driven by LiteLLM.

Aider is LiteLLM-backed, so any OpenAI-compatible base URL works. Set two env vars and pass `openai/<freetheai-alias>` as the model.

Base URL https://api.freetheai.xyz/v1
Recommended models bbg/deepseek-ai/DeepSeek-V4-Pro
Chat completions Streaming Tool calling
Step by step

Connect Aider to FreeTheAi.

  1. 1

    Set environment variables

    Aider reads OPENAI_API_BASE and OPENAI_API_KEY from your shell.

    bash
    export OPENAI_API_BASE=https://api.freetheai.xyz/v1
    export OPENAI_API_KEY=fta_PASTE_YOUR_FREETHEAI_KEY
  2. 2

    Run aider with the openai/ prefix

    LiteLLM uses the `openai/` prefix to route the request through its OpenAI driver. Append your FreeTheAi alias.

    bash
    aider --model openai/bbg/zai-org/GLM-5.1
  3. 3

    Optional: persist in .aider.conf.yml

    Drop a config in your project root so you do not have to repeat the flags.

    yaml
    openai-api-base: https://api.freetheai.xyz/v1
    openai-api-key: fta_PASTE_YOUR_FREETHEAI_KEY
    model: openai/bbg/zai-org/GLM-5.1
Recommended aliases

Models that pair well with Aider.

  • bbg/deepseek-ai/DeepSeek-V4-Pro
  • bbg/zai-org/GLM-5.1
  • wsf/kimi-k2.6

See the full live catalog at /models. Aliases are stable; pricing on the free tier stays $0.

Heads up

Common gotchas.

  • Always include `/v1` in the base URL.
  • LiteLLM may print 'unknown model' warnings. Use `--no-show-model-warnings` or supply context-window via `--model-metadata-file` if it gets noisy.
Where to next

Keep building.