Skip to content
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
8 changes: 5 additions & 3 deletions MaxKernel/auto_agent/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,12 @@
import os

from google.adk.apps.app import EventsCompactionConfig
from google.adk.apps.llm_event_summarizer import LlmEventSummarizer
from google.adk.planners import BuiltInPlanner
from google.genai import types
from auto_agent.custom_types import TimeoutGemini

from auto_agent.constants import MODEL_NAME, TEMPERATURE, TOP_K, TOP_P
from google.adk.apps.llm_event_summarizer import LlmEventSummarizer
from auto_agent.custom_types import TimeoutGemini

# Environment variables
WORKDIR = os.environ.get("WORKDIR", os.path.dirname(os.path.abspath(__file__)))
Expand All @@ -19,14 +20,15 @@

compaction_model = TimeoutGemini(model=MODEL_NAME)


# Set events compaction policy to avoid memory overflow
def get_compaction_config():
return EventsCompactionConfig(
token_threshold=300000,
event_retention_size=5,
compaction_interval=0,
overlap_size=0,
summarizer=LlmEventSummarizer(llm=compaction_model)
summarizer=LlmEventSummarizer(llm=compaction_model),
)


Expand Down
10 changes: 6 additions & 4 deletions MaxKernel/evaluation/jax_kernel_evaluator.py
Original file line number Diff line number Diff line change
Expand Up @@ -428,12 +428,14 @@ def _build_task_json(
rtol: Evaluator level fallback for rtol.
"""
effective_atol = (
atol if atol is not None else
(task.atol if task.atol is not None else DEFAULT_ATOL)
atol
if atol is not None
else (task.atol if task.atol is not None else DEFAULT_ATOL)
)
effective_rtol = (
rtol if rtol is not None else
(task.rtol if task.rtol is not None else DEFAULT_RTOL)
rtol
if rtol is not None
else (task.rtol if task.rtol is not None else DEFAULT_RTOL)
)

task_info = {
Expand Down