Code0ut commited on
Commit
1b6e30f
·
verified ·
1 Parent(s): 5d215eb

Upload folder using huggingface_hub

Browse files
Files changed (1) hide show
  1. models.py +5 -19
models.py CHANGED
@@ -11,29 +11,15 @@ from typing import Any, Dict, Optional
11
 
12
  from openenv.core.env_server.types import Action, Observation
13
 
14
- TASKS = {
15
- "easy": {
16
- "goal": "Make profit in 5 steps",
17
- "target_profit": 0.01
18
- },
19
- "medium": {
20
- "goal": "Maximize portfolio value",
21
- "target_profit": 0.05
22
- },
23
- "hard": {
24
- "goal": "Achieve 10% return",
25
- "target_return": 0.1
26
- }
27
- }
28
 
29
  class StockExchangeMarket(Enum):
30
  BSE = "bse"
31
  NSE = "nse"
32
 
33
- class task_type(str, Enum):
34
- Easy = "easy"
35
- Medium = "medium"
36
- Hard = "hard"
37
 
38
  class FinenvAction(Action):
39
  """
@@ -51,7 +37,7 @@ class FinenvAction(Action):
51
  # Trading fields
52
  quantity: Optional[int] = 0
53
 
54
- task_type: Optional[task_type] = None
55
 
56
  # Initialization fields
57
  stock: Optional[str] = None
 
11
 
12
  from openenv.core.env_server.types import Action, Observation
13
 
14
+ from typing import Optional, Literal
15
+
16
+
 
 
 
 
 
 
 
 
 
 
 
17
 
18
  class StockExchangeMarket(Enum):
19
  BSE = "bse"
20
  NSE = "nse"
21
 
22
+
 
 
 
23
 
24
  class FinenvAction(Action):
25
  """
 
37
  # Trading fields
38
  quantity: Optional[int] = 0
39
 
40
+ task_type: Optional[Literal["easy", "medium", "hard"]] = None
41
 
42
  # Initialization fields
43
  stock: Optional[str] = None