Move API credentials to .env and set gpt-5.6-luna model
- Load OPENAI_API_KEY and OPENAI_BASE_URL from gitignored .env (repo-root, CWD-independent) - Fix command explanation to use the configured model instead of hardcoded gpt-4o-mini - Update default model and fallbacks to gpt-5.6-luna - Document .env-based configuration in READMEs
This commit is contained in:
+12
-3
@@ -80,7 +80,7 @@ The rich terminal UI provides:
|
||||
Edison can be configured via the `edison.yaml` file. Here's an example configuration:
|
||||
|
||||
```yaml
|
||||
model: gpt-3.5-turbo
|
||||
model: gpt-5.6-luna
|
||||
temperature: 0
|
||||
max_tokens: 500
|
||||
safety: true
|
||||
@@ -88,13 +88,22 @@ safety: true
|
||||
|
||||
## API Key
|
||||
|
||||
Edison requires an OpenAI API key to function. You can provide it in one of the following ways:
|
||||
Edison requires an API key to function. The recommended way is a `.env` file in the repository root (gitignored, so not checked in):
|
||||
|
||||
```
|
||||
OPENAI_API_KEY="your-api-key"
|
||||
OPENAI_BASE_URL="https://api.openai.com/v1"
|
||||
```
|
||||
|
||||
You can also provide it in one of the following ways:
|
||||
|
||||
1. Environment variable: `OPENAI_API_KEY="your-api-key"`
|
||||
2. `.env` file in the same directory as the script
|
||||
2. `.env` file in the repository root
|
||||
3. `.openai.apikey` file in your home directory
|
||||
4. In the `edison.yaml` configuration file: `openai_api_key: "your-api-key"`
|
||||
|
||||
When using a custom backend or proxy, set `OPENAI_BASE_URL` (or `base_url` in `edison.yaml`) to its endpoint.
|
||||
|
||||
## License
|
||||
|
||||
MIT
|
||||
|
||||
Reference in New Issue
Block a user