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

Use JSON format for commands signature #4714

Merged

Conversation

waynehamadi
Copy link
Contributor

@waynehamadi waynehamadi commented Jun 16, 2023

Background

Changes

Use more formal definition of command arguments, using JSON, so that we can prepare the OpenAI functions.

Documentation

  • changed signature on all commands
  • removed git_operations, dowload_file and replace_in_file
  • Fixed summarization using the wrong method to check if valid JSON

Test Plan

PR Quality Checklist

  • My pull request is atomic and focuses on a single change.
  • I have thoroughly tested my changes with multiple different prompts.
  • I have considered potential risks and mitigations for my changes.
  • I have documented my changes clearly and comprehensively.
  • I have not snuck in any "extra" small tweaks changes.
  • I have run the following commands against my code to ensure it passes our linters:
    black .
    isort .
    mypy
    autoflake --remove-all-unused-imports --recursive --ignore-init-module-imports --ignore-pass-after-docstring autogpt tests --in-place

@waynehamadi waynehamadi marked this pull request as draft June 16, 2023 00:06
@github-actions
Copy link
Contributor

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

@netlify
Copy link

netlify bot commented Jun 16, 2023

Deploy Preview for auto-gpt-docs canceled.

Name Link
🔨 Latest commit 9c773ef
🔍 Latest deploy log https://app.netlify.com/sites/auto-gpt-docs/deploys/648dad79a977cf000830adf6

@waynehamadi waynehamadi force-pushed the commands-signature-as-json branch from c44eea2 to db7d069 Compare June 16, 2023 00:16
@github-actions
Copy link
Contributor

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

@waynehamadi waynehamadi force-pushed the commands-signature-as-json branch from db7d069 to 80c3522 Compare June 16, 2023 00:44
@github-actions
Copy link
Contributor

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

@waynehamadi waynehamadi force-pushed the commands-signature-as-json branch from 80c3522 to 181c6ef Compare June 16, 2023 00:49
@codecov
Copy link

codecov bot commented Jun 16, 2023

Codecov Report

Patch coverage: 84.21% and project coverage change: -0.35 ⚠️

Comparison is base (0b6fec4) 71.32% compared to head (9c773ef) 70.97%.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #4714      +/-   ##
==========================================
- Coverage   71.32%   70.97%   -0.35%     
==========================================
  Files          68       68              
  Lines        3309     3252      -57     
  Branches      528      516      -12     
==========================================
- Hits         2360     2308      -52     
+ Misses        787      783       -4     
+ Partials      162      161       -1     
Impacted Files Coverage Δ
autogpt/commands/git_operations.py 100.00% <ø> (ø)
autogpt/commands/image_gen.py 75.67% <ø> (ø)
autogpt/commands/task_statuses.py 100.00% <ø> (ø)
autogpt/commands/web_selenium.py 54.20% <ø> (ø)
autogpt/main.py 22.07% <ø> (ø)
autogpt/plugins/__init__.py 79.35% <70.00%> (-1.32%) ⬇️
autogpt/command_decorator.py 95.65% <100.00%> (ø)
autogpt/commands/execute_code.py 73.52% <100.00%> (ø)
autogpt/commands/file_operations.py 80.64% <100.00%> (-2.16%) ⬇️
autogpt/commands/web_search.py 100.00% <100.00%> (ø)
... and 1 more

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@github-actions
Copy link
Contributor

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

@waynehamadi waynehamadi force-pushed the commands-signature-as-json branch from 181c6ef to 3f3013f Compare June 16, 2023 01:22
@github-actions
Copy link
Contributor

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

@waynehamadi waynehamadi force-pushed the commands-signature-as-json branch from 3f3013f to 3611d46 Compare June 16, 2023 01:27
@github-actions
Copy link
Contributor

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

@Auto-GPT-Bot
Copy link
Contributor

You changed AutoGPT's behaviour. The cassettes have been updated and will be merged to the submodule when this Pull Request gets merged.

@waynehamadi waynehamadi force-pushed the commands-signature-as-json branch from 3611d46 to e33f414 Compare June 16, 2023 01:39
@github-actions
Copy link
Contributor

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

@waynehamadi waynehamadi force-pushed the commands-signature-as-json branch from e33f414 to e7a1e49 Compare June 16, 2023 01:46
@github-actions
Copy link
Contributor

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

@waynehamadi waynehamadi force-pushed the commands-signature-as-json branch from e7a1e49 to 0abcd3e Compare June 16, 2023 02:03
@github-actions
Copy link
Contributor

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

@waynehamadi waynehamadi force-pushed the commands-signature-as-json branch from 0abcd3e to faffcbf Compare June 16, 2023 02:07
@github-actions
Copy link
Contributor

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

@waynehamadi waynehamadi force-pushed the commands-signature-as-json branch from faffcbf to 746c803 Compare June 16, 2023 19:41
@github-actions
Copy link
Contributor

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

@Auto-GPT-Bot
Copy link
Contributor

You changed AutoGPT's behaviour. The cassettes have been updated and will be merged to the submodule when this Pull Request gets merged.

@github-actions
Copy link
Contributor

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

1 similar comment
@github-actions
Copy link
Contributor

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

@waynehamadi waynehamadi force-pushed the commands-signature-as-json branch from 5cac6ba to dd9f163 Compare June 16, 2023 21:04
@github-actions
Copy link
Contributor

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

@waynehamadi waynehamadi force-pushed the commands-signature-as-json branch from dd9f163 to eb53ea7 Compare June 16, 2023 21:06
@github-actions
Copy link
Contributor

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

@waynehamadi waynehamadi force-pushed the commands-signature-as-json branch from eb53ea7 to 45e26d6 Compare June 16, 2023 21:12
@github-actions
Copy link
Contributor

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

@waynehamadi waynehamadi force-pushed the commands-signature-as-json branch from 45e26d6 to 939745e Compare June 16, 2023 21:22
@github-actions
Copy link
Contributor

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

@waynehamadi waynehamadi force-pushed the commands-signature-as-json branch from 939745e to 592968a Compare June 16, 2023 21:26
@github-actions
Copy link
Contributor

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

@waynehamadi waynehamadi force-pushed the commands-signature-as-json branch from 67f1169 to b627d5e Compare June 16, 2023 21:28
@github-actions
Copy link
Contributor

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

1 similar comment
@github-actions
Copy link
Contributor

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

@waynehamadi waynehamadi force-pushed the commands-signature-as-json branch from b627d5e to 7586e4f Compare June 17, 2023 01:29
@github-actions
Copy link
Contributor

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

@waynehamadi waynehamadi marked this pull request as ready for review June 17, 2023 01:34
Pwuts
Pwuts previously requested changes Jun 17, 2023
Copy link
Member

@Pwuts Pwuts left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please link back to the original PR and give @erik-megarad some credit in the description :)

autogpt/command_decorator.py Outdated Show resolved Hide resolved
autogpt/commands/execute_code.py Outdated Show resolved Hide resolved
autogpt/commands/file_operations.py Outdated Show resolved Hide resolved
autogpt/commands/image_gen.py Outdated Show resolved Hide resolved
autogpt/commands/git_operations.py Outdated Show resolved Hide resolved
autogpt/commands/web_search.py Outdated Show resolved Hide resolved
autogpt/models/command.py Outdated Show resolved Hide resolved
@waynehamadi
Copy link
Contributor Author

@github-actions github-actions bot added size/l and removed size/xl labels Jun 17, 2023
@waynehamadi waynehamadi merged commit 10d7747 into Significant-Gravitas:master Jun 17, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

6 participants