Skip to content

Commit

Permalink
Fixed mypy
Browse files Browse the repository at this point in the history
  • Loading branch information
gabrielfior committed Apr 11, 2024
1 parent bcbb2ac commit 64d8ac6
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import typing as t
from datetime import datetime
from datetime import datetime, timedelta

import typer
from loguru import logger
Expand All @@ -23,6 +23,7 @@
MarketType,
get_binary_markets,
)
from prediction_market_agent_tooling.tools.utils import utcnow

from prediction_market_agent.agents.crewai_subsequential_agent.crewai_agent_subquestions import (
CrewAIAgentSubquestions,
Expand All @@ -33,7 +34,7 @@ def build_binary_agent_market_from_question(question: str) -> AgentMarket:
return AgentMarket(
id=question,
url=question,
close_time=None,
close_time=utcnow() + timedelta(days=1),
volume=None,
question=question,
p_yes=Probability(0.5),
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import random

import typing as t
from prediction_market_agent_tooling.deploy.agent import DeployableAgent
from prediction_market_agent_tooling.markets.agent_market import AgentMarket
from prediction_market_agent_tooling.markets.markets import MarketType
Expand All @@ -16,9 +16,10 @@ class DeployableThinkThoroughlyAgent(DeployableAgent):
def __init__(self) -> None:
super().__init__()

def pick_markets(self, markets: list[AgentMarket]) -> list[AgentMarket]:
def pick_markets(self, markets: t.Sequence[AgentMarket]) -> t.Sequence[AgentMarket]:
# We simply pick 5 random markets to bet on
picked_markets: list[AgentMarket] = []
markets = list(markets)
random.shuffle(markets)
for market in markets:
# Assume very high probability markets are already known, and have
Expand Down

0 comments on commit 64d8ac6

Please sign in to comment.