Resolves the API key, model and base URL used for equivalent-mutant detection. Each field is resolved independently, with this precedence (highest first):
Usage
get_openai_config(dir = getwd())Details
values set with
set_openai_config();a
.openai_configfile indir(a human-readable "field: value" file that is parsed, never executed);the environment variables
OPENAI_API_KEY,OPENAI_MODELandOPENAI_BASE_URL;built-in defaults (model
"gpt-4", the public OpenAI base URL).
Examples
config <- get_openai_config()
names(config)
#> [1] "api_key" "model" "base_url"