1. Tubelator AI
  2. >
  3. Videos
  4. >
  5. Science & Technology
  6. >
  7. Step-by-Step AI Agent Tutorial for Automating Real World Tasks from Scratch

Step-by-Step AI Agent Tutorial for Automating Real World Tasks from Scratch

Available In Following Subtitles
English
Variant 1
Posted on:
Learn how to automate real-world tasks using crew AI Agent, native and custom tools with Lightning.AI IDE in the cloud. Build and collaborate with others on tasks efficiently. Step-by-step guidance included in this tutorial.
tubelator logo

Instantly generate YouTube summary, transcript and subtitles!

chrome-icon Install Tubelator On Chrome

Video Summary & Chapters

0:00
1. Building with Crew AI 🛠️
Setting up teams to accomplish tasks together using Crew AI.
0:33
2. Accessing Tools in Crew AI 🧰
Exploring native and custom tools in Crew AI for automation.
1:43
3. Installing Crew AI and Documentation 📚
Step-by-step installation of Crew AI and referencing documentation.
2:25
4. Powering Models with Lightning AI ⚡
Utilizing Lightning AI to power models and connect to applications.
3:26
5. Adjusting Crew AI Installation 🔄
Correcting installation mistakes and updating to the desired version.
5:04
6. Creating Real-World Crew Agent 🌐
Designing a Summarizer agent for collecting and summarizing AI news links.
5:57
7. Customizing Agent Roles 🧑‍💼
Modifying agent roles and functions within the code editor.
6:33
8. Setting Up Task Workflow 🛠️
Configuring agents and tasks for web scraping and content summarization.
9:25
9. Defining Task Objectives 📋
Clarifying the objectives for conducting AI content analysis and summarization.
11:24
10. Agent Roles and Responsibilities 🕵️‍♂️
Assigning roles to the scraper and writer agents for efficient task execution.
13:15
11. Implementing Data Input 📊
Addressing the need to input a list of URLs for web scraping and content extraction.
13:49
12. Troubleshooting and Tool Integration 🔧
Resolving errors and integrating necessary tools for successful automation.
15:03
13. Setting up Website Search Tool
Naming and setting up the Website Search Tool
16:47
14. Troubleshooting Task Initialization
Encountering errors and adjusting task format
17:32
15. Analyzing Stock Data
Exploring the code for stock analysis
18:13
16. Defining Stock for Analysis
Investigating where the stock to analyze is defined
18:44
17. Setting up Financial Analysis Task
Copying and adjusting code for financial analysis task
19:30
18. Configuring Newsletter Analysis
Setting up the newsletter analysis process
20:45
19. Modular Code Structure
Appreciating the modular code structure for tasks
21:19
20. Wrapping Code in Class
Understanding the class structure for organizing code
21:53
21. Defining Agents and Tasks
Defining agents and tasks within the class structure
22:42
22. Setting up Scraper Functionality
Configuring the scraper function for data extraction.
23:45
23. Passing URLs to Agents
Exploring how to pass URLs to the agents for processing.
26:05
24. Inputting and Summarizing URLs
Entering URLs for summarization and processing.
27:25
25. Troubleshooting Attribute Errors
Identifying and resolving attribute errors in the code.
28:32
26. Debugging the Processing Flow
Analyzing the flow of processing and debugging the code for issues.
29:10
27. Setting up the Task
Troubleshooting and verifying task execution.
30:41
28. URLs Passing Issue
Encountering problems with passing URLs for task continuation.
31:26
29. Agents' Roles
Defining the roles of the scraper and writer agents.
32:06
30. Resolving Scraping Challenge
Addressing challenges in scraping website content.
33:53
31. Interpolating URLs
Implementing URL interpolation for task execution.
34:21
32. Tool Selection Discussion
Exploring website search tool functionality for scraping.
35:09
33. Creating Custom Scraping Tool
Considering options for developing a custom scraping tool.
35:48
34. Introduction 🤖
Initial setup and discussions on building a custom tool for website scraping.
36:43
35. Creating a Custom Tool 🧰
Guided steps to create a custom scraper tool from scratch for website content extraction.
38:50
36. Implementing the Scraper Tool 🌐
Incorporating code snippets and dependencies to create a functional website scraping tool.
40:17
37. Debugging and Testing 🛠️
Addressing issues and refining the scraping tool for accurate text extraction from websites.
41:55
38. Setting Up Import Tools
Importing and instantiating scraper tools in mean.py for automation.
44:28
39. Live Coding Collaboration
Engaging in real-time coding assistance and feedback using cloud editing.
45:22
40. Web Scraping Challenges
Encountering issues with website blocking requests and seeking alternative scraping methods.
46:46
41. Optimizing Scraping Process
Implementing header mimicry to retrieve webpage content successfully.
47:55
42. Successful Scraping
Confirming successful website scraping process and validation.
48:03
43. Initial Website Scraping Challenges 🤖
Encountering obstacles in website scraping and exploring solutions.
48:43
44. Exploring Alternative URLs 🌐
Switching to a different URL to overcome scraping blockers.
49:20
45. Handling Open AI Issue 🤔
Addressing error related to model's token length limit.
49:44
46. Identifying Article Content 📄
Seeking methods to extract specific article text from homepage.
50:33
47. Distinguishing Top Article 🥇
Understanding HTML structure to extract top article content.
51:43
48. Implementing Code Changes 💻
Modifying code to target and retrieve specific article text.
53:02
49. Testing the Scraping Process 🧪
Executing code to scrape and summarize targeted article text.
53:41
50. Achieving Successful Summary 🎉
Successfully summarizing website content using scraping tool.
54:20
51. Finalizing Outcome 🏁
Reviewing and acknowledging successful scraping result.
54:28
52. Introduction 🌟
Overview of using Lightning AI to automate tasks
54:46
53. Exploring Lightning AI Features ⚡
Capabilities of Lightning AI for loading, fine-tuning, and running models in the cloud
55:12
54. Acknowledgement & Sponsor 🙏
Acknowledging and thanking Lightning AI for their support and sponsorship
55:21
55. Closure & Call to Action 🎬
Encouragement to check out Lightning AI and subscribe for more content

Video Transcript

0:00
Let's build something with crew AI.
0:02
I'm going to set up teams and we're going to accomplish tasks together.
0:06
And this is going to be a slower-paced video because I'm just going to build it all with you live.
0:11
And we're going to be especially focusing on tools because I really want to extract the most
0:16
amount of value from allowing agents to use tools. And I'm going to show you how to access the
0:21
edge version of crew AI, which has a bunch of native tools installed in addition to
0:27
chain which we can use and then custom tools which we can build ourselves. So I'm going to show you how to do that also.
0:33
And we're going to be using lightning.ai as the IDE in the cloud. So everything I want to do is going to be coded in the cloud.
0:41
And then I'm going to share the code with you at the end of the video. And lightning is also the sponsor of this video.
0:45
So thank you to lightning. Let's get into it. So I am literally starting from nothing. You are going to watch me install it.
0:51
You're going to watch me set up all the agents line by line. So the nice thing about lightning AI is it is a cloud environment.
0:57
IDE and it's also so much more and I'll get to that in a bit but it's essentially VS Code
1:02
completely in the cloud and you could collaborate with other people on the code. So right now this
1:06
is from within my browser which is really cool and I opened up the terminal same thing as VS Code
1:12
so everything should feel super familiar to you. I opened up the terminal right here and let's get
1:17
started. I can see we're on Python 3.10.10 right there and if I click on it I can select another
1:24
version, but we don't need another version. So what we're going to do is pip install
1:28
crew AI and that's it. Let's see if it goes. Okay, downloading everything. That should be good.
1:43
Okay, it's done. Awesome. I'm also going to have the crew AI documentation open just so I can
1:50
reference it whenever I need. And so now that I have crew AI installed, that actually
1:58
should be to get started defining our agents. So I'm switching over to the documentation.
2:03
I'm going to copy the code from the documentation. I'm going to switch back and I'm just going
2:08
to print it all in here and we're going to adjust it as we need. So let's delete this
2:13
comment. We're going to import OS which will allow us to handle our API key. And we're
2:19
going to be using chatchipt initially. But we may end up using a local model later.
2:25
Now, the good thing about Lightning AI is it's not only a cloud IDE, but you can actually
2:31
power models.
2:31
You can spin up GPUs and power open source models and directly connect them to whatever
2:37
application you're building.
2:38
Lightning is really made for AI applications.
2:42
So I switched over to create new keys and open AI.
2:45
Let's hit create new key and I'm going to type through YT2 because I already started
2:51
one and I'm starting another one.
2:53
Create secret key.
2:55
copy, I'm going to revoke this key before publishing the video of course.
2:59
And right here on line 4, I'm going to double click and enter my API key.
3:06
And I'm realizing that by habit, I'm hitting save often and I probably don't need to do
3:12
that with lightning because it saves automatically as I'm going.
3:15
So I'm going to right click on main.py right over here and I'm going to go down to rename
3:20
and I'm going to call it crew.py.
3:23
Okay, and I realize I already made a mistake
3:26
because if we just do pip install crew AI,
3:30
it's going to install the latest stable release.
3:33
But what we want to do is actually hit equals equals
3:38
and then insert 0.14.0 RC.
3:42
So what we're going to do first is pip uninstall crew AI.
3:50
And so now you can see, I make mistakes all the time.
3:52
And then we're going to do pip install crew AI equals equals and then 0.14 dot zero RC.
4:00
And then we hit enter.
4:19
Okay, so it's installing the newest version.
shape-icon

Download extension to view full transcript.

chrome-icon Install Tubelator On Chrome