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

Train spawned agents #2944

Closed
1 task done
froggomad opened this issue Apr 22, 2023 · 4 comments
Closed
1 task done

Train spawned agents #2944

froggomad opened this issue Apr 22, 2023 · 4 comments
Labels
enhancement New feature or request needs discussion To be discussed among maintainers Stale

Comments

@froggomad
Copy link

froggomad commented Apr 22, 2023

Duplicates

  • I have searched the existing issues

Summary 💡

When given a goal to spawn an agent with a specific task, the agent should be trained on how to perform that task first.

For instance, I'm trying to create a midjourney prompt bot with one agent that generates prompts and another agent that critiques those prompts. However, neither spawned agent knows anything about midjourney or what goes into a prompt even though these topics were researched and saved to memory beforehand.

Assistant Specification

Here's the assistant I created:

AI Name: Midjourney Prompt Master

Midjourney Prompt Master is: An AI that spawns and trains agents in order to make the best midjourney prompts.

Goals

  1. Research midjourney documentation and save information about prompt generation and parameters to memory. Only use Midjourney v5 for research.
  2. Research what creates a good midjourney prompt. Pay special attention to camera, lighting, and style.
  3. Spawn an agent that creates midjourney prompts. Before asking it to perform any tasks, train it on what makes a good midjourney prompt by using information stored in memory or on disk about midjourney.
  4. Spawn another agent that critiques the first agent's prompts and generates new prompts based on the critique. Before asking it to perform any tasks, train it on what makes a good midjourney prompt by using information stored in memory or on disk about midjourney.
  5. Save the prompts, critiques, and new prompts to a file.

Auto GPT Steps

NEXT ACTION: COMMAND = google ARGUMENTS = {'input': 'Midjourney v5 documentation'}

NEXT ACTION: COMMAND = browse_website ARGUMENTS = {'url': 'https://docs.midjourney.com/docs/quick-start', 'question': 'What makes a good midjourney prompt?'}

Spawning the Agent

THOUGHTS: I should spawn an agent that creates midjourney prompts and train it on what makes a good midjourney prompt. Before asking it to perform any tasks, I will use the information I gathered from my research to train it.
REASONING: Spawning an agent that creates midjourney prompts will help me generate prompts more efficiently. Training the agent on what makes a good midjourney prompt will ensure that the prompts it generates are of high quality.

PLAN:

  • Spawn an agent that creates midjourney prompts
  • Train the agent on what makes a good midjourney prompt
  • Use the information gathered from my research to train the agent
  • Determine what task to perform next
  • Respond with the appropriate command

CRITICISM: I need to ensure that the agent is properly trained before asking it to perform any tasks.

NEXT ACTION: COMMAND = start_agent ARGUMENTS = {'name': 'midjourney_prompt_agent', 'task': 'Create midjourney prompts', 'prompt': 'Create a midjourney prompt that describes a finished work in a clear and specific manner.'}

SYSTEM: Command start_agent returned: Agent midjourney_prompt_agent created with key 0. First response: "Describe in detail the final product or outcome of your project, including any notable features or accomplishments."

THOUGHTS: I should spawn another agent that critiques the first agent's prompts and generates new prompts based on the critique. Before asking it to perform any tasks, I will use the information I gathered from my research to train it.

REASONING: Spawning another agent that critiques the first agent's prompts and generates new prompts based on the critique will help me improve the quality of the prompts generated. Training the agent on what makes a good midjourney prompt will ensure that the critiques and new prompts it generates are of high quality.

PLAN:

  • Spawn another agent that critiques the first agent's prompts and generates new prompts based on the critique
  • Train the agent on what makes a good midjourney prompt
  • Use the information gathered from my research to train the agent
  • Determine what task to perform next
  • Respond with the appropriate command

CRITICISM: I need to ensure that the agent is properly trained before asking it to perform any tasks.

NEXT ACTION: COMMAND = start_agent ARGUMENTS = {'name': 'midjourney_prompt_critique_agent', 'task': 'Critique and generate midjourney prompts', 'prompt': 'Critique the midjourney prompt generated by the midjourney_prompt_agent and generate a new prompt based on the critique.'}

Result

SYSTEM: Command start_agent returned: Agent midjourney_prompt_critique_agent created with key 1. First response: The midjourney prompt generated by the midjourney_prompt_agent is: "As the sun set behind the mountains, the group realized they were lost. They had to find shelter before nightfall." While this prompt sets up a potentially interesting situation, it is quite generic and lacks specificity. It doesn't give much information about the characters or their motivations, and it doesn't provide any unique or unexpected elements to the story. A new prompt could be: "As the last rays of sunlight disappeared, the group of hikers stumbled upon an abandoned cabin in the woods. But as they settled in for the night, they began to realize that they were not alone." This prompt adds more intrigue and suspense to the story, as well as providing a specific setting and potential conflict. It also leaves room for the characters to be developed and for unexpected twists to occur.

Aborted!

Examples 🌈

"Valid" prompt examples

old man with a messy beard and messy hair, smoking a pipe, wearing a kangol hat, facing the camera, minimalistic --ar 4:6 --v 5

skeleton wearing a trench coat --ar 16:9 --v 5

blue frog wearing a tophat, minimalist --ar 4:6 --v 5

mad scientist frog at a computer, lighting type: dreamlike, messy hair, --ar 6:9 --v 5

Motivation 🔦

I'd like to test the AGI approach of creating specialized agents to perform tasks and critique one another

@ntindle ntindle added enhancement New feature or request needs discussion To be discussed among maintainers labels Apr 23, 2023
@beddows
Copy link

beddows commented Apr 23, 2023

Did you try putting a "valid" prompt example in the Goals (ai_settings.yaml)? That might help set expectations.

@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
enhancement New feature or request needs discussion To be discussed among maintainers Stale
Projects
None yet
Development

No branches or pull requests

4 participants