Marvin makes use of Pydantic's
BaseSettings to configure, load, and change behavior.
All settings are configurable via environment variables like
Please set Marvin specific settings in
~/.marvin/.env. One exception being
OPENAI_API_KEY, which may be as a global env var on your system and it will be picked up by Marvin.
Setting Environment Variables
For example, in your
~/.marvin/.env file you could have:
A runtime settings object is accessible via
marvin.settings and can be used to access or update settings throughout the package.
Mutating settings at runtime
For example, to access or change the LLM model used by Marvin at runtime:
Settings for using Azure OpenAI models¶
Some of Marvin's functionality is supported by Azure OpenAI services.
After setting up your Azure OpenAI account and deployment, set these environment variables in your environment,
Note that the chat completion model must be your Azure OpenAI deployment name.