Skip to content
Open
Changes from 2 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
7 changes: 6 additions & 1 deletion src/google/adk/evaluation/evaluation_generator.py
Original file line number Diff line number Diff line change
Expand Up @@ -277,7 +277,7 @@ def convert_events_to_eval_invocations(
invocations = []
for invocation_id, events in events_by_invocation_id.items():
final_response = None
user_content = ""
user_content = None
invocation_timestamp = 0
app_details = None
if (
Expand Down Expand Up @@ -306,6 +306,11 @@ def convert_events_to_eval_invocations(
if p.function_call or p.function_response or p.text:
events_to_add.append(event)
break

if user_content is None:
# We skip because an evaluation case without user input
# is generally not useful for testing/grading.
continue

invocation_events = [
InvocationEvent(author=e.author, content=e.content)
Expand Down