Skip to content
DOCS — PRODUCT · PROFILES

Configuration Profiles

Profiles are named presets for the general CLI config file, ~/.config/openmed/config.toml. They set log_level, timeout, and use_medical_tokenizer.

Profiles do not change how the agent runs

The TUI and openmed agent --once do not read these values. Models, providers, permissions, and tools are set in runtime settings and provider configuration. Profiles are not an auth system, a model catalog, or an MCP server list.

Built-in profiles

Profile log_level timeout use_medical_tokenizer Intended use
dev DEBUG 600 true Development and debugging
prod WARNING 300 true Production-style defaults
test DEBUG 60 false Tests and CI
fast WARNING 120 false Faster local experiments

Inspect and apply profiles

openmed config profiles
openmed config profile-show dev
openmed config profile-use prod
openmed config show --profile fast

Behavior:

  • openmed config profiles lists built-in and custom profiles
  • openmed config profile-show <name> prints the stored profile values
  • openmed config profile-use <name> merges the profile into the saved config file and records its name as profile
  • openmed config show --profile <name> previews the merged config without saving it

Custom profiles

Create one from the current config:

openmed config set log_level DEBUG
openmed config set timeout 900
openmed config profile-save myprofile

Use or delete it later:

openmed config profile-use myprofile
openmed config profile-delete myprofile

Built-in profiles cannot be overwritten or deleted. profile-save copies every key from the current config except hf_token and profile.

Storage

Custom profiles are stored as TOML files under:

~/.config/openmed/profiles/<name>.toml

For example:

# OpenMed profile: myprofile
# Custom profile configuration

default_org = "OpenMed"
cache_dir = "/home/you/.cache/openmed"
device = null
log_level = "DEBUG"
timeout = 900
use_medical_tokenizer = true
medical_tokenizer_exceptions = null

Environment variable

You can also set:

export OPENMED_PROFILE=prod

This only fills in the profile name when the config file has none. It does not load that profile's values; use openmed config profile-use for that.

Resolution precedence

openmed config show builds its output in this order, with later steps winning:

  1. Built-in defaults
  2. Config file (~/.config/openmed/config.toml, including anything profile-use wrote)
  3. --profile <name> on openmed config show, for that one display
  4. Environment variables OPENMED_USE_MEDICAL_TOKENIZER and OPENMED_MEDICAL_TOKENIZER_EXCEPTIONS

HF_TOKEN and OPENMED_PROFILE apply only when the file leaves hf_token or profile empty. CLI flags such as --model, --agent, and --phi-mode are not part of this config. They override runtime settings for one run.

For environment variables and path details, see Configuration.