Skip to content

AutoGPT is the vision of accessible AI for everyone, to use and to build on. Our mission is to provide the tools, so that you can focus on what matters.

Remove graphql logs (#264)

merwanehamadiaa37109707cd
diff --git a/agbenchmark/agent_interface.py b/agbenchmark/agent_interface.py
index 402120e8f3..6b2d5bbe74 100644
--- a/agbenchmark/agent_interface.py
+++ b/agbenchmark/agent_interface.py
@@ -14,6 +14,10 @@ load_dotenv()
mock_test_str = os.getenv("MOCK_TEST")
MOCK_FLAG = mock_test_str.lower() == "true" if mock_test_str else False
+helicone_graphql_logs = os.getenv("HELICONE_GRAPHQL_LOGS")
+HELICONE_GRAPHQL_LOGS = (
+ helicone_graphql_logs.lower() == "true" if helicone_graphql_logs else False
+)
def run_agent(
diff --git a/agbenchmark/utils/get_data_from_helicone.py b/agbenchmark/utils/get_data_from_helicone.py
index 0de17cd3f5..51a24065dd 100644
--- a/agbenchmark/utils/get_data_from_helicone.py
+++ b/agbenchmark/utils/get_data_from_helicone.py
@@ -4,6 +4,7 @@ from typing import Optional
import requests
+from agbenchmark.agent_interface import HELICONE_GRAPHQL_LOGS
from agbenchmark.start_benchmark import BENCHMARK_START_TIME
@@ -22,7 +23,6 @@ query ExampleQuery($properties: [PropertyFilter!]){
}
}
"""
- print(query)
variables = {
"properties": [
@@ -37,8 +37,9 @@ query ExampleQuery($properties: [PropertyFilter!]){
{"value": {"equals": challenge}, "name": "challenge"},
]
}
-
- print(json.dumps(variables, indent=4))
+ if HELICONE_GRAPHQL_LOGS:
+ print(query)
+ print(json.dumps(variables, indent=4))
operation_name = "ExampleQuery"