Commit Graph

11 Commits

Author SHA1 Message Date
Zacharias 931c274cd3 refactor: update CoreMemory to v2 and rename OllamaToolResponse
build / build (push) Has been cancelled
- Refactored `CoreMemory` to support versioning (v2) and dual-memory types: `MAPPED_MEMORY` (key-value) and `ARRAYED_MEMORY` (sequential).
- Added automatic migration logic for v1 memory files to v2.
- Introduced new memory tools: `AddArrayMemory`, `GetArrayMemory`, and `GetArrayedMemories`.
- Renamed `OllamaToolRespnce` to `OllamaToolResponse` and added `empty()` factory methods for better error handling.
- Updated multiple function tools (e.g., `GetMemoryFunction`, `GetMemoriesFunction`, `APITool`, `GetWikiPageText`) to use the new `OllamaToolResponse` and `Optional`-based memory retrieval.
- Improved null safety by adding `@NotNull` annotations to tool implementations.
2026-05-27 21:10:15 +02:00
Zacharias f6610777ae refactor: redesign plugin system and enhance message handling
build / build (push) Has been cancelled
- Move plugin and tool-related classes to a dedicated `Plugin-API` module.
- Introduce a new plugin lifecycle (`onInit`, `onEnable`, `onDisable`) and a more robust `Tool` API.
- Refactor `Core` to use `PrintAdvanceMessageHandler` for improved handling of assistant messages, tool responses, and errors.
- Rename `PluginLoader` to `Loader` and migrate it to `me.zacharias.chat.plugin.loader`.
- Update build configurations and Java toolchains across modules.
- Clean up obsolete plugin annotations and interfaces in the `Core` module.
2026-05-26 16:28:02 +02:00
Zacharias a33a37ec0a Updated OllamaFunctionTool.toString to reflect what the Ollama API actually wants
build / build (push) Has been cancelled
Added @NotNull annotation to OllamaFunctionTool.name and OllamaFunctionTool.parameters since the documentation reports as these being required

Made sure that OllamaFunctionTool.description is actually optional as the Ollama API docs define
2026-05-05 22:27:36 +02:00
Zacharias b1aa35e1b1 Updated depndencies for
build / build (push) Has been cancelled
- GradleAPI
- Launcher
- MALAPITool

Started finishing up the File handeling module in Core
- Added ReadFileTool.java which allowes to read files from this contained "file system"

modulized dependency for the API

Updated for Launcher.java to use class and method refrence to entry point to remove hard dependency

Added a @SafeVarargs to OllamaObject.java
made OllamaObject.OllamaObjectBuilder#addFileTools not throw IllegalArgumentException and instead add the tooling and return the builder

Added overloaded constructor OllamaToolErrorException#OllamaToolErrorException(String, Exception) to allow for forwarding of exceptions, although this is not recomended

PythonRunner
- Fixed bugs with it under Linux host(this MUST be refractord to support Windows and Mac hosts)
- Added a overwrite for default python print method to send prints over the external_tools socket to be put into output log for the runner
- Cleaned up some stuff
- Updated to properly refer to files
- Fixed cmd.sh generation
- Removed old "-c" addition to the command
- Removed old code related to how logs pulled from containers standerd output's
- Updated the generation of external_tools.py to respect pythons requirment of optinal arguments being after all required

Updated Tool#addTool to respect the standerd of spring boot's return model
2026-05-04 19:50:49 +02:00
Zacharias 943c8470a5 Honestly speaking... No clue what the updates are :/
build / build (push) Has been cancelled
2026-01-17 14:30:26 +01:00
Zacharias 4262dd68c6 Enhanced tool management in OllamaObject and added Maven publishing configuration.
build / build (push) Has been cancelled
- 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>
2025-08-18 20:01:42 +02:00
Zacharias 2cf0428d2a Added legal disclaimers about scraping.. mostly to make sure i dont get into too mutch trouble about things
build / build (push) Has been cancelled
2025-08-05 01:33:48 +02:00
Zacharias bbf3c645b0 Added README.md to GeniusAPI
build / build (push) Has been cancelled
2025-08-05 00:51:35 +02:00
Zacharias 5886d164b4 Core.java
- Added a safe handle for if Core#logWriter is not initialized to prevent craching

GetLyrics.java
- Slowly modifying the http headers to avoid package due to catching this as a Scrapper
- Added so we skip extra calls if the song is cached
2025-08-05 00:38:58 +02:00
Zacharias 57fc7f2533 Quick and dirty commit, due to heaste of this needing 2025-06-08 22:01:17 +02:00
Zacharias 840ad468e3 Added Genius API wrapper
for fetching song lyrics from Genius Database

# Disclaimer. This commit contains parts that are for educational purposes only!

FindSong:
- Uses Genius API to find the song queried

GetLyrics:
# Educational purposes only
- Scrapes Genius lyrics page for the Lyrics
2025-06-08 21:54:56 +02:00