TheR1D / shell_gpt

A command-line productivity tool powered by AI large language models like GPT-4, will help you accomplish your tasks faster and more efficiently.
MIT License
9.41k stars 741 forks source link

Adopt to new function calling format - allow function calling on Groq & other non-openai models #569

Closed tijszwinkels closed 1 month ago

tijszwinkels commented 4 months ago

Update function calling to use the new 'tool use' format. This format is compatible with litellm proxies, groq, etc.

tijszwinkels commented 3 months ago

@TheR1D Thank you for testing this well!

I have addressed your comments:

Tested by prompting it to perform multiple action at once, as well as with an empty functions directory.

HejiaZ2023 commented 2 months ago

Hi @tijszwinkels @TheR1D ,

I’ve noticed that this PR is almost complete, but there are some lint test failures. I’d love to help out and get this merged as I'm also interested in this feature.

I’ve made the necessary changes to fix the lint issues and pushed them to a branch on my fork. You can review my changes here: https://github.com/HejiaZ2023/shell_gpt/pull/1

If you’re okay with it, I can either create a new PR with these changes or, if the PR owner add me as a collaborator, I guess I can push the changes directly to this branch.

Please let me know how you’d like to proceed.

Thanks again for your work on this feature!

tijszwinkels commented 2 months ago

@HejiaZ2023 Thanks! - I merged and pushed your changes onto this branch. I've added you as a colaborator as well for now.

tijszwinkels commented 2 months ago

@TheR1D Any more changes you'd like to see? Anything we can do to reduce your workload?

TheR1D commented 1 month ago

Hi @tijszwinkels, @HejiaZ2023, sorry for the late reply. The PR has been merged. Thank you for your contribution!