├── .eslintignore ├── .eslintrc.cjs ├── .github └── workflows │ ├── publish.yaml │ └── test.yaml ├── .gitignore ├── .npmignore ├── .prettierrc.json ├── LICENSE ├── README.md ├── examples ├── README.md ├── abort │ ├── abort-all-requests.ts │ └── abort-single-request.ts ├── fill-in-middle │ └── fill.ts ├── logprobs │ └── logprobs-chat.ts ├── multimodal │ ├── cat.jpg │ └── multimodal.ts ├── pull-progress │ └── pull.ts ├── structured_outputs │ ├── structured-outputs-image.ts │ └── structured-outputs.ts ├── thinking │ ├── thinking-enabled.ts │ ├── thinking-levels.ts │ └── thinking-streaming.ts ├── tools │ ├── calculator.ts │ ├── flight-tracker.ts │ └── multi-tool.ts └── websearch │ ├── gpt-oss-browser-tools-helpers.ts │ ├── gpt-oss-browser-tools.ts │ └── websearch-tools.ts ├── package.json ├── src ├── browser.ts ├── constant.ts ├── index.ts ├── interfaces.ts ├── utils.ts └── version.ts ├── test ├── browser.test.ts ├── index.test.ts └── utils.test.ts └── tsconfig.json /.eslintignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | dist 3 | -------------------------------------------------------------------------------- /.eslintrc.cjs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/.eslintrc.cjs -------------------------------------------------------------------------------- /.github/workflows/publish.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/.github/workflows/publish.yaml -------------------------------------------------------------------------------- /.github/workflows/test.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/.github/workflows/test.yaml -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/.gitignore -------------------------------------------------------------------------------- /.npmignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/.npmignore -------------------------------------------------------------------------------- /.prettierrc.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/.prettierrc.json -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/LICENSE -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/README.md -------------------------------------------------------------------------------- /examples/README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/examples/README.md -------------------------------------------------------------------------------- /examples/abort/abort-all-requests.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/examples/abort/abort-all-requests.ts -------------------------------------------------------------------------------- /examples/abort/abort-single-request.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/examples/abort/abort-single-request.ts -------------------------------------------------------------------------------- /examples/fill-in-middle/fill.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/examples/fill-in-middle/fill.ts -------------------------------------------------------------------------------- /examples/logprobs/logprobs-chat.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/examples/logprobs/logprobs-chat.ts -------------------------------------------------------------------------------- /examples/multimodal/cat.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/examples/multimodal/cat.jpg -------------------------------------------------------------------------------- /examples/multimodal/multimodal.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/examples/multimodal/multimodal.ts -------------------------------------------------------------------------------- /examples/pull-progress/pull.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/examples/pull-progress/pull.ts -------------------------------------------------------------------------------- /examples/structured_outputs/structured-outputs-image.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/examples/structured_outputs/structured-outputs-image.ts -------------------------------------------------------------------------------- /examples/structured_outputs/structured-outputs.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/examples/structured_outputs/structured-outputs.ts -------------------------------------------------------------------------------- /examples/thinking/thinking-enabled.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/examples/thinking/thinking-enabled.ts -------------------------------------------------------------------------------- /examples/thinking/thinking-levels.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/examples/thinking/thinking-levels.ts -------------------------------------------------------------------------------- /examples/thinking/thinking-streaming.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/examples/thinking/thinking-streaming.ts -------------------------------------------------------------------------------- /examples/tools/calculator.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/examples/tools/calculator.ts -------------------------------------------------------------------------------- /examples/tools/flight-tracker.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/examples/tools/flight-tracker.ts -------------------------------------------------------------------------------- /examples/tools/multi-tool.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/examples/tools/multi-tool.ts -------------------------------------------------------------------------------- /examples/websearch/gpt-oss-browser-tools-helpers.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/examples/websearch/gpt-oss-browser-tools-helpers.ts -------------------------------------------------------------------------------- /examples/websearch/gpt-oss-browser-tools.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/examples/websearch/gpt-oss-browser-tools.ts -------------------------------------------------------------------------------- /examples/websearch/websearch-tools.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/examples/websearch/websearch-tools.ts -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/package.json -------------------------------------------------------------------------------- /src/browser.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/src/browser.ts -------------------------------------------------------------------------------- /src/constant.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/src/constant.ts -------------------------------------------------------------------------------- /src/index.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/src/index.ts -------------------------------------------------------------------------------- /src/interfaces.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/src/interfaces.ts -------------------------------------------------------------------------------- /src/utils.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/src/utils.ts -------------------------------------------------------------------------------- /src/version.ts: -------------------------------------------------------------------------------- 1 | export const version = '0.0.0' 2 | -------------------------------------------------------------------------------- /test/browser.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/test/browser.test.ts -------------------------------------------------------------------------------- /test/index.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/test/index.test.ts -------------------------------------------------------------------------------- /test/utils.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/test/utils.test.ts -------------------------------------------------------------------------------- /tsconfig.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ollama/ollama-js/HEAD/tsconfig.json --------------------------------------------------------------------------------