Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pull master into Release v0.4.4 #4903

Merged
merged 25 commits into from
Jul 7, 2023
Merged

Pull master into Release v0.4.4 #4903

merged 25 commits into from
Jul 7, 2023

Conversation

lc0rp
Copy link
Contributor

@lc0rp lc0rp commented Jul 7, 2023

Bringing the release-v0.4.4 branch up to speed in prep for release

yuta0x89 and others added 24 commits June 26, 2023 14:38
…antic 2.0 (#4858)

As per
pydantic/pydantic#1729 (comment),
the implementation of `model_post_init()` is postponed until Pydantic
v2. As a result, the initialization of PluginConfig is being skipped.

This fix calls `plugin.model_post_init()` explicitly.

The recency of the Pydantic v2 release means that some of the other
extensions we use do not support it yet. Specifically, extensions such
as spacy and openapi-python-client are currently limited to Pydantic
versions that are less than 2.0. There may be other extensions that have
the same limitation as well.

---------

Co-authored-by: Reinier van der Leer <[email protected]>
Simplified plugin log messages to make plugin debugging easier

---------

Co-authored-by: Reinier van der Leer <[email protected]>
Rough sketching out of a hello world using our refactored autogpt
library. See the tracking issue here: #4770.

# Run instructions

There are two client applications for Auto-GPT included. 

## CLI Application

:star2: **This is the reference application I'm working with for now**
:star2:

The first app is a straight CLI application. I have not done anything
yet to port all the friendly display stuff from the
`logger.typewriter_log` logic.

- [Entry
Point](https://github.com/Significant-Gravitas/Auto-GPT/blob/re-arch/hello-world/autogpt/core/runner/cli_app/cli.py)
- [Client
Application](https://github.com/Significant-Gravitas/Auto-GPT/blob/re-arch/hello-world/autogpt/core/runner/cli_app/main.py)

To run, you first need a settings file.  Run

```
 python REPOSITORY_ROOT/autogpt/core/runner/cli_app/cli.py make-settings
 ```

where `REPOSITORY_ROOT` is the root of the Auto-GPT repository on your machine.  This will write a file called `default_agent_settings.yaml` with all the user-modifiable configuration keys to `~/auto-gpt/default_agent_settings.yml` and make the `auto-gpt` directory in your user directory if it doesn't exist).  At a bare minimum, you'll need to set `openai.credentials.api_key` to your OpenAI API Key to run the model.

You can then run Auto-GPT with 

```
python REPOSITORY_ROOT/autogpt/core/runner/cli_app/cli.py make-settings
```

to launch the interaction loop.

## CLI Web App

The second app is still a CLI, but it sets up a local webserver that the client application talks to rather than invoking calls to the Agent library code directly.  This application is essentially a sketch at this point as the folks who were driving it have had less time (and likely not enough clarity) to proceed.

- [Entry Point](https://github.com/Significant-Gravitas/Auto-GPT/blob/re-arch/hello-world/autogpt/core/runner/cli_web_app/cli.py)
- [Client Application](https://github.com/Significant-Gravitas/Auto-GPT/blob/re-arch/hello-world/autogpt/core/runner/cli_web_app/client/client.py)
- [Server API](https://github.com/Significant-Gravitas/Auto-GPT/blob/re-arch/hello-world/autogpt/core/runner/cli_web_app/server/api.py)

To run, you still need to generate a default configuration.  You can do 

```
python REPOSITORY_ROOT/autogpt/core/runner/cli_web_app/cli.py
make-settings
```

It invokes the same command as the bare CLI app, so follow the instructions above about setting your API key.

To run, do 

```
python REPOSITORY_ROOT/autogpt/core/runner/cli_web_app/cli.py client
```

This will launch a webserver and then start the client cli application to communicate with it.

:warning: I am not actively developing this application.  It is a very good place to get involved if you have web application design experience and are looking to get involved in the re-arch.

---------

Co-authored-by: David Wurtz <[email protected]>
Co-authored-by: Media <[email protected]>
Co-authored-by: Richard Beales <[email protected]>
Co-authored-by: Daryl Rodrigo <[email protected]>
Co-authored-by: Daryl Rodrigo <[email protected]>
Co-authored-by: Swifty <[email protected]>
Co-authored-by: Nicholas Tindle <[email protected]>
Co-authored-by: Merwane Hamadi <[email protected]>
* Fix Config model initialization

* Fix basedir determination in install_plugin_dependencies

* Add logging to install_plugin_dependencies()

---------

Co-authored-by: collijk <[email protected]>
* New Challenge test_information_retrieval_challenge_c

I created a new challenge needs a bit of work

* Update current_score.json

Changed max level beaten to null

* reformatted test_information_retrieval_challenge_c with black

reformatted test_information_retrieval_challenge_c with black

---------

Co-authored-by: merwanehamadi <[email protected]>
* Update setup.md

Change "docker-compose" command to "docker compose" to avoid future issues with running the Docker method (`docker-compose` is v1 and is outdated, is not a recognized command with newer versions of Docker engine)

* Update usage.md

* Update comment in docker-compose.yml

---------

Co-authored-by: Reinier van der Leer <[email protected]>
* [Fix] Recover the azure config load function

* [Style] Apply black, isort, mypy, autoflake

* [Fix] Rename the return parameter from 'azure_model_map' to 'azure_model_to_deployment_id_map'

* [Feat] Change the azure config file path to be dynamically configurable

* [Test] Add azure_config and azure deployment_id_for_model

* [Style] Apply black, isort, mypy, autoflake

* [Style] Apply black, isort, mypy, autoflake

* Refactor Azure configuration

- Refactor the `azure_config_file` attribute in the `Config` class to be optional.
- Refactor the `azure_model_to_deployment_id_map` attribute in the `Config` class to be optional and provide default values.
- Update the `get_azure_deployment_id_for_model` function to accept additional parameters.
- Update references to `get_azure_deployment_id_for_model` in `create_text_completion`, `create_chat_completion`, and `get_embedding` functions to pass the required parameters.

* Clean up process for azure

* Docstring

* revert some unneccessary fiddling

* Avoid altering args to models

* Retry on 404s

* Don't permanently change the environment

* Formatting

---------

Co-authored-by: Luke <[email protected]>
Co-authored-by: lc0rp <[email protected]>
Co-authored-by: collijk <[email protected]>
* Use GPT-4 as default smart LLM in Agent

* Rename (smart|fast)_llm_model to (smart|fast)_llm everywhere

* Fix test_config.py::test_initial_values

* Fix test_config.py::test_azure_config

* Fix Azure config backwards compatibility
* add capability to specify AI config at cmd line

* Make `--ai-goal` multi-parameter

* Fix argument forwarding in run.sh

---------

Co-authored-by: Reinier van der Leer <[email protected]>
* changing configs names to tts_provider

* accidently triggered circular importing.

* added config to places it needs other than the logger

* got it to work on windows

* did all the formatting stuff

---------

Co-authored-by: James Collins <[email protected]>
@netlify
Copy link

netlify bot commented Jul 7, 2023

Deploy Preview for auto-gpt-docs canceled.

Name Link
🔨 Latest commit 3b7e101
🔍 Latest deploy log https://app.netlify.com/sites/auto-gpt-docs/deploys/64a78fd78cb1b70007225439

@github-actions
Copy link
Contributor

github-actions bot commented Jul 7, 2023

This PR exceeds the recommended size of 500 lines. Please make sure you are NOT addressing multiple issues with one PR.

* Fix --gpt3only and --gpt4only

* Fix and consolidate test_config.py::test_azure_config (x2)

---------

Co-authored-by: Luke K (pr-0f3t) <[email protected]>
Co-authored-by: Ryan <[email protected]>
Co-authored-by: Reinier van der Leer <[email protected]>
@github-actions
Copy link
Contributor

github-actions bot commented Jul 7, 2023

This PR exceeds the recommended size of 500 lines. Please make sure you are NOT addressing multiple issues with one PR.

@lc0rp lc0rp merged commit ebe3221 into release-v0.4.4 Jul 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.