How to Set OPENAI_BASE_URL, and How It Differs From OPENAI_API_BASE
Current official OpenAI SDKs read OPENAI_BASE_URL; OPENAI_API_BASE belongs to the 0.x era. Setup commands, which tools read it, and how to verify it works.
Blog
Troubleshooting guides, IP and privacy explainers, AI service updates and model watch — each backed by tools and data you can check yourself.
Current official OpenAI SDKs read OPENAI_BASE_URL; OPENAI_API_BASE belongs to the 0.x era. Setup commands, which tools read it, and how to verify it works.
Change base_url in the openai Python library via OpenAI(base_url=...) or OPENAI_BASE_URL: three methods, precedence, /v1 and slash rules, and debug checklist.
Buying an AI API for your company? Before signing, check the contracting entity and invoices, data terms, uptime, keys, budget caps and exit costs with this printable 12-item checklist.
Personal use and offering AI services to others fall under very different rules. Covers four scenarios, data export and a 7-point checklist. Not legal advice.
OpenCode is an open-source terminal AI coding agent that isn't tied to one model vendor. Install it, run it, and connect a model in 5 steps, plus fixes.
How to use AGI Plan: sign up with an email code, pick a plan and create an API key, then change one base URL in Claude Code, Codex, or Cherry Studio. Pay in RMB.
Most beginners should start with an API. Run a local LLM only if data must stay on your machine, your hardware fits, and you'll maintain it. Five-factor checklist.
LLM API free tiers vary by vendor and change often. Verify yours in 5 steps, from pricing page to overage rules, then set a spend cap.
How to get an Alibaba Cloud Model Studio API key and make your first Qwen call: setup order, compatible-mode base URL, Python example, billing and key safety.
Walk through the DeepSeek Open Platform flow: sign up, add funds, create a key, send a first request with curl or an OpenAI-compatible SDK, plus an error table and a status check.
Steady usage above break-even favors a subscription; light or spiky usage favors pay-as-you-go. Estimate monthly cost from one week of usage.
Using AI to code in VS Code comes down to four settings: API type, base URL, API key and model name. Here is a generic setup guide plus a troubleshooting table.
Claude Code vs Codex CLI compared on config files, permissions and sandboxing, API format, and login, plus a decision table and setup checklist.
Claude Code works in your terminal; Cursor is an AI code editor. Compare workflow, learning curve, and setup, plus 5 self-test questions to pick the right one.
insufficient_quota means your account's quota or budget ran out, not that you're sending requests too fast. See 3 causes in one table and a 5-step fix.
List the model IDs your key can use with /v1/models, then copy one exactly. Covers display names vs. model IDs, provider naming, and a 4-step 404 check.
An invalid api key 401 is rarely a broken key. It is usually a stray space, an env var, the wrong base URL, an auth header or project scope. Six checks, each with a command.
A system prompt is standing instructions, not a per-turn question. See where it goes in OpenAI vs Anthropic APIs, get a 5-part template, and how to test it.
Temperature and top_p explained with a next-word lottery example, plus value guidance for coding, translation, and writing and a step-by-step tuning method.
Streaming returns the model's output as it is generated. stream=true shows the first token sooner without cutting total time. Includes runnable Python code and a troubleshooting list.
LLM APIs have no memory: multi-turn chat means resending history every call. See the message pattern, three truncation strategies, and the token cost impact.
Prompts only lower JSON errors, JSON mode guarantees valid syntax, and structured outputs enforce your schema. Includes Python validation and retry code.
Embeddings turn text into numbers so similar meaning means small distance. Learn vectors, cosine similarity, three uses, and a runnable API call.
Function calling means the model proposes a call and your code runs it. See the tools definition, the returned tool_calls, and the result you send back.