mirror of
https://github.com/ollama/ollama.git
synced 2026-05-05 23:53:43 -05:00
Open
opened 2026-04-12 12:51:08 -05:00 by GiteaMirror
·
36 comments
No Branch/Tag Specified
main
dhiltgen/ci
hoyyeva/editor-config-repair
parth-launch-codex-app
hoyyeva/fix-codex-model-metadata-warning
hoyyeva/qwen
hoyyeva/launch-backup-ux
parth/hide-claude-desktop-till-release
hoyyeva/opencode-image-modality
parth-mlx-decode-checkpoints
parth-add-claude-code-autoinstall
release_v0.22.0
pdevine/manifest-list
codex/fix-codex-model-metadata-warning
pdevine/addressable-manifest
brucemacd/launch-fetch-reccomended
jmorganca/llama-compat
launch-copilot-cli
hoyyeva/opencode-thinking
release_v0.20.7
parth-auto-save-backup
parth-test
jmorganca/gemma4-audio-replacements
fix-manifest-digest-on-pull
hoyyeva/vscode-improve
brucemacd/install-server-wait
brucemacd/download-before-remove
parth/update-claude-docs
parth-anthropic-reference-images-path
brucemac/start-ap-install
pdevine/mlx-update
pdevine/qwen35_vision
drifkin/api-show-fallback
mintlify/image-generation-1773352582
hoyyeva/server-context-length-local-config
jmorganca/faster-reptition-penalties
jmorganca/convert-nemotron
parth-pi-thinking
pdevine/sampling-penalties
jmorganca/fix-create-quantization-memory
dongchen/resumable_transfer_fix
pdevine/sampling-cache-error
jessegross/mlx-usage
hoyyeva/openclaw-config
hoyyeva/app-html
pdevine/qwen3next
brucemacd/sign-sh-install
brucemacd/tui-update
brucemacd/usage-api
jmorganca/launch-empty
fix-app-dist-embed
mxyng/mlx-compile
mxyng/mlx-quant
mxyng/mlx-glm4.7
mxyng/mlx
brucemacd/simplify-model-picker
jmorganca/qwen3-concurrent
fix-glm-4.7-flash-mla-config
drifkin/qwen3-coder-opening-tag
brucemacd/usage-cli
fix-cuda12-fattn-shmem
ollama-imagegen-docs
parth/fix-multiline-inputs
brucemacd/config-docs
mxyng/model-files
mxyng/simple-execute
fix-imagegen-ollama-models
mxyng/async-upload
jmorganca/lazy-no-dtype-changes
imagegen-auto-detect-create
parth/decrease-concurrent-download-hf
fix-mlx-quantize-init
jmorganca/x-cleanup
usage
imagegen-readme
jmorganca/glm-image
mlx-gpu-cd
jmorganca/imagegen-modelfile
parth/agent-skills
parth/agent-allowlist
parth/signed-in-offline
parth/agents
parth/fix-context-chopping
improve-cloud-flow
parth/add-models-websearch
parth/prompt-renderer-mcp
jmorganca/native-settings
jmorganca/download-stream-hash
jmorganca/client2-rebased
brucemacd/oai-chat-req-multipart
jessegross/multi_chunk_reserve
grace/additional-omit-empty
grace/mistral-3-large
mxyng/tokenizer2
mxyng/tokenizer
jessegross/flash
hoyyeva/windows-nacked-app
mxyng/cleanup-attention
grace/deepseek-parser
hoyyeva/remember-unsent-prompt
parth/add-lfs-pointer-error-conversion
parth/olmo2-test2
hoyyeva/ollama-launchagent-plist
nicole/olmo-model
parth/olmo-test
mxyng/remove-embedded
parth/render-template
jmorganca/intellect-3
parth/remove-prealloc-linter
jmorganca/cmd-eval
nicole/nomic-embed-text-fix
mxyng/lint-2
hoyyeva/add-gemini-3-pro-preview
hoyyeva/load-model-list
mxyng/expand-path
mxyng/environ-2
hoyyeva/deeplink-json-encoding
parth/improve-tool-calling-tests
hoyyeva/conversation
hoyyeva/assistant-edit-response
hoyyeva/thinking
origin/brucemacd/invalid-char-i-err
parth/improve-tool-calling
jmorganca/required-omitempty
grace/qwen3-vl-tests
mxyng/iter-client
parth/docs-readme
nicole/embed-test
pdevine/integration-benchstat
parth/remove-generate-cmd
parth/add-toolcall-id
mxyng/server-tests
jmorganca/glm-4.6
jmorganca/gin-h-compat
drifkin/stable-tool-args
pdevine/qwen3-more-thinking
parth/add-websearch-client
nicole/websearch_local
jmorganca/qwen3-coder-updates
grace/deepseek-v3-migration-tests
mxyng/fix-create
jmorganca/cloud-errors
pdevine/parser-tidy
revert-12233-parth/simplify-entrypoints-runner
parth/enable-so-gpt-oss
brucemacd/qwen3vl
jmorganca/readme-simplify
parth/gpt-oss-structured-outputs
revert-12039-jmorganca/tools-braces
mxyng/embeddings
mxyng/gguf
mxyng/benchmark
mxyng/types-null
parth/move-parsing
mxyng/gemma2
jmorganca/docs
mxyng/16-bit
mxyng/create-stdin
pdevine/authorizedkeys
mxyng/quant
parth/opt-in-error-context-window
brucemacd/cache-models
brucemacd/runner-completion
jmorganca/llama-update-6
brucemacd/benchmark-list
brucemacd/partial-read-caps
parth/deepseek-r1-tools
mxyng/omit-array
parth/tool-prefix-temp
brucemacd/runner-test
jmorganca/qwen25vl
brucemacd/model-forward-test-ext
parth/python-function-parsing
jmorganca/cuda-compression-none
drifkin/num-parallel
drifkin/chat-truncation-fix
jmorganca/sync
parth/python-tools-calling
drifkin/array-head-count
brucemacd/create-no-loop
parth/server-enable-content-stream-with-tools
qwen25omni
mxyng/v3
brucemacd/ropeconfig
jmorganca/silence-tokenizer
parth/sample-so-test
parth/sampling-structured-outputs
brucemacd/doc-go-engine
parth/constrained-sampling-json
jmorganca/mistral-wip
brucemacd/mistral-small-convert
parth/sample-unmarshal-json-for-params
brucemacd/jomorganca/mistral
pdevine/bfloat16
jmorganca/mistral
brucemacd/mistral
pdevine/logging
parth/sample-correctness-fix
parth/sample-fix-sorting
jmorgan/sample-fix-sorting-extras
jmorganca/temp-0-images
brucemacd/parallel-embed-models
brucemacd/shim-grammar
jmorganca/fix-gguf-error
bmizerany/nameswork
jmorganca/faster-releases
bmizerany/validatenames
brucemacd/err-no-vocab
brucemacd/rope-config
brucemacd/err-hint
brucemacd/qwen2_5
brucemacd/logprobs
brucemacd/new_runner_graph_bench
progress-flicker
brucemacd/forward-test
brucemacd/go_qwen2
pdevine/gemma2
jmorganca/add-missing-symlink-eval
mxyng/next-debug
parth/set-context-size-openai
brucemacd/next-bpe-bench
brucemacd/next-bpe-test
brucemacd/new_runner_e2e
brucemacd/new_runner_qwen2
pdevine/convert-cohere2
brucemacd/convert-cli
parth/log-probs
mxyng/next-mlx
mxyng/cmd-history
parth/templating
parth/tokenize-detokenize
brucemacd/check-key-register
bmizerany/grammar
jmorganca/vendor-081b29bd
mxyng/func-checks
jmorganca/fix-null-format
parth/fix-default-to-warn-json
jmorganca/qwen2vl
jmorganca/no-concat
parth/cmd-cleanup-SO
brucemacd/check-key-register-structured-err
parth/openai-stream-usage
parth/fix-referencing-so
stream-tools-stop
jmorganca/degin-1
brucemacd/install-path-clean
brucemacd/push-name-validation
brucemacd/browser-key-register
jmorganca/openai-fix-first-message
jmorganca/fix-proxy
jessegross/sample
parth/disallow-streaming-tools
dhiltgen/remove_submodule
jmorganca/ga
jmorganca/mllama
pdevine/newlines
pdevine/geems-2b
jmorganca/llama-bump
mxyng/modelname-7
mxyng/gin-slog
mxyng/modelname-6
jyan/convert-prog
jyan/quant5
paligemma-support
pdevine/import-docs
jmorganca/openai-context
jyan/paligemma
jyan/p2
jyan/palitest
bmizerany/embedspeedup
jmorganca/llama-vit
brucemacd/allow-ollama
royh/ep-methods
royh/whisper
mxyng/api-models
mxyng/fix-memory
jyan/q4_4/8
jyan/ollama-v
royh/stream-tools
roy-embed-parallel
bmizerany/hrm
revert-5963-revert-5924-mxyng/llama3.1-rope
royh/embed-viz
jyan/local2
jyan/auth
jyan/local
jyan/parse-temp
jmorganca/template-mistral
jyan/reord-g
royh-openai-suffixdocs
royh-imgembed
royh-embed-parallel
jyan/quant4
royh-precision
jyan/progress
pdevine/fix-template
jyan/quant3
pdevine/ggla
mxyng/update-registry-domain
jmorganca/ggml-static
mxyng/create-context
jyan/v0.146
mxyng/layers-from-files
build_dist
bmizerany/noseek
royh-ls
royh-name
timeout
mxyng/server-timestamp
bmizerany/nosillyggufslurps
royh-params
jmorganca/llama-cpp-7c26775
royh-openai-delete
royh-show-rigid
jmorganca/enable-fa
jmorganca/no-error-template
jyan/format
royh-testdelete
bmizerany/fastverify
language_support
pdevine/ps-glitches
brucemacd/tokenize
bruce/iq-quants
bmizerany/filepathwithcoloninhost
mxyng/split-bin
bmizerany/client-registry
jmorganca/if-none-match
native
jmorganca/native
jmorganca/batch-embeddings
jmorganca/initcmake
jmorganca/mm
pdevine/showggmlinfo
modenameenforcealphanum
bmizerany/modenameenforcealphanum
jmorganca/done-reason
jmorganca/llama-cpp-8960fe8
ollama.com
bmizerany/filepathnobuild
bmizerany/types/model/defaultfix
rmdisplaylong
nogogen
bmizerany/x
modelfile-readme
bmizerany/replacecolon
jmorganca/limit
jmorganca/execstack
jmorganca/replace-assets
mxyng/tune-concurrency
jmorganca/testing
whitespace-detection
jmorganca/options
upgrade-all
scratch
cuda-search
mattw/airenamer
mattw/allmodelsonhuggingface
mattw/quantcontext
mattw/whatneedstorun
brucemacd/llama-mem-calc
mattw/faq-context
mattw/communitylinks
mattw/noprune
mattw/python-functioncalling
rename
mxyng/install
pulse
remove-first
editor
mattw/selfqueryingretrieval
cgo
mattw/howtoquant
api
matt/streamingapi
format-config
mxyng/extra-args
shell
update-nous-hermes
cp-model
upload-progress
fix-unknown-model
fix-model-names
delete-fix
insecure-registry
ls
deletemodels
progressbar
readme-updates
license-layers
skip-list
list-models
modelpath
matt/examplemodelfiles
distribution
go-opts
v0.23.1
v0.23.1-rc0
v0.23.0
v0.23.0-rc0
v0.22.1
v0.22.1-rc1
v0.22.1-rc0
v0.22.0
v0.22.0-rc1
v0.21.3-rc0
v0.21.2-rc1
v0.21.2
v0.21.2-rc0
v0.21.1
v0.21.1-rc1
v0.21.1-rc0
v0.21.0
v0.21.0-rc1
v0.21.0-rc0
v0.20.8-rc0
v0.20.7
v0.20.7-rc1
v0.20.7-rc0
v0.20.6
v0.20.6-rc1
v0.20.6-rc0
v0.20.5
v0.20.5-rc2
v0.20.5-rc1
v0.20.5-rc0
v0.20.4
v0.20.4-rc2
v0.20.4-rc1
v0.20.4-rc0
v0.20.3
v0.20.3-rc0
v0.20.2
v0.20.1
v0.20.1-rc2
v0.20.1-rc1
v0.20.1-rc0
v0.20.0
v0.20.0-rc1
v0.20.0-rc0
v0.19.0
v0.19.0-rc2
v0.19.0-rc1
v0.19.0-rc0
v0.18.4-rc1
v0.18.4-rc0
v0.18.3
v0.18.3-rc2
v0.18.3-rc1
v0.18.3-rc0
v0.18.2
v0.18.2-rc1
v0.18.2-rc0
v0.18.1
v0.18.1-rc1
v0.18.1-rc0
v0.18.0
v0.18.0-rc2
v0.18.0-rc1
v0.18.0-rc0
v0.17.8-rc4
v0.17.8-rc3
v0.17.8-rc2
v0.17.8-rc1
v0.17.8-rc0
v0.17.7
v0.17.7-rc2
v0.17.7-rc1
v0.17.7-rc0
v0.17.6
v0.17.5
v0.17.4
v0.17.3
v0.17.2
v0.17.1
v0.17.1-rc2
v0.17.1-rc1
v0.17.1-rc0
v0.17.0
v0.17.0-rc2
v0.17.0-rc1
v0.17.0-rc0
v0.16.3
v0.16.3-rc2
v0.16.3-rc1
v0.16.3-rc0
v0.16.2
v0.16.2-rc0
v0.16.1
v0.16.0
v0.16.0-rc2
v0.16.0-rc0
v0.16.0-rc1
v0.15.6
v0.15.5
v0.15.5-rc5
v0.15.5-rc4
v0.15.5-rc3
v0.15.5-rc2
v0.15.5-rc1
v0.15.5-rc0
v0.15.4
v0.15.3
v0.15.2
v0.15.1
v0.15.1-rc1
v0.15.1-rc0
v0.15.0-rc6
v0.15.0
v0.15.0-rc5
v0.15.0-rc4
v0.15.0-rc3
v0.15.0-rc2
v0.15.0-rc1
v0.15.0-rc0
v0.14.3
v0.14.3-rc3
v0.14.3-rc2
v0.14.3-rc1
v0.14.3-rc0
v0.14.2
v0.14.2-rc1
v0.14.2-rc0
v0.14.1
v0.14.0-rc11
v0.14.0
v0.14.0-rc10
v0.14.0-rc9
v0.14.0-rc8
v0.14.0-rc7
v0.14.0-rc6
v0.14.0-rc5
v0.14.0-rc4
v0.14.0-rc3
v0.14.0-rc2
v0.14.0-rc1
v0.14.0-rc0
v0.13.5
v0.13.5-rc1
v0.13.5-rc0
v0.13.4-rc2
v0.13.4
v0.13.4-rc1
v0.13.4-rc0
v0.13.3
v0.13.3-rc1
v0.13.3-rc0
v0.13.2
v0.13.2-rc2
v0.13.2-rc1
v0.13.2-rc0
v0.13.1
v0.13.1-rc2
v0.13.1-rc1
v0.13.1-rc0
v0.13.0
v0.13.0-rc0
v0.12.11
v0.12.11-rc1
v0.12.11-rc0
v0.12.10
v0.12.10-rc1
v0.12.10-rc0
v0.12.9-rc0
v0.12.9
v0.12.8
v0.12.8-rc0
v0.12.7
v0.12.7-rc1
v0.12.7-rc0
v0.12.7-citest0
v0.12.6
v0.12.6-rc1
v0.12.6-rc0
v0.12.5
v0.12.5-rc0
v0.12.4
v0.12.4-rc7
v0.12.4-rc6
v0.12.4-rc5
v0.12.4-rc4
v0.12.4-rc3
v0.12.4-rc2
v0.12.4-rc1
v0.12.4-rc0
v0.12.3
v0.12.2
v0.12.2-rc0
v0.12.1
v0.12.1-rc1
v0.12.1-rc2
v0.12.1-rc0
v0.12.0
v0.12.0-rc1
v0.12.0-rc0
v0.11.11
v0.11.11-rc3
v0.11.11-rc2
v0.11.11-rc1
v0.11.11-rc0
v0.11.10
v0.11.9
v0.11.9-rc0
v0.11.8
v0.11.8-rc0
v0.11.7-rc1
v0.11.7-rc0
v0.11.7
v0.11.6
v0.11.6-rc0
v0.11.5-rc4
v0.11.5-rc3
v0.11.5
v0.11.5-rc5
v0.11.5-rc2
v0.11.5-rc1
v0.11.5-rc0
v0.11.4
v0.11.4-rc0
v0.11.3
v0.11.3-rc0
v0.11.2
v0.11.1
v0.11.0-rc0
v0.11.0-rc1
v0.11.0-rc2
v0.11.0
v0.10.2-int1
v0.10.1
v0.10.0
v0.10.0-rc4
v0.10.0-rc3
v0.10.0-rc2
v0.10.0-rc1
v0.10.0-rc0
v0.9.7-rc1
v0.9.7-rc0
v0.9.6
v0.9.6-rc0
v0.9.6-ci0
v0.9.5
v0.9.4-rc5
v0.9.4-rc6
v0.9.4
v0.9.4-rc3
v0.9.4-rc4
v0.9.4-rc1
v0.9.4-rc2
v0.9.4-rc0
v0.9.3
v0.9.3-rc5
v0.9.4-citest0
v0.9.3-rc4
v0.9.3-rc3
v0.9.3-rc2
v0.9.3-rc1
v0.9.3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19
v0.1.18
v0.1.17
v0.1.16
v0.1.15
v0.1.14
v0.1.13
v0.1.12
v0.1.11
v0.1.10
v0.1.9
v0.1.8
v0.1.7
v0.1.6
v0.1.5
v0.1.4
v0.1.3
v0.1.2
v0.1.1
v0.1.0
v0.0.21
v0.0.20
v0.0.19
v0.0.18
v0.0.17
v0.0.16
v0.0.15
v0.0.14
v0.0.13
v0.0.12
v0.0.11
v0.0.10
v0.0.9
v0.0.8
v0.0.7
v0.0.6
v0.0.5
v0.0.4
v0.0.3
v0.0.2
v0.0.1
Labels
Clear labels
amd
api
app
bug
build
cli
cloud
compatibility
context-length
create
docker
documentation
embeddings
feature request
feedback wanted
good first issue
gpt-oss
gpu
harmony
help wanted
image
install
intel
js
launch
linux
macos
memory
mlx
model
needs more info
networking
nvidia
ollama.com
performance
pull-request
python
question
registry
rendering
thinking
tools
top
vulkan
windows
wsl
Mirrored from GitHub Pull Request
Milestone
No items
No Milestone
Projects
Clear projects
No project
No Assignees
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: github-starred/ollama#2529
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @owenzhao on GitHub (May 1, 2024).
Original GitHub issue: https://github.com/ollama/ollama/issues/4072
Originally assigned to: @dhiltgen on GitHub.
I am using Ollama 0.1.32 on Windows 11. Ollama is set to provide LLMs on LAN. However, when I use it, sometimes the Windows goes sleep mode when I am waiting Ollama answering questions using API.
So I guess Ollama does not prevent Windows 11 into sleep even through Ollama is working.
Ollama is install natively, not docker.
@molbal commented on GitHub (May 1, 2024):
I do not think this is an Ollama question - you are using the consumer version of Windows as a server. That being said, I recommend using this Powertoys utility as a workaround: https://learn.microsoft.com/en-us/windows/powertoys/awake
@owenzhao commented on GitHub (May 1, 2024):
Thanks. But I don't think this is a good approach.
Even with a consumer version of Windows, an app prevent the system into sleep is very common. I believe you must have used this kind of apps. For example, Video Player like MPV can prevent the system into sleep during playing movies. Music players can prevent the system into sleep when a song is played.
Powertoys can prevent the system sleep when a specified process is running by its pid. But that is not what I expected. As my idea is to prevent the system sleep only when Ollama is working. If the Ollama server is started but waiting in background, it should not prevent the system into sleep. It is just like the video players, only prevent the system into sleep when a video is playing.
Also, even with a consumer version of Windows, the prevent sleep API is provided by the system. So there should no different whether the system is a consumer version or a server version.
If I design this feature in Ollama, I will extend the time length of preventing the system into sleep every time Ollama answers a question. Five minutes will be enough.
@dhiltgen commented on GitHub (May 1, 2024):
This looks like a good first issue.
https://learn.microsoft.com/en-us/windows/win32/api/winbase/nf-winbase-setthreadexecutionstate
ddc2195639/process.go (L144)Wired into the scheduler to toggle state when there is (or isn't) an active runner.
@centopw commented on GitHub (May 2, 2024):
I think it would be handy to add an option in the settings or menu to toggle "Keep PC Awake" in Ollama. Not everyone needs their PC to stay awake while using it, so having this option would be great for those who do and for those who don't. It's all about giving users the choice they want. What do you think?
@eirnym commented on GitHub (May 9, 2024):
@owenzhao My guess based on a description of your setup, is windows machine is set up as a ollama server. The server once in a while goes to sleep as you described. You requested that when Ollama is working, Windows machine should not go to sleep and when ollama is not working Windows machine should be allowed to go to sleep.
I propose a complex solution which could satisfy your needs.
Please note, that it's not common and it's not recommended to prevent sleeping when working from a service. it's generally considered a bad and dangerous practice and there's many other workarounds. Usually when a computer is in server role, it runs all the time without going to sleep (see my suggestion on power/battery settings).
@owenzhao commented on GitHub (May 9, 2024):
I found that many of the replies were not got what I meant. So I want to reclaim what I mean.
First, many of you mixed Ollama server started in background and was working. So the suggestions were useless.
When Windows system starts, Ollama server starts alone with it. There is no settings need to do on that. That is the default behavior of Ollama.exe.
When Ollama server starts and no one is using it, I call it starts in background.
If I start my own app and use Ollama API to connect with Ollama server, I call it is working.
My intent is not kept Windows awake when Ollama server starts in background, which is many of you suggest to use PID with power toy. Again, that was not my intent. My intent is to stop Windows to sleep when I call the Ollama's API and waiting the results.
Currently, sometimes when I called Ollama API and was waiting the result or just got the result and before I called the next Ollama API, the Windows slept. That was very odd and I think should be changed.
@eirnym commented on GitHub (May 10, 2024):
@owenzhao
It could be handy when you work on the same computer. To start and stop a service efficiently there's windows services and they are universal.
Also automatic services start automatically without logging in.
I don't know how you use it, proposed solution should be good for others as well. I use Ollama sporadically or within IDE, e.g. I expect it running when I work, not per a single request.
And based on console logs and local tests, when I run Ollama in interactive mode it doesn't call Ollama all the time and I can restart a server in between calls. And I prefer to keep it this way.
Thus,proposed solution is a half-ok as server would go to sleep just after a single request goes off and it would be more frustrating as AFAIK programmatic method doesn't reset sleep timer.
Additionally, starting and stopping windows server is much easier than you think as it's an unattended action (ssh can be used as a universal solution).
More so, the best and the most manageable solution is to use required Power Settings, not changing service to prevent OS sleeping, which is the worst practice.
I vote strongly against proposed and against changing how interactive mode works as well.
@owenzhao commented on GitHub (May 10, 2024):
Can you explain why you think it is the worst practice as many other apps can do that and the system is allowed to do that so they provided API. As I pointed out, many movie players can do that. So why that is the worst practice? I don't think there any drawbacks. As the system only awake during the working time, the system can still go to sleep if Ollama is not needed.
@eirnym commented on GitHub (May 10, 2024):
I don't speak for consumer apps, but for services specifically. The reason is quite simple: the administrator defines how computer should work, not a service. And you is an administrator of your computer. Also if a background app preventing computer to go to sleep and user doesn't aware of it (explicit action/setting), then it becomes a hassle to manage actual power settings and battery life, especially if we speak about laptops. For example, I as a developer usually have multiple services on my laptop and if any of them would prevent sleep without my explicit setting, I'd just remove a service, and if I'd like to run a homelab server on a laptop or desktop, I'd set my power settings in such way, that laptop won't go to sleep till I say so. One of a good examples of such behaviour is community project wsusoffline (and their derivatives).
Video players are kind'a an exception here (not really), as a user stare at screen for a long period of time and doesn't want to be disturbed from an entertainment. Not really as it is a mass user desire.
Simplifying things, Ollama is an ordinary HTTP server (it's written in documentation as well), which provides a main function on the backend to ask model to produce some response on some request, nothing more, nothing else. Response is quite small and limited in time.
@eirnym commented on GitHub (May 10, 2024):
the definition of "Ollama is not needed" is quite vague. It serves a request/response, but don't keep connection alive (which I prefer to keep this way), so the only time Ollama actually serves something is when there's an explicit user interaction. Don't take my word and check it yourself. I tested provided commands in my terminal, you can test in any other way you'd like.
ollama serve)ollama run <model>with any model you already have.With this out of the way, I'd define "Ollama is needed" as "I have a session with Ollama". The script to run Ollama serving contents and set specific predefined power settings and then stopping Ollama and revert Power Settings is more universal and easier to implement. AFAIK, PowerToys require an active GUI session
@owenzhao commented on GitHub (May 11, 2024):
I think we are not talking the same thing. You suggest me to use SSH, so you supposed I am using a remote terminal. I am not. I am using an app that use Ollama's API. So there is no SSH, just http.
@owenzhao commented on GitHub (May 11, 2024):
Also, I think it is common that a server stops the OS from sleeping. For example, SMB, the file sharing service of the Windows, which is also the preferred file sharing service in macOS. When you play a movie from SMB, the OS runs SMB won't go to sleep as long as you playing the movie. So the SMB must have the ability to stop the OS from sleeping.
What I want is the same. I don't think this is a bad idea. It is just like you don't want the OS to sleep when you are playing a movie on SMB.
@eirnym commented on GitHub (May 11, 2024):
SMB is not the same at all. This is a low-level driver. This represents a file system and it's critical for the operation system to provide guarantee that data transferred would be transferred without data losses and all writes would written to the disk.
You have no such guarantee for user space file systems such as sshfs.
@owenzhao commented on GitHub (May 11, 2024):
You have too many principles, but can you consider the user experience? A naive user, which is me, just think they are the same and should work alike.
@eirnym commented on GitHub (May 12, 2024):
They are not the same and should not work alike.
A HTTP server is not a system driver on a host OS and should not be considered alike even from an end user perspective. You can install any other HTTP servers and try yourself. Even Docker (paid) doesn't prevent computer go to sleep. (I know there's issue that some users complain that docker prevents computer to sleep, while I don't experience this issue on my systems)
You want a feature you can do as a power user (not even system administrator) if you just switch power settings to another profile.
Proposed solution by me is easy to implement, easy to use, intuitive and universal. You don't need special knowledge to write specific Power Shell scripts, just copy-paste from other projects including mentioned ones or from services like Stack Overflow.
@owenzhao commented on GitHub (May 13, 2024):
They are just the same. They are the same until you add new rules.
First, you say servers are not apps. Then, you say servers are not the same. So you just want to keep your point, instead of listening. You force me to user power settings, which is totally a different thing. Power setting are set for the global, what I suggest is for the local, specially for the Ollama. Why local should change global? Where are your principles now?
This thing is easy and clear. The system provides API to keep the OS awake. The decision is made by developer to improve user experience. Whether to do depends on if the solution is expected by the user. This is the only rule. Not other rules are needed. Intuitively, if a user expects the app should work, then it is a good solution.
@eirnym commented on GitHub (May 13, 2024):
How are they the same? You set "rules" that they are the same. Please, ask Google Search (or any other similar) if a HTTP server is the same as SMB service and what is a bad or good practice for keeping machine awake.
Ollama has server component server which you want to run on a windows machine and client you want to run on a separate machine.
That is you propose to set global thing using a non-critical service. Please, don't mess with responsibility of between service and administrator. You're an administrator of your personal computer and you are responsible of how things should be done.
I explained how Ollama works a few times and you probably skipped these parts. At the beginning you asked to keep windows alive per request, which would not a reasonable solution and I explained why.
If change will be per request, your single request will be finished and the next may not start and you won't be happy. Again.
For example, let's imagine your proposition has been implemented and another user installed Ollama on a laptop with Windows. Ollama per your request will drain battery as computer won't go to sleep. Or let's imagine places with high electricity bill, people won't be happy that their computer drains their money as it doesn't want to go to sleep when it supposed to.
@xgdgsc commented on GitHub (Nov 20, 2024):
I fully support the author' s proposal. As it' s valid use case someone wants to share an ollama instance in office LAN for co-workers to use on a laptop with windows hello that goes to sleep fast when the laptop owner take a break. Adding the mode of preventing sleep when tokens are generated or remote chat connections are active would help a lot, both with electricity consumption and user experience.
@owenzhao commented on GitHub (Nov 20, 2024):
I don't believe "a laptop with windows hello that goes to sleep fast when the laptop owner take a break" is a valid example for working as a server. Do you know what is a server? Server means providing constant services. A Server should not break as it wishes even if it provides services for no charge.
@molbal commented on GitHub (Nov 20, 2024):
For laptops use something like this: https://learn.microsoft.com/en-us/windows/powertoys/awake
@Snehallaldas commented on GitHub (Dec 11, 2024):
You can create a simple PowerShell script that monitors whether a specific application is running. When the application is active, the script will stop your computer from going to sleep. Once you close the application, it will restore your system's default sleep settings.
Steps:
Write the Script: Open a text editor (like Notepad) and paste the following code. Save the file as PreventSleep.ps1
Replace "YourApplicationName" with the name of the app's process (e.g., "notepad").
$AppName = "YourApplicationName"
$SleepDisabled = $false
while ($true) {
# Check if the application is running.
$AppRunning = Get-Process -Name $AppName -ErrorAction SilentlyContinue
}
Replace "YourApplicationName" with the name of the application's process. For example, if you want this for Notepad, use notepad.
Run the Script:
Open PowerShell as an Administrator.
Navigate to the folder where you saved the script.
Run the script using the command:
powershell
Copy code
.\PreventSleep.ps1
The script will now monitor your application and manage sleep settings.
Make It Run Automatically: If you want this to work every time you start your computer or open the application:
Use Task Scheduler to run the script on startup or when the application launches.
Alternatively, create a shortcut to the script and run it manually when needed.
This script essentially checks every 10 seconds if the specified app is running. If it finds the app, it keeps the computer awake. Once the app is closed, it restores your default sleep settings. It’s a lightweight and automatic way to handle this without manually toggling any settings.
@owenzhao commented on GitHub (Dec 11, 2024):
Thanks for your reply. However, this solution won't work on the situation that Ollama working on another machine. To simplified my question. Let's assume you have an application that makes API calls to another computer running Ollama. The purpose of this application is to batch process images by utilizing Ollama to identify the content in those images. This is typically a lengthy process. As a result, it's quite common for the application to keep waiting for Ollama to finish processing while the other computer has already gone to sleep.
@eirnym commented on GitHub (Dec 11, 2024):
@owenzhao Could you please collaborate why script provided won't work in your case?
Please note, that this script doesn't require remote session and you can run it remotely as well (e.g. via SSH)
@owenzhao commented on GitHub (Dec 11, 2024):
It does run everywhere. But what if the server running Ollama is not mine? As I may provide the app on the App Store. You suggest me to ask the users to run the script one by one? That will reduce potential users hugely and leading a developer looking for servers other than Ollama as a replacement.
@owenzhao commented on GitHub (Dec 11, 2024):
Besides, my suggestion is not prevent a computer to sleep if Ollama is running. I want my app is not interrupt after it start working with Ollama. So the condition will be "ollama ps" has outputs. If "ollama ps" is empty, the computer can sleep as it is.
@eirnym commented on GitHub (Dec 12, 2024):
Condition in script provided can be improved to satisfy your needs: to check if process exists and command output satisfy "if processing is running".
Additionally, other power settings can be set to satisfy your personal preferences.
Powershell scripting is powerful enough to satisfy your needs
@Bob2345de commented on GitHub (Feb 14, 2025):
Has someone managed to create a suitable PS script for this?
@michael-stief commented on GitHub (Mar 5, 2025):
I would also be interested in this feature. My use case is to use Ollama every now and then. I can specify a program/script in my client before a request is sent to Ollama, in my case a Wake-on-LAN packet via internet. My PC wakes up from standby and can compute the response. My PC is a lot more powerful than my laptop, but no high-end machine so the response can take between a few minutes and an hour. My PCs is set to go to standby real fast since I use it only for occasional requests and gaming when I'm at home.
Monitoring the PID doesn't really help in my use case. I'd have to connect to my PC with VPN and RDP to manually start and stop the service each time I ask a question. Also since I don't know how long it will take to generate the answer I'd like to do something else, check later for the answer and be sure it was fully computed and received. My PC shouldn't go into standby in the meantime while it is still working on it. But I also want my PC to go to standby automatically how I configured it in the energy options in Windows as soon as the question is processed. If I need my PC again for another question and the pause between them are larger than the configured standby time another magic packet automatically sent before my question will take care of it.
The suggestion from owenzhao is perfectly valid in my opinion. As long as Ollama is working on a response it should prevent standby since it's uncertain how long the response will take. After it's finished, it should allow the PC to go into standby as usual.
@eirnym commented on GitHub (Mar 6, 2025):
@michael-stief Could you tell if I understood your correctly. You log into your PC, asking
ollamafor a single answer, then keep it sleeping?If my assumption is correct, then I see it as scenario in a script below. It's written in Zsh, but is applicable to your situation as well.
Checking
ollama psinstead of just plain PID would help in your situation. The script logic won't change much. Inzshit would be something like this:ollama ps | wc -land do something with a number.@eirnym commented on GitHub (Mar 6, 2025):
@Bob2345de What from the script above doesn't work in your situation?
@Alexious-sh commented on GitHub (Jul 28, 2025):
Come on! Did anyone from "scripters" ever used ollama on a remote machine? No one runs
ollama run...through SSH or whatever. Most of the people using the API, commenting from open-webui or any other system. It doesn't spawn any extra process you could monitor externally. That's why, I think, it's an ollama's responsibility to keep a wakelock while LLM is active. Especially, given that it shouldn't be so hard to implement.@molbal commented on GitHub (Jul 28, 2025):
Following that logic @Alexious-sh all other servers should maintain their own wake locks.
Ollama shouldn't be responsible for the environment it's running in.
@eirnym commented on GitHub (Jul 28, 2025):
@Alexious-sh if you use web api, use one of the method above to keep machine awake while server is running.
@Alexious-sh commented on GitHub (Sep 1, 2025):
@molbal This is how Windows apps usually do. Unfortunately, non-server Windows systems doesn't have many built-in tools to achieve something like systemd sockets provide on Linux. E.g. I currently have a middleware proxy service running on a dedicated low-power machine, which sends a Wake-on-LAN packet to my desktop if it's sleeping and then proxies everything to the Ollama running there. And the only problem now is that PC could fall asleep in the middle of interaction with Ollama.
@eirnym Which one? Using "numerous of unspoken ways to theoretically do something" or tracking the PID of the always running
ollama serveprocess? None of them helped, unfortunately.@eirnym commented on GitHub (Sep 1, 2025):
@Alexious-sh Thank you for sharing your setup.
Could you please share your experience how exactly you've implemented and didn't worked. Specific implementation would help others to help and others to use.
@tdbe commented on GitHub (Oct 26, 2025):
Despite the abundance of common use presented, seems a few ollama contributors have developed cutting edge mental gymnastics for why they like their computer turning off to save power while it's in the middle of serving.
Here's the expected solution until the stegosauruses go away: You're probably running ollama through a js web client like this, something you can edit/extend. So:
Just make every
Sendof the prompt window also send a command thatresets the idle timerof the server OS.Need to use a custom (python) server for this, and start it after logon. (An apache php's script exec invoke or other GUI-less environments afaics forbid access to any idle reset events.)
Using key press events (simplest reliable option), with pyautogui (but nircmd also works).
Server.py:
Client js usage example (also call this when you press Send):
This will work cross-domain on your LAN. You can now WoL and use ollama free from the mushy chew of the stegosaurus.