menikev commited on
Commit
7dec672
·
verified ·
1 Parent(s): 0cd0124

Update crypto__analysis_tasks.py

Browse files
Files changed (1) hide show
  1. crypto__analysis_tasks.py +103 -82
crypto__analysis_tasks.py CHANGED
@@ -1,83 +1,104 @@
1
- from crewai import Task
2
- from textwrap import dedent
3
-
4
- class CryptoAnalysisTasks:
5
- def market_research(self, agent, crypto):
6
- return Task(description=dedent(f"""
7
- Conduct comprehensive market research on {crypto}.
8
- Analyze its current market position, recent price movements,
9
- and overall market sentiment. Include information about its
10
- technology, use cases, and any recent developments or partnerships.
11
-
12
- Your final answer MUST be a detailed report that includes:
13
- 1. Current market status
14
- 2. Recent price analysis
15
- 3. Market sentiment overview
16
- 4. Key technological aspects and use cases
17
- 5. Recent news and developments
18
-
19
- Make sure to use the most recent data possible.
20
-
21
- Selected cryptocurrency: {crypto}
22
- """),
23
- agent=agent
24
- )
25
-
26
- def technical_analysis(self, agent):
27
- return Task(description=dedent(f"""
28
- Perform a thorough technical analysis of the cryptocurrency.
29
- Examine key technical indicators such as RSI, moving averages,
30
- and trading volumes. Identify potential support and resistance levels.
31
-
32
- Your final report MUST include:
33
- 1. Analysis of key technical indicators
34
- 2. Identification of chart patterns
35
- 3. Support and resistance levels
36
- 4. Volume analysis
37
- 5. Short-term and long-term price projections based on technical factors
38
-
39
- Ensure your analysis is based on the most recent market data.
40
- """),
41
- agent=agent
42
- )
43
-
44
- def sentiment_analysis(self, agent):
45
- return Task(description=dedent(f"""
46
- Conduct a sentiment analysis of the cryptocurrency across various platforms.
47
- Analyze social media trends, news sentiment, and community engagement.
48
-
49
- Your final answer must be a comprehensive report that includes:
50
- 1. Overall sentiment score
51
- 2. Analysis of social media trends
52
- 3. News sentiment overview
53
- 4. Community engagement metrics
54
- 5. Any notable shifts in sentiment and potential reasons
55
-
56
- Use the most recent data and consider both quantitative and qualitative factors.
57
- """),
58
- agent=agent
59
- )
60
-
61
- def recommend(self, agent):
62
- return Task(description=dedent(f"""
63
- Review and synthesize the analyses provided by the Market Analyst
64
- and Technical Analyst. Combine these insights to form a comprehensive
65
- investment recommendation.
66
-
67
- Consider all aspects, including market trends, technical indicators,
68
- sentiment analysis, and fundamental factors.
69
-
70
- Your final answer MUST be a detailed investment recommendation report for your client. It should include:
71
- 1. Executive summary
72
- 2. Market analysis recap
73
- 3. Technical analysis insights
74
- 4. Sentiment analysis overview
75
- 5. Risk assessment
76
- 6. Short-term and long-term price projections
77
- 7. Clear investment strategy and recommendations
78
- 8. Potential scenarios and their impacts
79
-
80
- Provide a well-formatted, comprehensive report that a client can use to make informed decisions.
81
- """),
82
- agent=agent
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
83
  )
 
