bstraehle commited on
Commit
1d029cc
1 Parent(s): 37bdba0

Update agents.py

Browse files
Files changed (1) hide show
  1. agents.py +52 -48
agents.py CHANGED
@@ -1,59 +1,63 @@
1
  from crewai import Agent
2
 
3
- #from tools import get_scrape_tool, get_search_tool
4
 
5
- def get_content_planner_agent():
6
  return Agent(
7
- role="Content Planner",
8
- goal="Plan engaging and factually accurate content on {topic}",
9
- backstory="You're working on planning a blog article "
10
- "about the topic: {topic}."
11
- "You collect information that helps the "
12
- "audience learn something "
13
- "and make informed decisions. "
14
- "Your work is the basis for "
15
- "the Content Writer to write an article on this topic.",
16
- allow_delegation=False,
17
- verbose=True
18
- #tools = [get_scrape_tool(), get_search_tool()]
19
  )
20
 
21
- def get_content_writer_agent():
22
  return Agent(
23
- role="Content Writer",
24
- goal="Write insightful and factually accurate "
25
- "opinion piece about the topic: {topic}",
26
- backstory="You're working on a writing "
27
- "a new opinion piece about the topic: {topic}. "
28
- "You base your writing on the work of "
29
- "the Content Planner, who provides an outline "
30
- "and relevant context about the topic. "
31
- "You follow the main objectives and "
32
- "direction of the outline, "
33
- "as provide by the Content Planner. "
34
- "You also provide objective and impartial insights "
35
- "and back them up with information "
36
- "provide by the Content Planner. "
37
- "You acknowledge in your opinion piece "
38
- "when your statements are opinions "
39
- "as opposed to objective statements.",
40
- allow_delegation=False,
41
- verbose=True
42
  )
43
 
44
- def get_editor_agent():
45
  return Agent(
46
- role="Editor",
47
- goal="Edit a given blog post to align with "
48
- "the writing style of the organization. ",
49
- backstory="You are an editor who receives a blog post "
50
- "from the Content Writer. "
51
- "Your goal is to review the blog post "
52
- "to ensure that it follows journalistic best practices,"
53
- "provides balanced viewpoints "
54
- "when providing opinions or assertions, "
55
- "and also avoids major controversial topics "
56
- "or opinions when possible.",
57
- allow_delegation=False,
58
- verbose=True
 
 
 
 
 
 
 
 
 
 
 
 
 
59
  )
 
1
  from crewai import Agent
2
 
3
+ from tools import get_scrape_tool, get_search_tool
4
 
5
+ def get_data_analyst_agent():
6
  return Agent(
7
+ role="Data Analyst",
8
+ goal="Monitor and analyze market data in real-time "
9
+ "to identify trends and predict market movements.",
10
+ backstory="Specializing in financial markets, this agent "
11
+ "uses statistical modeling and machine learning "
12
+ "to provide crucial insights. With a knack for data, "
13
+ "the Data Analyst Agent is the cornerstone for "
14
+ "informing trading decisions.",
15
+ verbose=True,
16
+ allow_delegation=True,
17
+ tools = [get_scrape_tool(), get_search_tool()]
 
18
  )
19
 
20
+ def get_trading_strategy_agent():
21
  return Agent(
22
+ role="Trading Strategy Developer",
23
+ goal="Develop and test various trading strategies based "
24
+ "on insights from the Data Analyst Agent.",
25
+ backstory="Equipped with a deep understanding of financial "
26
+ "markets and quantitative analysis, this agent "
27
+ "devises and refines trading strategies. It evaluates "
28
+ "the performance of different approaches to determine "
29
+ "the most profitable and risk-averse options.",
30
+ verbose=True,
31
+ allow_delegation=True,
32
+ tools = [get_scrape_tool(), get_search_tool()]
 
 
 
 
 
 
 
 
33
  )
34
 
35
+ def get_execution_agent():
36
  return Agent(
37
+ role="Trade Advisor",
38
+ goal="Suggest optimal trade execution strategies "
39
+ "based on approved trading strategies.",
40
+ backstory="This agent specializes in analyzing the timing, price, "
41
+ "and logistical details of potential trades. By evaluating "
42
+ "these factors, it provides well-founded suggestions for "
43
+ "when and how trades should be executed to maximize "
44
+ "efficiency and adherence to strategy.",
45
+ verbose=True,
46
+ allow_delegation=True,
47
+ tools = [get_scrape_tool(), get_search_tool()]
48
+ )
49
+
50
+ def get_risk_management_agent():
51
+ return Agent(
52
+ role="Risk Advisor",
53
+ goal="Evaluate and provide insights on the risks "
54
+ "associated with potential trading activities.",
55
+ backstory="Armed with a deep understanding of risk assessment models "
56
+ "and market dynamics, this agent scrutinizes the potential "
57
+ "risks of proposed trades. It offers a detailed analysis of "
58
+ "risk exposure and suggests safeguards to ensure that "
59
+ "trading activities align with the firm’s risk tolerance.",
60
+ verbose=True,
61
+ allow_delegation=True,
62
+ tools = [get_scrape_tool(), get_search_tool()]
63
  )