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

Self Feedback broken #3934

Closed
1 task done
waynehamadi opened this issue May 7, 2023 · 3 comments
Closed
1 task done

Self Feedback broken #3934

waynehamadi opened this issue May 7, 2023 · 3 comments
Labels

Comments

@waynehamadi
Copy link
Contributor

waynehamadi commented May 7, 2023

Duplicates

  • I have searched the existing issues

Summary 💡

Look at this, this is what we send to OPENAI. As you can see, we don't even do any action anymore when using self feedback. We should just reply "y" if the agent behaves correctly, no need to send back a long message.

[
    {
        "role": "system",
        "content": "You are Debug-Code-GPT, an autonomous agent that specializes in debugging python code\nYour decisions must always be made independently without seeking user assistance. Play to your strengths as an LLM and pursue simple strategies with no legal complications.\n\nGOALS:\n\n1. 1-Run the code in the file named 'code.py' using the execute_code command.\n2. 2-Read code.py to understand why the code is not working as expected.\n3. 3-Modify code.py to fix the error.\n4. Repeat step 1, 2 and 3 until the code is working as expected. When you're done use the task_complet command.\n5. Do not use any other commands than execute_python_file and write_file\n\n\nConstraints:\n1. ~4000 word limit for short term memory. Your short term memory is short, so immediately save important information to files.\n2. If you are unsure how you previously did something or want to recall past events, thinking about similar events will help you remember.\n3. No user assistance\n4. Exclusively use the commands listed in double quotes e.g. \"command name\"\n\nCommands:\n1. append_to_file: Append to file, args: \"filename\": \"<filename>\", \"text\": \"<text>\"\n2. delete_file: Delete file, args: \"filename\": \"<filename>\"\n3. list_files: List Files in Directory, args: \"directory\": \"<directory>\"\n4. read_file: Read file, args: \"filename\": \"<filename>\"\n5. write_to_file: Write to file, args: \"filename\": \"<filename>\", \"text\": \"<text>\"\n6. execute_python_file: Execute Python File, args: \"filename\": \"<filename>\"\n7. improve_code: Get Improved Code, args: \"suggestions\": \"<list_of_suggestions>\", \"code\": \"<full_code_string>\"\n8. delete_agent: Delete GPT Agent, args: \"key\": \"<key>\"\n9. get_hyperlinks: Get text summary, args: \"url\": \"<url>\"\n10. get_text_summary: Get text summary, args: \"url\": \"<url>\", \"question\": \"<question>\"\n11. list_agents: List GPT Agents, args: () -> str\n12. message_agent: Message GPT Agent, args: \"key\": \"<key>\", \"message\": \"<message>\"\n13. start_agent: Start GPT Agent, args: \"name\": \"<name>\", \"task\": \"<short_task_desc>\", \"prompt\": \"<prompt>\"\n\nResources:\n1. Internet access for searches and information gathering.\n2. Long Term memory management.\n3. GPT-3.5 powered Agents for delegation of simple tasks.\n4. File output.\n\nPerformance Evaluation:\n1. Continuously review and analyze your actions to ensure you are performing to the best of your abilities.\n2. Constructively self-criticize your big-picture behavior constantly.\n3. Reflect on past decisions and strategies to refine your approach.\n4. Every command has a cost, so be smart and efficient. Aim to complete tasks in the least number of steps.\n5. Write all code to a file.\n\nYou should only respond in JSON format as described below \nResponse Format: \n{\n    \"thoughts\": {\n        \"text\": \"thought\",\n        \"reasoning\": \"reasoning\",\n        \"plan\": \"- short bulleted\\n- list that conveys\\n- long-term plan\",\n        \"criticism\": \"constructive self-criticism\",\n        \"speak\": \"thoughts summary to say to user\"\n    },\n    \"command\": {\n        \"name\": \"command name\",\n        \"args\": {\n            \"arg name\": \"value\"\n        }\n    }\n} \nEnsure the response can be parsed by Python json.loads"
    },
    {
        "role": "system",
        "content": "The current time and date is Sat May  6 17:52:20 2023"
    },
    {
        "role": "system",
        "content": "This reminds you of these events from your past: \nI was created and nothing new has happened."
    },
    {
        "role": "user",
        "content": "Determine which next command to use, and respond using the format specified above:"
    },
    {
        "role": "assistant",
        "content": "{\n    \"thoughts\": {\n        \"text\": \"I should start by executing the code in the file named 'code.py' using the execute_python_file command.\",\n        \"reasoning\": \"Executing the code will give me an idea of what the code is supposed to do and what is causing the error.\",\n        \"plan\": \"- Execute the code in the file named 'code.py' using the execute_python_file command.\",\n        \"criticism\": \"I don't have any criticism for my plan at this time.\",\n        \"speak\": \"I will start by executing the code in the file named 'code.py'.\"\n    },\n    \"command\": {\n        \"name\": \"execute_python_file\",\n        \"args\": {\n            \"filename\": \"code.py\"\n        }\n    }\n}"
    },
    {
        "role": "system",
        "content": "Self feedback: As an AI Agent specializing in debugging Python code, it is reasonable to execute the code in the file named 'code.py' using the execute_python_file command. This will give the AI Agent an idea of what the code is supposed to do and what is causing the error. However, it is important to note that executing the code alone may not be enough to identify the root cause of the error. The AI Agent should also consider analyzing the code line by line, checking for syntax errors, and identifying any logical errors that may be present. Additionally, the AI Agent should be able to provide suggestions for fixing the error and improving the overall code quality. Overall, the AI Agent's thought process is sound, but it could benefit from incorporating additional steps to ensure a more thorough debugging process."
    },
    {
        "role": "user",
        "content": "Determine which next command to use, and respond using the format specified above:"
    }
]

Examples 🌈

No response

Motivation 🔦

No response

@waynehamadi
Copy link
Contributor Author

@gravelBridge when @AbTrax fixes it pull my branch again https://github.com/Significant-Gravitas/Auto-GPT/pull/3804/files#diff-52a36dc2f4accbd205fd8a02146578f38e789fc82be164e16ae98ea59fa74651
And please retry to make docker work with VCR because I didn't make it work.

@github-actions
Copy link
Contributor

github-actions bot commented Sep 6, 2023

This issue has automatically been marked as stale because it has not had any activity in the last 50 days. You can unstale it by commenting or removing the label. Otherwise, this issue will be closed in 10 days.

@github-actions github-actions bot added the Stale label Sep 6, 2023
@github-actions
Copy link
Contributor

This issue was closed automatically because it has been stale for 10 days with no activity.

@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale Sep 17, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant