-
Notifications
You must be signed in to change notification settings - Fork 1
/
tasks.py
32 lines (27 loc) · 1.29 KB
/
tasks.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
from crewai import Task
from textwrap import dedent
from agents import linkedin_scraper_agent, web_researcher_agent, doppelganger_agent
scrape_linkedin_task = Task(
description=dedent(
"Scrape a LinkedIn profile to get some relevant posts"),
expected_output=dedent("A list of LinkedIn posts obtained from a LinkedIn profile"),
agent=linkedin_scraper_agent,
)
web_research_task = Task(
description=dedent(
"Get valuable and high quality web information about the comparison between Llama 2 and Llama 3"),
expected_output=dedent("Your task is to gather high quality information about the comparison"
" between Llama 2 and Llama 3"),
agent=web_researcher_agent,
)
create_linkedin_post_task = Task(
description=dedent(
"Create a LinkedIn post comparing Llama 2 and Llama 3 following the writing-style "
"expressed in the scraped LinkedIn posts."
),
expected_output=dedent("A high-quality and engaging LinkedIn post comparing Llama 2 and Llama 3."
" The LinkedIn post must follow"
" the same writing-style as the one expressed in the scraped LinkedIn posts"),
agent=doppelganger_agent,
)
create_linkedin_post_task.context = [scrape_linkedin_task, web_research_task]