Skip to content

fix(evals): include content-part text in ResponsesSampler transcripts; chore: ignore .venv #93

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

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
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
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,5 @@ tmp*
__pycache__
*.egg*
node_modules/
*.log
*.log
.venv/
10 changes: 8 additions & 2 deletions gpt_oss/evals/responses_sampler.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,8 +66,14 @@ def __call__(self, message_list: MessageList) -> SamplerResponse:
message_list.append(self._pack_message(getattr(output, "role", "assistant"), output.text))
elif hasattr(output, "content"):
for c in output.content:
# c.text handled below
pass
# Append any text content parts so message_list reflects the response
if hasattr(c, "text") and getattr(c, "text"):
message_list.append(
self._pack_message(
getattr(output, "role", "assistant"),
c.text,
)
)

return SamplerResponse(
response_text=response.output_text,
Expand Down