prediction-market-agent-tooling 0.67.4.dev992__tar.gz → 0.68.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/PKG-INFO +1 -1
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/deploy/betting_strategy.py +14 -3
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/seer/price_manager.py +68 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/seer/seer.py +11 -7
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/seer/seer_subgraph_handler.py +2 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/seer/subgraph_data_models.py +2 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/web3_utils.py +2 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/pyproject.toml +1 -1
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/LICENSE +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/README.md +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/abis/agentresultmapping.abi.json +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/abis/debuggingcontract.abi.json +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/abis/depositablewrapper_erc20.abi.json +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/abis/erc1155.abi.json +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/abis/erc20.abi.json +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/abis/erc4626.abi.json +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/abis/erc721.abi.json +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/abis/gvp2_settlement.abi.json +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/abis/omen_dxdao.abi.json +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/abis/omen_fpmm.abi.json +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/abis/omen_fpmm_conditionaltokens.abi.json +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/abis/omen_fpmm_factory.abi.json +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/abis/omen_kleros.abi.json +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/abis/omen_oracle.abi.json +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/abis/omen_realitio.abi.json +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/abis/omen_thumbnailmapping.abi.json +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/abis/ownable.abi.json +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/abis/ownable_erc721.abi.json +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/abis/proxy.abi.json +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/abis/seer_gnosis_router.abi.json +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/abis/seer_market_factory.abi.json +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/abis/swapr_router.abi.json +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/benchmark/__init__.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/benchmark/agents.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/benchmark/benchmark.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/benchmark/utils.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/chains.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/config.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/data_download/langfuse_data_downloader.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/deploy/agent.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/deploy/agent_example.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/deploy/constants.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/deploy/gcp/deploy.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/deploy/gcp/kubernetes_models.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/deploy/gcp/utils.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/deploy/trade_interval.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/gtypes.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/jobs/__init__.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/jobs/jobs_models.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/jobs/omen/omen_jobs.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/loggers.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/logprobs_parser.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/agent_market.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/base_subgraph_handler.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/blockchain_utils.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/categorize.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/data_models.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/manifold/__init__.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/manifold/api.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/manifold/data_models.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/manifold/manifold.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/manifold/utils.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/market_fees.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/markets.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/metaculus/api.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/metaculus/data_models.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/metaculus/metaculus.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/omen/__init__.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/omen/cow_contracts.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/omen/data_models.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/omen/omen.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/omen/omen_constants.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/omen/omen_contracts.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/omen/omen_resolving.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/omen/omen_subgraph_handler.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/polymarket/api.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/polymarket/data_models.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/polymarket/data_models_web.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/polymarket/polymarket.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/polymarket/polymarket_subgraph_handler.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/polymarket/utils.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/seer/data_models.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/seer/exceptions.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/seer/seer_contracts.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/markets/seer/swap_pool_handler.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/py.typed +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/_generic_value.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/balances.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/betting_strategies/kelly_criterion.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/betting_strategies/stretch_bet_between.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/betting_strategies/utils.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/caches/db_cache.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/caches/inmemory_cache.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/caches/serializers.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/contract.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/costs.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/cow/cow_order.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/cow/models.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/cow/semaphore.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/custom_exceptions.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/datetime_utc.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/db/db_manager.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/google_utils.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/hexbytes_custom.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/httpx_cached_client.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/image_gen/image_gen.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/image_gen/market_thumbnail_gen.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/ipfs/ipfs_handler.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/is_invalid.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/is_predictable.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/langfuse_.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/langfuse_client_utils.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/omen/reality_accuracy.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/omen/sell_positions.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/parallelism.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/perplexity/perplexity_client.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/perplexity/perplexity_models.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/perplexity/perplexity_search.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/relevant_news_analysis/data_models.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/relevant_news_analysis/relevant_news_analysis.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/relevant_news_analysis/relevant_news_cache.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/rephrase.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/safe.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/singleton.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/streamlit_user_login.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/tavily/tavily_models.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/tavily/tavily_search.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/tokens/auto_deposit.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/tokens/auto_withdraw.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/tokens/main_token.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/tokens/slippage.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/tokens/token_utils.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/tokens/usd.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/transaction_cache.py +0 -0
- {prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/prediction_market_agent_tooling/tools/utils.py +0 -0
@@ -387,6 +387,9 @@ class BinaryKellyBettingStrategy(BettingStrategy):
|
|
387
387
|
answer: CategoricalProbabilisticAnswer,
|
388
388
|
override_p_yes: float | None = None,
|
389
389
|
) -> BinaryKellyBet:
|
390
|
+
if not market.is_binary:
|
391
|
+
raise ValueError("This strategy is usable only with binary markets.")
|
392
|
+
|
390
393
|
estimated_p_yes = (
|
391
394
|
answer.probability_for_market_outcome(direction)
|
392
395
|
if not override_p_yes
|
@@ -457,7 +460,9 @@ class BinaryKellyBettingStrategy(BettingStrategy):
|
|
457
460
|
amounts = {
|
458
461
|
bet_outcome: BettingStrategy.cap_to_profitable_bet_amount(
|
459
462
|
market, market.get_token_in_usd(kelly_bet_size), bet_outcome
|
460
|
-
)
|
463
|
+
)
|
464
|
+
if kelly_bet_size > 0
|
465
|
+
else USD(0),
|
461
466
|
}
|
462
467
|
target_position = Position(market_id=market.id, amounts_current=amounts)
|
463
468
|
trades = self._build_rebalance_trades_from_positions(
|
@@ -512,9 +517,15 @@ class BinaryKellyBettingStrategy(BettingStrategy):
|
|
512
517
|
)
|
513
518
|
return kelly_bet_size
|
514
519
|
|
515
|
-
|
520
|
+
filtered_pool = {
|
521
|
+
outcome: pool_value
|
522
|
+
for outcome, pool_value in market.outcome_token_pool.items()
|
523
|
+
if INVALID_OUTCOME_LOWERCASE_IDENTIFIER not in outcome.lower()
|
524
|
+
}
|
525
|
+
|
526
|
+
pool_balances = [i.as_outcome_wei for i in filtered_pool.values()]
|
516
527
|
# stay float for compatibility with `minimize_scalar`
|
517
|
-
total_pool_balance = sum([i.value for i in
|
528
|
+
total_pool_balance = sum([i.value for i in filtered_pool.values()])
|
518
529
|
|
519
530
|
# The bounds below have been found to work heuristically.
|
520
531
|
optimized_bet_amount = minimize_scalar(
|
@@ -2,11 +2,15 @@ from cachetools import TTLCache, cached
|
|
2
2
|
from pydantic import BaseModel
|
3
3
|
from web3 import Web3
|
4
4
|
|
5
|
+
from prediction_market_agent_tooling.deploy.constants import (
|
6
|
+
INVALID_OUTCOME_LOWERCASE_IDENTIFIER,
|
7
|
+
)
|
5
8
|
from prediction_market_agent_tooling.gtypes import (
|
6
9
|
ChecksumAddress,
|
7
10
|
CollateralToken,
|
8
11
|
HexAddress,
|
9
12
|
OutcomeStr,
|
13
|
+
OutcomeToken,
|
10
14
|
Probability,
|
11
15
|
)
|
12
16
|
from prediction_market_agent_tooling.loggers import logger
|
@@ -182,3 +186,67 @@ class PriceManager:
|
|
182
186
|
normalized_prices[outcome] = new_price
|
183
187
|
|
184
188
|
return normalized_prices
|
189
|
+
|
190
|
+
def build_initial_probs_from_pool(
|
191
|
+
self, model: SeerMarket, wrapped_tokens: list[ChecksumAddress]
|
192
|
+
) -> tuple[dict[OutcomeStr, Probability], dict[OutcomeStr, OutcomeToken]]:
|
193
|
+
"""
|
194
|
+
Builds a map of outcome to probability and outcome token pool.
|
195
|
+
"""
|
196
|
+
probability_map = {}
|
197
|
+
outcome_token_pool = {}
|
198
|
+
wrapped_tokens_with_supply = [
|
199
|
+
(
|
200
|
+
token,
|
201
|
+
SeerSubgraphHandler().get_pool_by_token(
|
202
|
+
token, model.collateral_token_contract_address_checksummed
|
203
|
+
),
|
204
|
+
)
|
205
|
+
for token in wrapped_tokens
|
206
|
+
]
|
207
|
+
wrapped_tokens_with_supply = [
|
208
|
+
(token, pool)
|
209
|
+
for token, pool in wrapped_tokens_with_supply
|
210
|
+
if pool is not None
|
211
|
+
]
|
212
|
+
|
213
|
+
for token, pool in wrapped_tokens_with_supply:
|
214
|
+
if pool is None or pool.token1.id is None or pool.token0.id is None:
|
215
|
+
continue
|
216
|
+
if HexBytes(token) == HexBytes(pool.token1.id):
|
217
|
+
outcome_token_pool[
|
218
|
+
OutcomeStr(model.outcomes[wrapped_tokens.index(token)])
|
219
|
+
] = (
|
220
|
+
OutcomeToken(pool.totalValueLockedToken0)
|
221
|
+
if pool.totalValueLockedToken0 is not None
|
222
|
+
else OutcomeToken(0)
|
223
|
+
)
|
224
|
+
probability_map[
|
225
|
+
OutcomeStr(model.outcomes[wrapped_tokens.index(token)])
|
226
|
+
] = Probability(pool.token0Price.value)
|
227
|
+
else:
|
228
|
+
outcome_token_pool[
|
229
|
+
OutcomeStr(model.outcomes[wrapped_tokens.index(token)])
|
230
|
+
] = (
|
231
|
+
OutcomeToken(pool.totalValueLockedToken1)
|
232
|
+
if pool.totalValueLockedToken1 is not None
|
233
|
+
else OutcomeToken(0)
|
234
|
+
)
|
235
|
+
probability_map[
|
236
|
+
OutcomeStr(model.outcomes[wrapped_tokens.index(token)])
|
237
|
+
] = Probability(pool.token1Price.value)
|
238
|
+
|
239
|
+
for outcome in model.outcomes:
|
240
|
+
if outcome not in outcome_token_pool:
|
241
|
+
outcome_token_pool[outcome] = OutcomeToken(0)
|
242
|
+
logger.warning(
|
243
|
+
f"Outcome {outcome} not found in outcome_token_pool for market {self.seer_market.url}."
|
244
|
+
)
|
245
|
+
if outcome not in probability_map:
|
246
|
+
if INVALID_OUTCOME_LOWERCASE_IDENTIFIER not in outcome.lower():
|
247
|
+
raise PriceCalculationError(
|
248
|
+
f"Couldn't get probability for {outcome} for market {self.seer_market.url}."
|
249
|
+
)
|
250
|
+
else:
|
251
|
+
probability_map[outcome] = Probability(0)
|
252
|
+
return probability_map, outcome_token_pool
|
@@ -411,10 +411,14 @@ class SeerAgentMarket(AgentMarket):
|
|
411
411
|
must_have_prices: bool,
|
412
412
|
) -> t.Optional["SeerAgentMarket"]:
|
413
413
|
price_manager = PriceManager(seer_market=model, seer_subgraph=seer_subgraph)
|
414
|
-
|
415
|
-
probability_map = {}
|
414
|
+
wrapped_tokens = [Web3.to_checksum_address(i) for i in model.wrapped_tokens]
|
416
415
|
try:
|
417
|
-
|
416
|
+
(
|
417
|
+
probability_map,
|
418
|
+
outcome_token_pool,
|
419
|
+
) = price_manager.build_initial_probs_from_pool(
|
420
|
+
model=model, wrapped_tokens=wrapped_tokens
|
421
|
+
)
|
418
422
|
except PriceCalculationError as e:
|
419
423
|
logger.info(
|
420
424
|
f"Error when calculating probabilities for market {model.id.hex()} - {e}"
|
@@ -437,9 +441,9 @@ class SeerAgentMarket(AgentMarket):
|
|
437
441
|
condition_id=model.condition_id,
|
438
442
|
url=model.url,
|
439
443
|
close_time=model.close_time,
|
440
|
-
wrapped_tokens=
|
444
|
+
wrapped_tokens=wrapped_tokens,
|
441
445
|
fees=MarketFees.get_zero_fees(),
|
442
|
-
outcome_token_pool=
|
446
|
+
outcome_token_pool=outcome_token_pool,
|
443
447
|
outcomes_supply=model.outcomes_supply,
|
444
448
|
resolution=resolution,
|
445
449
|
volume=None,
|
@@ -633,9 +637,9 @@ class SeerAgentMarket(AgentMarket):
|
|
633
637
|
amount_wei=amount_wei,
|
634
638
|
web3=web3,
|
635
639
|
)
|
636
|
-
swap_pool_tx_hash = tx_receipt["transactionHash"]
|
640
|
+
swap_pool_tx_hash = tx_receipt["transactionHash"]
|
637
641
|
logger.info(f"TxHash is {swap_pool_tx_hash=}.")
|
638
|
-
return swap_pool_tx_hash
|
642
|
+
return swap_pool_tx_hash.hex()
|
639
643
|
|
640
644
|
def place_bet(
|
641
645
|
self,
|
@@ -9,6 +9,7 @@ from eth_typing import URI
|
|
9
9
|
from eth_utils.currency import MAX_WEI, MIN_WEI
|
10
10
|
from pydantic.types import SecretStr
|
11
11
|
from safe_eth.eth import EthereumClient
|
12
|
+
from safe_eth.eth.ethereum_client import TxSpeed
|
12
13
|
from safe_eth.safe.safe import SafeV141
|
13
14
|
from web3 import Web3
|
14
15
|
from web3.constants import HASH_ZERO
|
@@ -269,6 +270,7 @@ def send_function_on_contract_tx_using_safe(
|
|
269
270
|
tx_hash, tx = safe_tx.execute(
|
270
271
|
from_private_key.get_secret_value(),
|
271
272
|
tx_nonce=eoa_nonce,
|
273
|
+
eip1559_speed=TxSpeed.FAST,
|
272
274
|
)
|
273
275
|
receipt_tx = web3.eth.wait_for_transaction_receipt(tx_hash, timeout=timeout)
|
274
276
|
check_tx_receipt(receipt_tx)
|
{prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/LICENSE
RENAMED
File without changes
|
{prediction_market_agent_tooling-0.67.4.dev992 → prediction_market_agent_tooling-0.68.0}/README.md
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|