mirror of
https://github.com/aljazceru/Auto-GPT.git
synced 2026-01-31 11:54:30 +01:00
Minor improvements to the docs for voice config and testing (#3407)
This commit is contained in:
committed by
GitHub
parent
7a161cc0bd
commit
9e17a304de
@@ -99,15 +99,22 @@ https://github.com/Significant-Gravitas/Auto-GPT/pulls?q=is%3Apr+is%3Aopen+-labe
|
||||
## Testing your changes
|
||||
|
||||
If you add or change code, make sure the updated code is covered by tests.
|
||||
|
||||
To increase coverage if necessary, [write tests using `pytest`].
|
||||
To increase coverage if necessary, [write tests using pytest].
|
||||
|
||||
For more info on running tests, please refer to ["Running tests"](https://significant-gravitas.github.io/Auto-GPT/testing/).
|
||||
|
||||
[write tests using `pytest`]: https://realpython.com/pytest-python-testing/
|
||||
[write tests using pytest]: https://realpython.com/pytest-python-testing/
|
||||
|
||||
### API-dependent tests
|
||||
|
||||
To run tests that involve making calls to the OpenAI API, we use VCRpy. It caches known
|
||||
requests and matching responses in so-called *cassettes*, allowing us to run the tests
|
||||
in CI without needing actual API access.
|
||||
|
||||
When changes cause a test prompt to be generated differently, it will likely miss the
|
||||
cache and make a request to the API, updating the cassette with the new request+response.
|
||||
*Be sure to include the updated cassette in your PR!*
|
||||
|
||||
|
||||
In Pytest, we use VCRpy. It's a package that allows us to save OpenAI and other API providers' responses.
|
||||
When you run Pytest locally:
|
||||
|
||||
- If no prompt change: you will not consume API tokens because there are no new OpenAI calls required.
|
||||
|
||||
@@ -11,8 +11,8 @@ premade voices that Auto-GPT can use for speech.
|
||||
|
||||
1. Go to [ElevenLabs](https://beta.elevenlabs.io/) and make an account if you don't
|
||||
already have one.
|
||||
2. Choose and setup the `Starter` plan.
|
||||
3. Click the top right icon and find "Profile" to locate your API Key.
|
||||
2. Choose and setup the *Starter* plan.
|
||||
3. Click the top right icon and find *Profile* to locate your API Key.
|
||||
|
||||
In the `.env` file set:
|
||||
|
||||
|
||||
@@ -73,7 +73,7 @@ Get your OpenAI API key from: [https://platform.openai.com/account/api-keys](htt
|
||||
!!! important
|
||||
Make sure you have [Git](https://git-scm.com/downloads) installed for your OS.
|
||||
|
||||
!!! info
|
||||
!!! info "Executing commands"
|
||||
To execute the given commands, open a CMD, Bash, or Powershell window.
|
||||
On Windows: press ++win+x++ and pick *Terminal*, or ++win+r++ and enter `cmd`
|
||||
|
||||
@@ -115,9 +115,6 @@ Get your OpenAI API key from: [https://platform.openai.com/account/api-keys](htt
|
||||
|
||||
7. Save and close the `.env` file.
|
||||
|
||||
!!! info
|
||||
Get your ElevenLabs API key from: [ElevenLabs](https://elevenlabs.io). You can view your xi-api-key using the "Profile" tab on the website.
|
||||
|
||||
!!! info "Using a GPT Azure-instance"
|
||||
If you want to use GPT on an Azure instance, set `USE_AZURE` to `True` and
|
||||
make an Azure configuration file:
|
||||
|
||||
Reference in New Issue
Block a user