AutoGen Studio 2.0 Tutorial - Skills, Multi-Agent Teams, and REAL WORLD Use Cases (NO CODE)

AutoGen Studio 2.0 Tutorial - Skills, Multi-Agent Teams, and REAL WORLD Use Cases (NO CODE)

Introduction to Autogen Studio and Building a Real-World Agent Team

In this section, the speaker introduces the new version of Autogen Studio and explains that they will be building an agent team together for a real-world use case.

Installing Autogen Studio

  • Uninstalling previous version of Autogen Studio using pip uninstall autogen studio command.
  • Manually deleting the Autogen Studio folders from Python site packages if necessary.
  • Creating a new conda environment with Python 3.11 using conda create -n AG python=3.11 command.
  • Activating the environment using conda activate AG command.
  • Installing Autogen Studio using pip install autogen studio command.
  • Running Autogen Studio UI on port 8081 using autogen studio ui --port 8081 command.

New Features in Autogen Studio

  • Introduction of the "Models" tab where different models can be pre-defined for agents.
  • Ability to have agent groups with multiple agents in addition to user proxy.

Creating a Skill to Grab YouTube Video Transcripts

In this section, the speaker demonstrates how to create a skill in Autogen Studio that grabs transcripts from YouTube videos.

Using Chat GPT to Create the Skill

  • Copying an existing skill script that fetches profiles as an example.
  • Modifying the script to accept a YouTube URL as a parameter and retrieve the transcript via the YouTube API.

Alternative Method for Retrieving YouTube Transcripts

In this section, the speaker explores an alternative method for retrieving YouTube video transcripts without requiring an API key.

Exploring Direct Access to YouTube API

  • Discovering a method that uses the YouTube API directly without needing an API key.
  • Considering the possibility of using this alternative method for retrieving transcripts.

The summary is based on the given transcript and may not include all details from the video.

Installing the Library and Creating a New Skill

The speaker explains how to install a library and create a new skill in Autogen Studio.

Installing the Library and Creating a New Skill

  • Install the required library.
  • Switch back to Autogen Studio.
  • Create a new skill named "fetch YouTube transcript".
  • Delete the sample content in the skill.
  • Paste in the desired content, which includes an example of how to use it.
  • Click "OK" to save the changes.

Creating Agents for Fetching YouTube Transcripts and Converting them into Blog Posts and Tweet Threads

The speaker demonstrates how to create agents for fetching YouTube transcripts and converting them into blog posts and tweet threads.

Creating Agents for Fetching YouTube Transcripts and Converting them into Blog Posts and Tweet Threads

  • Create a new agent named "transcript getter" with the description "takes a YouTube URL and gets the transcript from a video".
  • Set Max consecutive auto reply as default, human input mode as never, and system message as "you are an AI agent that uses the fetch YouTube transcript skill to get a YouTube transcript for subsequent processing".
  • Add the "fetch YouTube transcript" skill to this agent.
  • Create another agent named "content writer" with the description "takes raw YouTube video transcripts and converts them into blog posts and tweet threads".
  • Set Max consecutive auto reply as default, human input mode as never, and system message as "you are an insightful intelligent and witty content writer who is able to take raw YouTube video transcripts and turn them into blog posts and tweet threads".

Creating Workflow for Fetching Transcript, Creating Blog Post, & Tweet Thread

The speaker explains how to create a workflow for fetching YouTube transcripts, creating blog posts, and tweet threads.

Creating Workflow for Fetching Transcript, Creating Blog Post, & Tweet Thread

  • Go to the workflows section.
  • Click on "new workflow".
  • Select "group chat" as the type of workflow.
  • Name the workflow "YT script to content" with the description "takes a YouTube URL, gets the transcript of the video, and then creates a blog post and tweet thread from that transcript".
  • Set sender as user proxy and receiver as group chat assistant.
  • Add the "content writer" and "transcript getter" agents to the group chat assistant.
  • Fill out all necessary details for each agent in the group chat assistant.
  • Click "OK" to save the changes.

Testing the Workflow

The speaker tests out the created workflow in Autogen Studio.

