Closed tisfeng closed 6 months ago
There are no feature changes in this PR, just a rewrite of the OpenAI service using Swift and removing the old objc code.
Other changes:
There seems to be something wrong with CI, can anyone help take a look?
Looks like a package resolution issue because of Package.resolved file is corrupted or malformed
, I cannot build it in local machine either.
@phlpsong I didn't change the configuration of custom OpenAI, I don't know why its interface changed to be the same as OpenAI.
I debug found that it will call OpenAIService + ConfigurableService
instead of CustomOpenAIService + ConfigurableService
, can you help me to look at it?
I think the root cause is the change of inheritance of OpenAIService and CustomOpenAIService, currently, CustomOpenAIService inherits from OpenAIService and they both implement ConfigurableService
, this may caused the method dispatch problem.
Maybe the simple approach is to create a base class like before, and make the subclass conform to ConfigurableService
.
@phlpsong ok, thank you for your answer, I will check it later.
I added a BaseOpenAIService
, it looks fixed now.
There seems to be something wrong with CI, can anyone help take a look?
I just found out that Xcode 15.3 could fix this. Currently, CI uses 15.1.
The system images of CI and Xcode versions are usually a bit outdated. As long as they run without issues, we can temporarily keep them until adapting to the new major updates.
Sure, let's keep the current package configuration utils stable.
Please review this PR 🥹
All fixed, please continue to review.
close https://github.com/tisfeng/Easydict/issues/291