[PR #1256] [CLOSED] Implement tensor_split support in modelfile #72821

Closed
opened 2026-05-05 04:23:16 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/ollama/ollama/pull/1256
Author: @Lissanro
Created: 11/23/2023
Status: Closed

Base: mainHead: tensor-split


📝 Commits (2)

  • 513f2ba Implement tensor_split support in modelfile
  • 8575b5b Document tensor_split parameter in docs/modelfile.md

📊 Changes

4 files changed (+4 additions, -0 deletions)

View changed files

📝 api/types.go (+1 -0)
📝 docs/api.md (+1 -0)
📝 docs/modelfile.md (+1 -0)
📝 llm/llama.go (+1 -0)

📄 Description

This patch allows to specify a string for --tensor-split in a modelfile, for example:

PARAMETER tensor_split "25,75"

This allows to adjust VRAM allocation for each model, for example, to optimize VRAM usage on each GPU or to better accommodate models which need more memory for context on the main GPU.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/ollama/ollama/pull/1256 **Author:** [@Lissanro](https://github.com/Lissanro) **Created:** 11/23/2023 **Status:** ❌ Closed **Base:** `main` ← **Head:** `tensor-split` --- ### 📝 Commits (2) - [`513f2ba`](https://github.com/ollama/ollama/commit/513f2badfcb738808de499dfb84e5fc1699b381b) Implement tensor_split support in modelfile - [`8575b5b`](https://github.com/ollama/ollama/commit/8575b5b41e328a19f94049c4d6158bfda31861ec) Document tensor_split parameter in docs/modelfile.md ### 📊 Changes **4 files changed** (+4 additions, -0 deletions) <details> <summary>View changed files</summary> 📝 `api/types.go` (+1 -0) 📝 `docs/api.md` (+1 -0) 📝 `docs/modelfile.md` (+1 -0) 📝 `llm/llama.go` (+1 -0) </details> ### 📄 Description This patch allows to specify a string for --tensor-split in a modelfile, for example: PARAMETER tensor_split "25,75" This allows to adjust VRAM allocation for each model, for example, to optimize VRAM usage on each GPU or to better accommodate models which need more memory for context on the main GPU. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-05-05 04:23:16 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/ollama#72821