camel-ai / camel

🐫 CAMEL: Finding the Scaling Law of Agents. A multi-agent framework. https://www.camel-ai.org
https://docs.camel-ai.org/
Apache License 2.0
5.47k stars 675 forks source link

[Feature Request] Update naming for OpenAIFunction #858

Closed Wendong-Fan closed 6 days ago

Wendong-Fan commented 1 month ago

Required prerequisites

Motivation

The class "OpenAIFunction" doesn't actually require OpenAI, it's a legacy name from earlier development.we can renaming it to something more fitting, like "CamelTool."

Solution

No response

Alternatives

No response

Additional context

No response

tom-doerr commented 1 month ago

I would like to give this a try, could you assign it to me?

Wendong-Fan commented 1 month ago

Hey @tom-doerr , thank you for your willingness to contribute! We're planning to rename OpenAIFunction to FunctionTool. However, if you have any alternative name suggestions, we’re open to discussing them. I've assigned this issue to you.

tom-doerr commented 1 month ago

I renamed OpenAIFunction to FunctionTool. However not all tests pass for me, even before I renamed it, see discussion: https://github.com/orgs/camel-ai/discussions/910

Wendong-Fan commented 1 month ago

I renamed OpenAIFunction to FunctionTool. However not all tests pass for me, even before I renamed it, see discussion: https://github.com/orgs/camel-ai/discussions/910

Thanks @tom-doerr! You can create the PR directly, if the failed test is not related to your change but just due to lack for API Keys then we can ignore those failed test

tom-doerr commented 1 month ago

Just added a PR that is almost just renaming OpenAIFunction. There are however still functions that include openai, e.g.

    def validate_openai_tool_schema(

I also worked on renaming those and renaming the files that are referencing OpenAI functions, however that breaks backwards compatibility. Should I rename them and add the old function/filenames that throw a deprecation warning when used?

Wendong-Fan commented 1 month ago

thanks @tom-doerr ! For this method it's indeed related to OpenAI since it's validating whether the schema follow's OpenAI's required format, so I'd suggest don't rename this method