879 Commits

Author SHA1 Message Date
dependabot[bot]
3ee93f9534
Bump org.apache.maven.plugins:maven-failsafe-plugin
Bumps [org.apache.maven.plugins:maven-failsafe-plugin](https://github.com/apache/maven-surefire) from 3.0.0-M5 to 3.5.3.
- [Release notes](https://github.com/apache/maven-surefire/releases)
- [Commits](https://github.com/apache/maven-surefire/compare/surefire-3.0.0-M5...surefire-3.5.3)

---
updated-dependencies:
- dependency-name: org.apache.maven.plugins:maven-failsafe-plugin
  dependency-version: 3.5.3
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-09-10 15:34:31 +00:00
Amith Koujalgi
74fbafeb3f
Merge pull request #157 from ollama4j/tests
Tests
2025-09-10 21:03:38 +05:30
amithkoujalgi
56c3f90559
Comment out pre-commit run step in GitHub workflow to prevent execution during CI 2025-09-10 20:00:54 +05:30
amithkoujalgi
27a2d68e9b
Enhance GitHub workflows and templates
- Updated dependabot configuration to include Maven, GitHub Actions, and npm with weekly update schedules and limits on open pull requests.
- Added a pull request template to standardize contributions and ensure necessary information is provided.
- Introduced issue templates for bug reports and feature requests to streamline issue tracking and enhance user experience.
- Created workflows for CodeQL analysis, pre-commit checks, and stale issue management to improve code quality and maintainability.
2025-09-10 19:10:13 +05:30
amithkoujalgi
085fe3a9b0
Add CODEOWNERS file to define repository ownership 2025-09-10 18:52:46 +05:30
amithkoujalgi
bb1adacc7f
Add CONTRIBUTING.md and SECURITY.md files
- Introduced a CONTRIBUTING.md file to guide contributors on setup, coding guidelines, and pull request processes.
- Added a SECURITY.md file outlining the security policy, reporting vulnerabilities, and responsible disclosure procedures.
2025-09-10 18:49:45 +05:30
amithkoujalgi
fdc2e39646
Refactor logging in OllamaAPI and ConsoleOutputStreamHandler
- Changed logger variable names from 'logger' to 'LOG' for consistency.
- Updated logging statements in OllamaAPI to use the new 'LOG' variable.
- Modified ConsoleOutputStreamHandler to log messages using 'LOG' instead of printing directly to the console.
2025-09-10 18:08:01 +05:30
amithkoujalgi
773cb4af78
Refactor verbosity handling in OllamaAPI
- Removed the verbose logging feature from the OllamaAPI class and related classes.
- Updated logging statements to use debug level instead of info for model requests and responses.
- Cleaned up related test cases to reflect the removal of verbosity settings.
2025-09-10 18:02:28 +05:30
amithkoujalgi
9036d9e7c6
Add unit tests for annotations, serialization, and tool functions
- Introduced TestAnnotations.java to validate OllamaToolService and ToolProperty annotations.
- Added TestBooleanToJsonFormatFlagSerializer.java to test serialization of Boolean values.
- Created TestFileToBase64Serializer.java for testing byte array serialization to Base64.
- Implemented TestOllamaChatMessage.java to ensure correct JSON representation of chat messages.
- Developed TestOllamaChatMessageRole.java to verify role registration and custom role creation.
- Added TestOllamaChatRequestBuilder.java to test message handling and request building.
- Created TestOllamaRequestBody.java to validate request body serialization.
- Implemented TestOllamaToolsResult.java to ensure correct transformation of tool results.
- Added TestOptionsAndUtils.java to test options builder and utility functions.
- Created TestReflectionalToolFunction.java to validate method invocation and argument handling.
- Implemented TestToolRegistry.java to ensure tool registration and retrieval functionality.
- Developed TestToolsPromptBuilder.java to verify prompt builder includes tools and prompts correctly.
- Added serialization tests in TestChatRequestSerialization.java and TestEmbedRequestSerialization.java.
2025-09-10 17:31:41 +05:30
amithkoujalgi
fddd753a48
Add unit tests for authentication, options, tool registry, and prompt builder
- Created TestAuth.java to validate BasicAuth and BearerAuth header generation.
- Added TestOptionsAndUtils.java to test OptionsBuilder and utility functions.
- Implemented TestToolRegistry.java to ensure tool registration and retrieval functionality.
- Developed TestToolsPromptBuilder.java to verify prompt builder includes tools and prompts correctly.
2025-09-10 17:06:47 +05:30
amithkoujalgi
b42cee36ae
Merge remote-tracking branch 'origin/main' 2025-09-10 16:58:09 +05:30
Amith Koujalgi
4694d31e2c
Update README.md 2025-09-10 09:37:19 +05:30
Amith Koujalgi
4abecd1d76
Update README.md 2025-09-10 09:35:24 +05:30
Amith Koujalgi
5ae999078c
Merge pull request #156 from ollama4j/amithkoujalgi-patch-2
Amithkoujalgi patch 2
2025-09-10 09:29:04 +05:30
amithkoujalgi
538db8f484
Update README.md 2025-09-10 09:28:37 +05:30
Amith Koujalgi
ca79831c1e
Update README.md 2025-09-10 08:43:06 +05:30
Amith Koujalgi
255173c6ac
Create CITATION.cff 2025-09-10 08:41:07 +05:30
Amith Koujalgi
8d197f963d
Merge pull request #155 from ollama4j/dependabot/npm_and_yarn/docs/npm_and_yarn-6ea9762674
All checks were successful
Mark stale issues / stale (push) Successful in 32s
Bump brace-expansion from 1.1.11 to 1.1.12 in /docs in the npm_and_yarn group across 1 directory
2025-09-05 20:42:27 +05:30
Amith Koujalgi
3c5107f113
Merge pull request #154 from ollama4j/amithkoujalgi-patch-1
Create dependabot.yml
2025-09-05 20:41:52 +05:30
dependabot[bot]
80ee58ba1e
Bump brace-expansion
Bumps the npm_and_yarn group with 1 update in the /docs directory: [brace-expansion](https://github.com/juliangruber/brace-expansion).


Updates `brace-expansion` from 1.1.11 to 1.1.12
- [Release notes](https://github.com/juliangruber/brace-expansion/releases)
- [Commits](https://github.com/juliangruber/brace-expansion/compare/1.1.11...v1.1.12)

---
updated-dependencies:
- dependency-name: brace-expansion
  dependency-version: 1.1.12
  dependency-type: indirect
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-09-05 10:40:50 +00:00
Amith Koujalgi
d219168451
Create dependabot.yml 2025-09-05 16:09:59 +05:30
Amith Koujalgi
977b85f8ea
Merge pull request #153 from sebastianbeattie/patch-1
All checks were successful
Mark stale issues / stale (push) Successful in 30s
Update maven version in README.md
2025-09-04 23:12:04 +05:30
Seb Beattie
9b31fa5390
Update maven version in README.md 2025-09-04 10:55:11 +01:00
Amith Koujalgi
0e0c83a065
Merge pull request #151 from ollama4j/docs-updates
All checks were successful
Mark stale issues / stale (push) Successful in 32s
2025-08-31 23:47:30 +05:30
amithkoujalgi
3ddfd4fb4e
Update README.md 2025-08-31 22:23:09 +05:30
amithkoujalgi
a093be5581
Update OllamaAPI.java 2025-08-31 22:02:43 +05:30
Amith Koujalgi
cfd784b919
Merge pull request #150 from ollama4j/docs-updates
All checks were successful
Mark stale issues / stale (push) Successful in 40s
Update docs and dependencies
2025-08-31 20:00:08 +05:30
amithkoujalgi
a3ebe6c992
Update docs and dependencies
Improved descriptions in README and blog posts, removed outdated info from pull-model API docs, and updated several npm dependencies in package.json and package-lock.json for better compatibility and security.
2025-08-31 19:59:29 +05:30
Amith Koujalgi
4eefb81a0b
Merge pull request #148 from ollama4j/doc-updates
Add docs for thinking APIs and update examples
2025-08-31 19:37:15 +05:30
amithkoujalgi
f914707536
Add docs for thinking APIs and update examples
Added new documentation for 'chat-with-thinking' and 'generate-thinking' APIs, including usage examples and streamed output. Updated existing API docs to improve example clarity, response formatting, and added more interactive output using TypewriterTextarea. Removed deprecated 'list-library-models' doc and made minor README updates.
2025-08-31 19:36:43 +05:30
Amith Koujalgi
931d5dd520
Merge pull request #145 from ollama4j/thinking-support
Thinking support
1.1.0
2025-08-31 17:44:58 +05:30
amithkoujalgi
b216d1b647
Refactor imports and add fields to OllamaStructuredResult
Reorders and deduplicates import statements across multiple files for consistency and clarity. Adds additional fields to OllamaStructuredResult and ensures OllamaResult is populated with these fields. Updates tests and minor code style improvements throughout the codebase.
2025-08-31 16:46:32 +05:30
amithkoujalgi
4de3d98b79
Update generate.md 2025-08-31 16:00:07 +05:30
amithkoujalgi
6fa5c323b8
Refactor stream handler and update test model usage
Simplified ConsoleOutputStreamHandler to print messages directly without substring logic. Updated WithAuth integration test to use the THINKING_MODEL ('gpt-oss:20b') instead of GENERAL_PURPOSE_MODEL ('gemma3:270m') for model pulling and generation.
2025-08-31 15:56:40 +05:30
amithkoujalgi
c754bd11da
Refactor OllamaAPI for improved async handling and response streaming
Updated OllamaAPI to support separate thinking and response stream handlers, enhancing the asynchronous generation of responses. Adjusted related models and observers to accommodate new streaming logic. Improved the handling of response data in OllamaResult and OllamaGenerateResponseModel, adding new properties for better tracking of response metrics. Refined integration tests to reflect changes in method signatures and ensure proper logging of streamed responses.
2025-08-31 14:02:42 +05:30
amithkoujalgi
5f5fa8ecae
Deprecate findModelTagFromLibrary and simplify WeatherTool
Marked findModelTagFromLibrary as deprecated in OllamaAPI due to reliance on unstable HTML structure. Simplified WeatherTool by removing external API calls and returning a static weather response for demonstration purposes.
2025-08-31 01:33:57 +05:30
amithkoujalgi
6ae6f4f25b
Update run-tests.yml 2025-08-30 21:31:54 +05:30
amithkoujalgi
6b69284497
Update workflow job names and refine integration tests
Added descriptive names to jobs in the GitHub Actions workflow for better clarity. In integration tests, replaced GENERAL_PURPOSE_MODEL with TOOLS_MODEL in relevant tests and adjusted logging within lambda expressions for improved output handling.
2025-08-30 21:30:16 +05:30
amithkoujalgi
52d7dbd7ce
Update build-on-pull-request.yml 2025-08-30 21:10:54 +05:30
amithkoujalgi
2070753c5e
Update run-tests.yml 2025-08-30 21:05:30 +05:30
Amith Koujalgi
c1f7fb78d9
Merge branch 'main' into thinking-support 2025-08-30 21:01:50 +05:30
amithkoujalgi
b71cf87ec2
Update build-on-pull-request.yml 2025-08-30 21:00:37 +05:30
amithkoujalgi
0965c3046e
Update build-on-pull-request.yml 2025-08-30 20:57:17 +05:30
amithkoujalgi
8e50bc8d75
Update OllamaAPIIntegrationTest.java 2025-08-30 20:54:18 +05:30
amithkoujalgi
be5b77c4ac
Refactor tool tests and improve tool argument handling
Refactored integration tests to use a reusable employeeFinderTool method and improved assertions for tool call results. Updated tool argument formatting in OllamaAPI for clearer output. Modified AnnotatedTool to use 'numberOfHearts' instead of 'amountOfHearts' and simplified the sayHello method signature and output. Removed redundant and duplicate test code for tool streaming.
2025-08-30 20:53:14 +05:30
amithkoujalgi
6078db6157
Update GitHub Actions workflows for PRs and tests
Enables all pull request event types in build-on-pull-request.yml and cleans up formatting. Removes redundant step for copying workflow file in run-tests.yml to streamline the workflow.
2025-08-30 20:04:42 +05:30
amithkoujalgi
97f457575d
Remove sample prompt utilities and update integration tests
Deleted SamplePrompts.java and sample-db-prompt-template.txt as they are no longer needed. Updated OllamaAPIIntegrationTest to use a new TOOLS_MODEL constant, refactored tool registration and prompt descriptions for employee details, and improved test assertions for tool-based chat interactions.
2025-08-30 20:01:35 +05:30
amithkoujalgi
4df59d8862
Refactor test steps to use run-tests workflow
Replaces separate Maven unit and integration test steps with a call to the reusable run-tests.yml workflow, passing the current branch as input. This simplifies the workflow and centralizes test execution logic.
2025-08-30 18:13:58 +05:30
amithkoujalgi
621004e6d8
Fix logging for model pull retry 2025-08-30 18:10:33 +05:30
Amith Koujalgi
74b2ab13e7
Merge pull request #146 from ollama4j/amithkoujalgi-patch-1
All checks were successful
Mark stale issues / stale (push) Successful in 34s
Update run-tests.yml
2025-08-30 18:09:47 +05:30