Closed ullenboom closed 1 day ago
It would be nice to use Double
instead of Float
in all the ModelOptions
implementations. It would make the API more convenient to work with and the code more readable.
I agree, thanks for raising the issue. I will aim to fix this for the M2 release that is coming up shortly.
@markpollack should this be moved to next milestone or release candidate?
I'm available to submit a PR on this. I had already done some preliminary analysis when working on the observability features. I should have the PR ready by the end of this week.
The PR is ready for review: https://github.com/spring-projects/spring-ai/pull/1325
A floating-point number with limited precision is commonly used in AI. However, using
float
orFloat
as a data type in the API might be impractical, and it could be worth reevaluating this decision.For instance, your own example in the reference documentation (https://docs.spring.io/spring-ai/reference/api/clients/ollama-chat.html) results in a compiler error, guess why :)