forked from Chat_things/NeuroDock
Enhanced tool management in OllamaObject and added Maven publishing configuration.
- Updated `OllamaObject` to support tool registration with sources. - Improved error handling and debug logging in multiple classes. - Added Maven plugin and publication setup in `build.gradle`. - Updated version to `1.3`. Signed-off-by: Zacharias <zacharias@4zellen.se>
This commit is contained in:
@@ -59,6 +59,10 @@ public class GetLyrics extends GeniusEndpointTool {
|
||||
@Override
|
||||
public OllamaToolRespnce function(OllamaFunctionArgument... args) {
|
||||
|
||||
if(!( args[0].value() instanceof Integer)) {
|
||||
throw new OllamaToolErrorException(this.name(), "The song_id must be an integer.");
|
||||
}
|
||||
|
||||
String lyricsStr = geniusToolsInstance.hasCache((int) args[0].value());
|
||||
|
||||
if(lyricsStr != null)
|
||||
|
||||
Reference in New Issue
Block a user