test(engine): live-confirm the OpenAI leg of Rig-backed completion#207
Merged
Conversation
Feature C (OpenAI leg) of the ailly-evals project. openai_from_env and its ContentBlock/AssistantContent mapping already existed and were unit-tested; this is the first live round trip against OpenAI, mirroring tests/rig_engine.rs's Anthropic shape. Confirms both flagged rough edges hold today: a system+user turn round-trips (system-prompt placement), and gen_ai.system correctly reads "openai" end to end. Does not exercise tool-calling — CompletionRequest has no tools field on any provider yet (tracked separately in TASKS.md). Co-Authored-By: "Ailly <developer@ailly.dev>"
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
tests/rig_engine_openai.rs, a live integration test confirmingopenai_from_envcompletes a real round trip againstgpt-4o-mini, gated onOPENAI_API_KEY(silently skipped when absent).ailly-evalsproject (session2026-07-06-A-ailly-evals). Production code already existed and was unit-tested — this is the first live confirmation, per the parent design's "no code dependency, run whenever credentials land" framing.gen_ai.systemOpenTelemetry attribute correctly reads"openai"end to end (not just for the already-tested Anthropic leg).CompletionRequesthas notoolsfield on any provider yet, a pre-existing gap already tracked indocs/developer/TASKS.md("live tool-definition wiring is completely missing").Test plan
cargo test --test rig_engine_openai(live, passes withOPENAI_API_KEYset)cargo test(full suite, green)cargo test --no-default-featurescargo clippy --all-targets --all-features -- -D warningscargo fmt --check(only pre-existing, unrelated drift incalibration.rsremains, confirmed present onmain_twobefore this change)Co-Authored-By: "Ailly developer@ailly.dev"