1
+ from crewai import Task
2
+ from textwrap import dedent
3
+
4
+ class CryptoAnalysisTasks:
5
+ def market_research(self, agent, crypto):
6
+ return Task(description=dedent(f"""
7
+ Conduct comprehensive market research on {crypto}.
8
+ Analyze its current market position, recent price movements,
9
+ and overall market sentiment. Include information about its
10
+ technology, use cases, and any recent developments or partnerships.
11
+
12
+ Your final answer MUST be a detailed report that includes:
13
+ 1. Current market status
14
+ 2. Recent price analysis
15
+ 3. Market sentiment overview
16
+ 4. Key technological aspects and use cases
17
+ 5. Recent news and developments
18
+
19
+ Make sure to use the most recent data possible.
20
+
21
+ Selected cryptocurrency: {crypto}
22
+ """),
23
+ expected_output="A detailed report covering the current market status, recent price analysis, market sentiment overview, key technological aspects and use cases, and recent news and developments.",
24
+ agent=agent
25
+ )
26
+
27
+ def technical_analysis(self, agent):
28
+ return Task(description=dedent(f"""
29
+ Perform a thorough technical analysis of the cryptocurrency.
30
+ Examine key technical indicators such as RSI, moving averages,
31
+ and trading volumes. Identify potential support and resistance levels.
32
+
33
+ Your final report MUST include:
34
+ 1. Analysis of key technical indicators
35
+ 2. Identification of chart patterns
36
+ 3. Support and resistance levels
37
+ 4. Volume analysis
38
+ 5. Short-term and long-term price projections based on technical factors
39
+
40
+ Ensure your analysis is based on the most recent market data.
41
+ """),
42
+ expected_output="A technical analysis report that includes key technical indicators, chart patterns, support and resistance levels, volume analysis, and price projections.",
43
+ agent=agent
44
+ )
45
+
46
+ def sentiment_analysis(self, agent):
47
+ return Task(description=dedent(f"""
48
+ Conduct a sentiment analysis of the cryptocurrency across various platforms.
49
+ Analyze social media trends, news sentiment, and community engagement.
50
+
51
+ Your final answer must be a comprehensive report that includes:
52
+ 1. Overall sentiment score
53
+ 2. Analysis of social media trends
54
+ 3. News sentiment overview
55
+ 4. Community engagement metrics
56
+ 5. Any notable shifts in sentiment and potential reasons
57
+
58
+ Use the most recent data and consider both quantitative and qualitative factors.
59
+ """),
60
+ expected_output="""
61
+ A comprehensive sentiment analysis report that includes:
62
+ 1. An overall sentiment score for the cryptocurrency.
63
+ 2. Detailed analysis of social media trends related to the cryptocurrency.
64
+ 3. Overview of the sentiment reflected in news articles and reports.
65
+ 4. Metrics and insights on community engagement (e.g., forum discussions, user activity).
66
+ 5. Any notable shifts in sentiment, along with potential reasons or events that caused these changes.
67
+ """,
68
+ agent=agent
69
+ )
70
+
71
+ def recommend(self, agent):
72
+ return Task(description=dedent(f"""
73
+ Review and synthesize the analyses provided by the Market Analyst
74
+ and Technical Analyst. Combine these insights to form a comprehensive
75
+ investment recommendation.
76
+
77
+ Consider all aspects, including market trends, technical indicators,
78
+ sentiment analysis, and fundamental factors.
79
+
80
+ Your final answer MUST be a detailed investment recommendation report for your client. It should include:
81
+ 1. Executive summary
82
+ 2. Market analysis recap
83
+ 3. Technical analysis insights
84
+ 4. Sentiment analysis overview
85
+ 5. Risk assessment
86
+ 6. Short-term and long-term price projections
87
+ 7. Clear investment strategy and recommendations
88
+ 8. Potential scenarios and their impacts
89
+
90
+ Provide a well-formatted, comprehensive report that a client can use to make informed decisions.
91
+ """),
92
+ expected_output="""
93
+ A detailed investment recommendation report that includes:
94
+ 1. An executive summary summarizing the key findings and recommendations.
95
+ 2. A recap of the market analysis, highlighting key market trends and their implications.
96
+ 3. Insights from the technical analysis, including key indicators and price projections.
97
+ 4. Overview of sentiment analysis results, summarizing public and community sentiment.
98
+ 5. A thorough risk assessment that outlines potential risks and their impact.
99
+ 6. Short-term and long-term price projections based on both market and technical analysis.
100
+ 7. A clear and actionable investment strategy, with specific recommendations.
101
+ 8. Analysis of potential scenarios (e.g., bullish, bearish) and how they might impact the investment strategy.
102
+ """,
103
+ agent=agent
104
  )