menikev commited on
Commit
942ee62
·
verified ·
1 Parent(s): 514fa3b

Update crypto__analysis_tasks.py

Browse files
Files changed (1) hide show
  1. crypto__analysis_tasks.py +47 -10
crypto__analysis_tasks.py CHANGED
@@ -4,32 +4,69 @@ from textwrap import dedent
4
  class CryptoAnalysisTasks:
5
  def market_research(self, agent, crypto):
6
  return Task(
7
- description=f"""Get current price and market cap for {crypto}. Find one recent news headline.
8
- Format: Price: $X, Market Cap: $Y, News: [headline]""",
9
- expected_output=f"Current price, market cap, and one news headline for {crypto}",
 
 
 
 
 
 
 
 
 
10
  agent=agent
11
  )
12
 
13
  def technical_analysis(self, agent, crypto):
14
  return Task(
15
- description=f"""Calculate RSI and 7-day moving average for {crypto}.
16
- Format: RSI: X, 7-day MA: $Y, Signal: [overbought/oversold/neutral]""",
 
 
 
 
 
 
 
 
 
17
  expected_output=f"RSI, moving average, and technical signal for {crypto}",
18
  agent=agent
19
  )
20
 
21
  def sentiment_analysis(self, agent, crypto):
22
  return Task(
23
- description=f"""Analyze overall market sentiment for {crypto} based on recent price action.
24
- Format: Sentiment: [Positive/Negative/Neutral], Reason: [brief explanation]""",
 
 
 
 
 
 
 
 
 
25
  expected_output=f"Market sentiment assessment for {crypto}",
26
  agent=agent
27
  )
28
 
29
  def recommend(self, agent, crypto):
30
  return Task(
31
- description=f"""Based on previous analyses, provide investment recommendation for {crypto}.
32
- Format: Recommendation: [BUY/HOLD/SELL], Confidence: [High/Medium/Low], Reason: [key factor]""",
33
- expected_output=f"Clear investment recommendation for {crypto}",
 
 
 
 
 
 
 
 
 
 
34
  agent=agent
35
  )
 
4
  class CryptoAnalysisTasks:
5
  def market_research(self, agent, crypto):
6
  return Task(
7
+ description=dedent(f"""
8
+ Get current price and market cap for {crypto}. Find recent news headlines.
9
+
10
+ Instructions:
11
+ 1. Get current price for {crypto}
12
+ 2. Get market cap for {crypto}
13
+ 3. Search for recent news about {crypto}
14
+
15
+ Format your response as:
16
+ Price: $X, Market Cap: $Y, News: [headline summary]
17
+ """),
18
+ expected_output=f"Current price, market cap, and recent news headlines for {crypto}",
19
  agent=agent
20
  )
21
 
22
  def technical_analysis(self, agent, crypto):
23
  return Task(
24
+ description=dedent(f"""
25
+ Calculate RSI and 7-day moving average for {crypto}.
26
+
27
+ Instructions:
28
+ 1. Calculate RSI for {crypto}
29
+ 2. Calculate 7-day moving average for {crypto}
30
+ 3. Determine if the asset is overbought, oversold, or neutral
31
+
32
+ Format your response as:
33
+ RSI: X, 7-day MA: $Y, Signal: [overbought/oversold/neutral]
34
+ """),
35
  expected_output=f"RSI, moving average, and technical signal for {crypto}",
36
  agent=agent
37
  )
38
 
39
  def sentiment_analysis(self, agent, crypto):
40
  return Task(
41
+ description=dedent(f"""
42
+ Analyze overall market sentiment for {crypto} based on available information.
43
+
44
+ Instructions:
45
+ 1. Get current price information for {crypto}
46
+ 2. Analyze sentiment of the price action and market data
47
+ 3. Provide sentiment assessment
48
+
49
+ Format your response as:
50
+ Sentiment: [Positive/Negative/Neutral], Reason: [brief explanation]
51
+ """),
52
  expected_output=f"Market sentiment assessment for {crypto}",
53
  agent=agent
54
  )
55
 
56
  def recommend(self, agent, crypto):
57
  return Task(
58
+ description=dedent(f"""
59
+ Based on all previous analyses, provide a clear investment recommendation for {crypto}.
60
+
61
+ Consider:
62
+ 1. Current price and market cap
63
+ 2. Technical indicators (RSI, moving averages)
64
+ 3. Market sentiment
65
+ 4. Recent news impact
66
+
67
+ Format your response as:
68
+ Recommendation: [BUY/HOLD/SELL], Confidence: [High/Medium/Low], Reason: [key supporting factor]
69
+ """),
70
+ expected_output=f"Clear investment recommendation with reasoning for {crypto}",
71
  agent=agent
72
  )