Skip to content

[Feature Request]: OAI_CONFIG_LIST should accept not only .json, but also .yaml #2559

Closed
@Mai0313

Description

@Mai0313

Is your feature request related to a problem? Please describe.

I am currently working on a project where I aim to make multi-agent experiments more structured. To achieve this, I am integrating the entire workflow and configuration using Hydra by FacebookResearch.

For those familiar with PyTorch Lightning, there is a repository called lightning-hydra-template, which is designed to enhance the experience for fine-tuning and training models.

With this in mind, I believe it would be beneficial to have a function that can load configurations from YAML files. Given that YAML and JSON share similar structures, I anticipate that incorporating this functionality should not pose significant challenges.

Describe the solution you'd like

I have devised a solution that I've successfully tested in my project. In the autogen/oai/openai_utils.py file, I propose replacing json.loads with yaml.safe_load to facilitate the loading of YAML files.

I plan to implement this change and will submit a pull request to address this enhancement.

We can split this or make a new function is ok to me.

Additional context

No response

### add yaml support

Metadata

Metadata

Assignees

No one assigned

    Labels

    0.2Issues which are related to the pre 0.4 codebaseneeds-triage

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions