[WIP] feat: add ProposalDriver for CRD-based agent execution#232
Draft
rioloc wants to merge 2 commits into
Draft
[WIP] feat: add ProposalDriver for CRD-based agent execution#232rioloc wants to merge 2 commits into
rioloc wants to merge 2 commits into
Conversation
Contributor
|
Important Review skippedDraft detected. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
3af4e56 to
033af0d
Compare
| import logging | ||
| import os | ||
| import shutil | ||
| import subprocess |
Comment on lines
+225
to
+226
| return subprocess.run( | ||
| [self._cli, *args], |
09093ef to
08aa6d8
Compare
08aa6d8 to
b1271b6
Compare
Introduce SubprocessDriver — a new AgentDriver that manages OpenShift Proposal CR lifecycle via oc/kubectl CLI. The driver builds and applies Proposal CRs, polls status conditions until terminal state, handles auto-approval via ProposalApproval resources, and cleans up on completion. Key design decisions: - Works directly with CRD conditions (the stable API contract) instead of replicating the operator's internal DerivePhase() logic - TerminalOutcome enum for driver-level terminal states - TurnData extended with proposal_spec, proposal_status, description, and expected_proposal_status fields (backward-compatible, all Optional) Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
b1271b6 to
af6e041
Compare
- Wire ProposalDriver into the evaluation pipeline: add "subprocess" to SUPPORTED_AGENT_TYPES, move SubprocessAgentConfig to core/models, register in AgentDriverRegistry via new registry module, and update all exports. Fixes ProposalDriver.__init__ to accept enabled kwarg. - Extend unit tests - Add agentic integration tests Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
af6e041 to
1781c8b
Compare
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
Add
SubprocessDriver— a newAgentDriverthat manages OpenShift Proposal CR lifecycle viaoc/kubectlCLI, enabling evaluation of agentic workloads running on the cluster.The driver builds and applies Proposal CRs, polls
.status.conditionsuntil a terminal state is reached, handles auto-approval viaProposalApprovalresources, and cleans up on completion. It works directly with CRD conditions (the stable API contract) rather than replicating the operator's internal phase derivation logic.Design document: https://gist.github.com/rioloc/c4b29b534f02e46d0e023599c90ed0f0
Milestones
ProposalDriverclass withexecute_turn, polling loop, auto-approve, cleanupTerminalOutcomeenum for driver-level terminal statesTurnDataextended withproposal_spec,proposal_status,description,expected_proposal_status_is_terminal,_should_approve)ProposalDriverinAgentDriverRegistryProposalAgentConfigtoagents.py"proposal"toSUPPORTED_AGENT_TYPES__init__.pyTest plan
uv run pytest tests/unit/pipeline/evaluation/test_proposal_driver.py -vmake testmake pre-commit🤖 Generated with Claude Code