buhe/langchain-swift

Is there a plan to replace OpenAIKit?

Lavanille777 opened this issue · 15 comments

It hasn't had any significant updates in a long time and doesn't even support the updates from version 1106.

buhe commented

Please, do you have any recommendations?

Please, do you have any recommendations?

I'm currently using the repository https://github.com/MacPaw/OpenAI, not sure if there might be a better alternative. Compared to the OpenAIKit, they offer support for function calling and the recent 1106 series of models. Even though the newest content format isn't yet supported, it's evident that there are already some people making efforts to adapt it.

buhe commented

I also used it at first, but I couldn't find how to set up proxy url. This is very important for blocked areas, such as China, because end users cannot be required to use VPN.

I also used it at first, but I couldn't find how to set up proxy url. This is very important for blocked areas, such as China, because end users cannot be required to use VPN.

Actually, you can set up a proxy server, just need to override the buildURL(path: String) method in OpenAI.swift. Although it requires modifying the source code, it's not complicated.

buhe commented

My previous project was to modify his source code. If you are willing, please submit a PR to it, thank you.

My previous project was to modify his source code. If you are willing, please submit a PR to it, thank you.

sure, I'll try it later.

My previous project was to modify his source code. If you are willing, please submit a PR to it, thank you.

Can you specify which repo it is?

Any progress on this? Also would like to use the new preview model

buhe commented

@SteveCutler @Lavanille777 What new models are needed?

buhe commented

I fork that repo and add "gpt-4-1106-preview", "gpt-3.5-turbo-1106", wait original repo merged.
I use my fork version on main branch first.

I fork that repo and add "gpt-4-1106-preview", "gpt-3.5-turbo-1106", wait original repo merged. I use my fork version on main branch first.

Thanks thats very helpful!

buhe commented

Please use 0.47.0

Got it working, thank you very much

buhe commented

Feel free to open again.