This Github Action uses Auto-GPT to follow instructions in the issue description.
As per the example below, your workflow should be configured to only run the job containing this action under certain conditions, such as when a new label "auto-gpt" is added to an issue.
Required The OpenAI API key.
Required The body of the issue.
Required The number of the issue.
To use the auto-gpt.yml
workflow file, follow these steps:
- Add the
OPENAI_KEY
secrets to your repository. - Add the following code to your
.github/workflows/auto-gpt.yml
file as below. - Create a new issue and label it with the
auto-gpt
label.
There is an example of how to use this action in .github/workflows/auto-gpt.yml
.
Auto-GPT env variables such as FAST_TOKEN_LIMIT
, MEMORY_BACKEND
etc should be able to be defined in your workflow yaml.
name: Auto-GPT
on:
issues:
types: [labeled]
jobs:
resolve-issue:
if: "contains(github.event.label.name, 'auto-gpt')"
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Run Auto-GPT
uses: nalbion/auto-gpt-action@master
with:
openai_key: ${{ secrets.OPENAI_KEY }}
issue_number: ${{ github.event.issue.number }}
issue_body: ${{ github.event.issue.body }}
This project was my first exposure to Auto-GPT, the idea was that it would be neat if Auto-GPT could automatically implement new features and/or fix bugs, just by tagging the issue with auto-gpt
.
Inspiration for parts of the solution was drawn from the gpt-developer action.
All of the code in this repository was generated by Auto-GPT based off the prompts in ai_settings.yaml
. Auto-GPT was not run in continuous mode, infact there was a very lengthy discussion guiding Auto-GPT through the whole process.
| No, you will not (do something I had to tell it not to do several times), your next step will be ...
-
To use OpenAI API key for Auto-GPT, you NEED to have a paid account.
-
Important: It's highly recommended that you track your usage on the Usage page You can also set limits on how much you spend on the Usage limits page.
-
Edit
Auto-GPT/.env
(and add it to your.gitignore
file!!):
OPENAI_API_KEY=your-openai-api-key
EXECUTE_LOCAL_COMMANDS=True
docker pull significantgravitas/auto-gpt:0.2.2
copy ai_settings.yaml %USERPROFILE%\auto_gpt_workspace
copy auto-gpt.json %USERPROFILE%\auto_gpt_workspace
docker run -it --env-file=./Auto-GPT/.env -v "%USERPROFILE%/auto_gpt_workspace:/home/appuser/auto_gpt_workspace" significantgravitas/auto-gpt:0.2.2 --ai-settings auto_gpt_workspace/ai_settings.yaml