Home/Config/Environment Variables
Environment Variables

Environment variables help DeepSeek TUI only when you know exactly which shell values are winning

Environment variables are convenient because they are fast to change, but that convenience turns into confusion when different shells, profiles, or project scripts quietly override what you thought the app would use.

Site detail pageDeepSeek TUI Environment VariablesConfig

Questions this page should answer fast

  • Which values belong in environment variables instead of checked-in config files?
  • How do you see whether the shell is overriding file-based config?
  • When should you stop using environment variables and move values into a more stable config path?

What to verify next

  • List the relevant environment variables in the shell you actually use.
  • Compare behavior with and without those exports active.
  • If the same issue survives after clearing env overrides, return to the config file path.

Common mistakes

  • Treating environment values as if they were self-documenting.
  • Forgetting that different terminal profiles can export different values.
  • Using env overrides permanently when a stable config file would be easier to reason about.

Recommended reading order

Move through the page by workflow need first, then branch into adjacent detail pages or hubs.

Step 1

Decide what should stay secret or local

Use environment variables for values that should remain machine-local or session-local, not for everything by default.

Step 2

Track where they are set

Know whether the variable comes from shell profile files, direnv-like tooling, CI, or a temporary export.

Step 3

Test across shell boundaries

If one terminal works and another does not, compare active environment state before rewriting config files.

Use-it-now examples

Start from working examples first, then adjust the details.

Check what the current shell really exports

List the relevant values before you edit config files, especially if different terminals behave differently.

echo "$DEEPSEEK_API_KEY"
# inspect any provider-related exports in the current shell

Compare with and without overrides

The fastest way to prove the env layer is involved is to compare behavior before and after clearing the relevant export.

unset DEEPSEEK_API_KEY
# reopen the shell or retry the narrowest request path

Common failure branches

Work out which layer failed first instead of treating every problem as the same.

One terminal works and another does not

That is usually a shell-profile difference, not a provider outage. Compare exports across the two shells before rewriting config.

You changed the config file but nothing moved

An environment override may still be winning. Clear or inspect env values before assuming the file path is wrong.

When to leave this page

Once the route is clear, leave this page quickly. Install pages should hand you into config, config pages should send you into provider or troubleshooting, and MCP or mode pages should send you back into live workflow decisions. A detail page is valuable because it narrows the problem, not because you stay on it forever.