Testing the Workflow

  • Go to playground.
  • Create a new session using "YT script to content".
  • Follow instructions provided in Autogen Studio for taking a YouTube URL, fetching its transcript, removing timestamps if any, and creating a blog post and tweet thread based on that transcript.

Troubleshooting an Error Message

The speaker encounters an error message while testing the workflow and troubleshoots it.

Troubleshooting an Error Message

  • Check if API key is properly set in Autogen Studio models section.
  • Retry testing after ensuring API client option is correctly configured.

Setting up the OpenAI API Key

The speaker explains how to activate AG (Autogen Studio) and set up the OpenAI API key.

Activating AG and setting up the API key

  • To activate AG, type "export open AI API key" followed by the actual API key.
  • Restart Autogen Studio after setting up the API key.

Troubleshooting and Refreshing Autogen Studio

The speaker encounters an issue with the API key not being recognized in a new tab. They troubleshoot by refreshing Autogen Studio.

Troubleshooting and refreshing Autogen Studio

  • If the API key is not recognized in a new tab, try refreshing Autogen Studio.
  • Retry using the fetch YouTube transcript skill after refreshing.
  • If issues persist, repeat the process of exporting the API key and restarting Autogen Studio.

Confirming Successful Setup

The speaker confirms that Autogen is working properly by observing activity in both the UI and terminal.

Confirming successful setup

  • Activity dots bouncing indicate that Autogen is working.
  • In terminal, observe code exchanges between agents.
  • Verify that Autogen recognizes and installs necessary skills like YouTube transcript API.

Viewing Output Results

The speaker examines the output results from running Autogen, including code output, agent messages, and generated transcripts.

Examining output results

  • Code output shows successful execution of tasks.
  • Agent messages show user instructions for using skills and steps planned by transcript getter.
  • Transcript getter installs required components and generates Python script for skill usage.
  • Generated transcript from video is displayed in UI.

Output Discrepancy and Terminal Results

The speaker notices that the final blog post and tweet thread are not displayed in the UI but can be found in the terminal.

Output discrepancy and terminal results

  • Final blog post and tweet thread are missing from the UI.
  • Switching to the terminal reveals suggested structure for the blog post and generated content.
  • Terminal displays tweet thread with emojis, hashtags, etc.
  • The reason for the output discrepancy is unknown.

Recap of Autogen Studio Usage

The speaker summarizes how to use Autogen Studio, create skills for agents, assign skills to agents, create agent teams, and execute tasks successfully.

Recap of Autogen Studio usage

  • Activate AG and set up API key.
  • Refresh Autogen Studio if issues arise.
  • Confirm successful setup through UI activity and terminal exchanges.
  • Examine code output, agent messages, and generated transcripts.
  • Note any discrepancies between UI display and terminal results.
  • Understand how to use Autogen Studio effectively.
Video description

Let's build an AutoGen team to take a YouTube video, retrieve its transcript, and then create a blog post and tweet thread from it. We'll use the newest version of AutoGen Studio and I'll show you how to use Agent Skills. Join My Newsletter for Regular AI Updates šŸ‘‡šŸ¼ https://www.matthewberman.com Need AI Consulting? āœ… https://forwardfuture.ai/ Rent a GPU (MassedCompute) šŸš€ https://bit.ly/matthew-berman-youtube USE CODE "MatthewBerman" for 50% discount My Links šŸ”— šŸ‘‰šŸ» Subscribe: https://www.youtube.com/@matthew_berman šŸ‘‰šŸ» Twitter: https://twitter.com/matthewberman šŸ‘‰šŸ» Discord: https://discord.gg/xxysSXBxFW šŸ‘‰šŸ» Patreon: https://patreon.com/MatthewBerman Media/Sponsorship Inquiries šŸ“ˆ https://bit.ly/44TC45V Links: AutoGen Advanced Tutorial - https://www.youtube.com/watch?v=PUPO2tTyPOo AutoGen Studio - https://microsoft.github.io/autogen/blog/2023/12/01/AutoGenStudio/ LiteLLM - https://github.com/BerriAI/litellm Conda - https://conda.io/projects/conda/en/latest/user-guide/install/index.html Ollama - https://ollama.ai/