Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bump PMAT #525

Merged
merged 4 commits into from
Oct 21, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
980 changes: 446 additions & 534 deletions poetry.lock

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,7 @@
from prediction_market_agent_tooling.tools.betting_strategies.kelly_criterion import (
get_kelly_bet_simplified,
)
from prediction_market_agent_tooling.tools.tavily_storage.tavily_models import (
TavilyStorage,
)
from prediction_market_agent_tooling.tools.tavily.tavily_storage import TavilyStorage
from prediction_market_agent_tooling.tools.utils import utcnow

from prediction_market_agent.agents.microchain_agent.utils import (
Expand Down
4 changes: 1 addition & 3 deletions prediction_market_agent/agents/prophet_agent/deploy.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,7 @@
from prediction_market_agent_tooling.loggers import logger
from prediction_market_agent_tooling.markets.agent_market import AgentMarket
from prediction_market_agent_tooling.markets.data_models import ProbabilisticAnswer
from prediction_market_agent_tooling.tools.tavily_storage.tavily_models import (
TavilyStorage,
)
from prediction_market_agent_tooling.tools.tavily.tavily_storage import TavilyStorage
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codebase verification

Invalid Import Path: prediction_market_agent_tooling.tools.tavily.tavily_storage Does Not Exist

The module prediction_market_agent_tooling.tools.tavily.tavily_storage does not exist, and TavilyStorage is not defined within it. Please verify and correct the import path or ensure that the tavily_storage module is created with the appropriate definition of TavilyStorage.

  • File Affected: prediction_market_agent/agents/prophet_agent/deploy.py
🔗 Analysis chain

Verify the updated import path for TavilyStorage

Ensure that the module prediction_market_agent_tooling.tools.tavily.tavily_storage exists and that TavilyStorage is correctly defined within it. This change reflects a module reorganization; verify that all references to TavilyStorage are updated accordingly throughout the codebase.

Run the following script to confirm the existence of TavilyStorage in the new import path:

🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Description: Verify that TavilyStorage is accessible from the new import path.

# Test: Search for the definition of TavilyStorage in the codebase.
rg -A 5 'class TavilyStorage'

# Expected: Should find the class definition of TavilyStorage in the correct module file.

Length of output: 31


Script:

#!/bin/bash
# Description: Search for any definition of TavilyStorage in the codebase.

ast-grep --pattern $'$_ TavilyStorage($_)' --language python

Length of output: 250


Script:

#!/bin/bash
# Description: Verify the existence of the module path prediction_market_agent_tooling.tools.tavily.tavily_storage.

fd 'tavily_storage.py' .

Length of output: 24


Script:

#!/bin/bash
# Description: Corrected search for any definition of TavilyStorage in the codebase.

ast-grep --pattern $'$_ TavilyStorage($_)' --lang python

Length of output: 500


Script:

#!/bin/bash
# Description: Enhanced search for files related to tavily_storage in the codebase.

fd -i 'tavily_storage' .

Length of output: 24


Script:

#!/bin/bash
# Description: Search for any references to TavilyStorage in the codebase.

rg 'TavilyStorage'

Length of output: 1806


Script:

#!/bin/bash
# Description: List all files in the tavily directory to verify the existence of tavily_storage.py.

ls prediction_market_agent_tooling/tools/tavily/

Length of output: 143


Script:

#!/bin/bash
# Description: Search for any definitions of TavilyStorage (class, function, variable) in the codebase.

rg '^\s*(class|def)\s+TavilyStorage\b' --context 2

Length of output: 52


Script:

#!/bin/bash
# Description: Verify the directory structure for the TavilyStorage import path.

ls prediction_market_agent_tooling/tools/tavily/

Length of output: 143

from prediction_prophet.benchmark.agents import (
EmbeddingModel,
OlasAgent,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,7 @@
)
from prediction_market_agent_tooling.tools.langfuse_ import langfuse_context, observe
from prediction_market_agent_tooling.tools.parallelism import par_generator, par_map
from prediction_market_agent_tooling.tools.tavily_storage.tavily_models import (
TavilyStorage,
)
from prediction_market_agent_tooling.tools.tavily.tavily_storage import TavilyStorage
from prediction_market_agent_tooling.tools.utils import (
LLM_SUPER_LOW_TEMPERATURE,
DatetimeUTC,
Expand Down
4 changes: 1 addition & 3 deletions prediction_market_agent/tools/prediction_prophet/research.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
from prediction_market_agent_tooling.loggers import logger
from prediction_market_agent_tooling.tools.tavily_storage.tavily_models import (
TavilyStorage,
)
from prediction_market_agent_tooling.tools.tavily.tavily_storage import TavilyStorage
from prediction_prophet.benchmark.agents import ( # noqa: F401 # Just to make it available for the user of research.
_make_prediction as prophet_make_prediction,
)
Expand Down
4 changes: 2 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ poetry = "^1.7.1"
poetry-plugin-export = "^1.6.0"
functions-framework = "^3.5.0"
cron-validator = "^1.0.8"
prediction-market-agent-tooling = { version = "^0.52.2", extras = ["langchain", "google"] }
prediction-market-agent-tooling = { version = "^0.54.0", extras = ["langchain", "google"] }
pydantic-settings = "^2.1.0"
autoflake = "^2.2.1"
isort = "^5.13.2"
Expand All @@ -52,7 +52,7 @@ tweepy = "^4.14.0"
langchain-pinecone = "^0.1.1"
pinatapy-vourhey = "^0.2.0"
plotly = "^5.22.0"
prediction-prophet = { git = "https://github.com/agentcoinorg/predictionprophet.git", rev = "63fe84e5c00a992d59f44fe240a3d99debfc703c" }
prediction-prophet = { git = "https://github.com/agentcoinorg/predictionprophet.git", rev = "69b3ab619b25eab5890e58d5dc65be3aadf5bb65" }
transformers = "^4.43.3"
openfactverification-kongzii = "^0.2.0"

Expand Down
Loading