nanocode Integration
AVELIN API is compatible with nanocode — the minimal Claude Code alternative that fits in a single Python file.
nanocode is the entire agentic coding loop in ~250 lines of Python with zero external dependencies. It gives you the full toolset — read, write, edit, glob, grep, and bash — the same capabilities as tools with 100x more code. The killer feature is radical simplicity: you can read the entire source, understand every decision, and fork it in an afternoon. No node_modules, no Docker images, no build step. Just one file you drop into any project. For developers who want to own their tooling — modify the prompt, change the tool behavior, add a feature — nanocode is the coding agent you can actually hold in your head.
Why AVELIN + nanocode? Access AVELIN's frontier coding models with 1M-token context windows, automatic failover, and ~100 tps throughput through a single OpenAI-compatible endpoint.
Quick Setup
Step 1: Get your AVELIN API key
Sign up at avelin.ai and generate an API key. It will look like sk-ave...xxxx.
Step 2: Install nanocode
Refer to nanocode documentation for installation instructions.
Step 3: Configure AVELIN
Set AVELIN as your LLM provider. Most tools support OpenAI-compatible endpoints via environment variables or config files:
export OPENAI_API_BASE=https://api.avelin.ai/v1 export OPENAI_API_KEY=sk-avelin-YOUR_KEY
Common config file pattern:
provider: openai api_base: https://api.avelin.ai/v1 api_key: sk-ave...xxxx model: avelin-coding-pro
Step 4: Select your model
Recommended Models
Primary: avelin-coding-pro
Alternatives
Why AVELIN for nanocode?
- 1M context windows: Large codebases fit without aggressive exclusions
- Prompt caching: ~80% reduction on repeated system prompts and repo-maps
- Automatic failover: Coding sessions keep running if a provider is down
- Model diversity: Multiple frontier models through one API
Troubleshooting
Related
- API Quickstart — First API call in 5 minutes
- Aider Guide — Popular terminal coding tool
- Claude Code Guide — Anthropic's CLI coding tool
- Model Catalog — Full comparison
- nanocode Documentation — Official docs