Skip to content

Conversation

@garrett4wade
Copy link
Collaborator

Description

Related Issue

Fixes #(issue)

Type of Change

  • Bug fix (non-breaking change that fixes an issue)
  • New feature (non-breaking change that adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not
    work as expected)
  • Documentation update
  • Code refactoring (no functional changes)
  • Performance improvement
  • Test coverage improvement

Checklist

  • I have read the Contributing Guide
  • I have run formatting tools (pre-commit or manual)
  • I have run relevant unit tests and they pass
  • I have added tests for new functionality
  • I have updated documentation if needed
  • My branch is up to date with main
  • This PR introduces breaking changes (if yes, fill out details below)
  • If this PR changes documentation, I have built and previewed it locally with
    jb build docs
  • No critical issues raised by AI reviewers (/gemini review)

Breaking Change Details (if applicable):

Additional Context


Need help? Check the Contributing Guide or ask in
GitHub Discussions!

@garrett4wade garrett4wade marked this pull request as draft January 6, 2026 01:54
@gemini-code-assist
Copy link
Contributor

Summary of Changes

Hello @garrett4wade, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request significantly enhances the system's capabilities by introducing a robust framework for integrating agent-based workflows, particularly through an OpenAI-compatible proxy. This allows developers to define complex agent behaviors using familiar OpenAI SDKs, which then interact with the underlying inference engine. The changes involve new abstract classes for agents, a dedicated proxy server for managing agent interactions and rewards, and a refactored workflow resolution mechanism that seamlessly integrates these new agent types into the existing rollout and training pipelines. This streamlines the development of sophisticated reinforcement learning agents that leverage large language models.

Highlights

  • Agent Workflow Support: Introduced a new AgentWorkflow abstract base class and WorkflowLike type alias, enabling the definition of custom agent logic that can interact with the inference engine.
  • OpenAI Proxy Integration: Implemented an OpenAIProxyServer and OpenAIProxyWorkflow to provide an OpenAI API-compatible interface for agent workflows, facilitating the use of OpenAI SDKs within the system.
  • Refactored Workflow Resolution: Centralized workflow resolution logic in RemoteInfEngine, allowing it to dynamically wrap AgentWorkflow instances/classes into OpenAIProxyWorkflow and handle RolloutWorkflow instances/classes or string paths.
  • Improved Concurrency for Rollouts: Introduced GroupedRolloutWorkflow to efficiently run multiple episodes concurrently and merge their results, enhancing performance for batch rollouts.
  • CLI and Documentation Updates: Added OpenAIConfig to cli_args.py and updated documentation (cli_reference.md, agentic_rl.md) to reflect the new agent workflow and OpenAI proxy configurations.

🧠 New Feature in Public Preview: You can now enable Memory to help Gemini Code Assist learn from your team's feedback. This makes future code reviews more consistent and personalized to your project's style. Click here to enable Memory in your admin console.

Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces a significant and well-structured feature to support agent-based workflows using an OpenAI-compatible proxy. The core of the change is the AgentWorkflow abstraction, which allows users to integrate agentic logic into the training pipeline seamlessly. The refactoring of the proxy logic and the simplification of the WorkflowExecutor are commendable design choices. However, I've identified a few issues: a misleading comment in a utility function, some dead code in the new proxy workflow module, a broken test due to an incorrect constructor call, and a broken example that relies on a removed API. Addressing these points will further improve the quality of this feature.

*[self._run_episode(task_id, data) for _ in range(self.group_size)]
)
await ProxyServer.finish_task(task_id, base_url=self.base_url)
await OpenAIProxyServer.finish_task(task_id, base_url=self.base_url)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

high

This example attempts to call OpenAIProxyServer.finish_task, but this method does not exist on the OpenAIProxyServer class. This method was present in the old ProxyServer but was removed during the refactoring. The new proxy server uses a capacity-based mechanism and does not have a finish_task endpoint. This example is broken and needs to be updated to work with the new proxy server design.

@garrett4wade garrett4wade force-pushed the fw/proxy branch 2 times, most recently from b90bd72 to 5c267b1 Compare January 7, 2026 09:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants