[vc_row][vc_column][vc_headings linewidth=”0″ borderwidth=”1″ borderclr=”#000000″ title=”Ollama” google_fonts=”font_family:Comfortaa%3A300%2Cregular%2C700|font_style:700%20bold%20regular%3A700%3Anormal” titlesize=”60″ titleclr=”#000000″ caption_url=”” caption_urls=”” caption_urlss=”” caption_urldesc=””]Run, build, and share LLMs[/vc_headings][vc_single_image image=”4723″ alignment=”center”][vc_column_text]Ollama is a tool for running large language models on macOS, especially on Apple Silicon devices. It simplifies the process of installing and running Llama2, a powerful and versatile language model that can handle various natural language tasks. With Ollama, users can easily create and deploy applications that use Llama2 without worrying about compatibility issues or performance bottlenecks.[/vc_column_text][/vc_column][/vc_row][vc_row][vc_column][vc_headings style=”theme4″ borderclr=”#000000″ style2=”image” title=”Getting Started” google_fonts=”font_family:Comfortaa%3A300%2Cregular%2C700|font_style:700%20bold%20regular%3A700%3Anormal” lineheight=”3″ titlesize=”40″ titleclr=”#000000″ image_id=”2854″ caption_url=”” caption_urls=”” caption_urlss=”” caption_urldesc=””][/vc_headings][vc_column_text]
To run and chat with the Meta’s new model, Llama 2:
ollama run llama2
Model library
ollama contains a library of open-source models:
[/vc_column_text][vc_raw_html css=”.vc_custom_1690036906405{border-top-width: 2px !important;border-right-width: 2px !important;border-bottom-width: 2px !important;border-left-width: 2px !important;background-color: #dbdbdb !important;border-left-color: #000000 !important;border-left-style: solid !important;border-right-color: #000000 !important;border-right-style: solid !important;border-top-color: #000000 !important;border-top-style: solid !important;border-bottom-color: #000000 !important;border-bottom-style: solid !important;border-radius: 1px !important;}”]JTNDdGFibGUlM0UlMEElM0N0aGVhZCUzRSUwQSUzQ3RyJTNFJTBBJTNDdGglM0VNb2RlbCUzQyUyRnRoJTNFJTBBJTNDdGglM0VQYXJhbWV0ZXJzJTNDJTJGdGglM0UlMEElM0N0aCUzRVNpemUlM0MlMkZ0aCUzRSUwQSUzQ3RoJTNFRG93bmxvYWQlM0MlMkZ0aCUzRSUwQSUzQyUyRnRyJTNFJTBBJTNDJT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MkZ0ZCUzRSUwQSUzQ3RkJTNFMTNCJTNDJTJGdGQlM0UlMEElM0N0ZCUzRTcuM0dCJTNDJTJGdGQlM0UlMEElM0N0ZCUzRSUzQ2NvZGUlM0VvbGxhbWElMjBwdWxsJTIwbm91cy1oZXJtZXMlM0MlMkZjb2RlJTNFJTNDJTJGdGQlM0UlMEElM0MlMkZ0ciUzRSUwQSUzQ3RyJTNFJTBBJTNDdGQlM0VXaXphcmQlMjBWaWN1bmElMjBVbmNlbnNvcmVkJTNDJTJGdGQlM0UlMEElM0N0ZCUzRTEzQiUzQyUyRnRkJTNFJTBBJTNDdGQlM0U3LjNHQiUzQyUyRnRkJTNFJTBBJTNDdGQlM0UlM0Njb2RlJTNFb2xsYW1hJTIwcHVsbCUyMHdpemFyZC12aWN1bmElM0MlMkZjb2RlJTNFJTNDJTJGdGQlM0UlMEElM0MlMkZ0ciUzRSUwQSUzQyUyRnRib2R5JTNFJTBBJTNDJTJGdGFibGUlM0U=[/vc_raw_html][vc_message message_box_color=”black”]The 3B models require a minimum of 8 GB of RAM, the 7B models need at least 16 GB of RAM, and the 13B models demand 32 GB of RAM or more.[/vc_message][/vc_column][/vc_row][vc_row][vc_column][vc_headings style=”theme3″ borderclr=”#000000″ title=”Download Ollama” align=”left” google_fonts=”font_family:Comfortaa%3A300%2Cregular%2C700|font_style:700%20bold%20regular%3A700%3Anormal” lineheight=”3″ titlesize=”40″ titleclr=”#000000″ caption_url=”” caption_urls=”” caption_urlss=”” caption_urldesc=””][/vc_headings][vc_btn title=”Download Ollama” color=”mulled-wine” align=”center” i_align=”right” i_icon_fontawesome=”fas fa-external-link-alt” add_icon=”true” link=”url:https%3A%2F%2Follama.ai%2Fdownload|target:_blank”][vc_column_text]
Examples
Run the model
ollama run llama2
>>> hi
Hello! How can I help you today?
Create a custom model
Pull a base model:
ollama pull llama2
Create the Modelfile:
FROM llama2
# set the temperature to 1 [higher is more creative, lower is more coherent]
PARAMETER temperature 1
# set the system prompt
SYSTEM """
You are Mario from Super Mario Bros. Answer as Mario, the assistant, only.
"""
Then, build and run the model:
ollama create mario -f ./Modelfile
ollama run mario
>>> hi
Hello! It's your friend Mario.
Check the examples directory for more examples
Pull a model from the registry
ollama pull orca
Listing local models
ollama list
Model packages
Overview
A Modelfile is a file that specifies the data, configuration, and model weights for Ollama bundles. Ollama bundles are packages that contain everything needed to run a machine-learning model.
Build
go build .
To run it, you have to start the server:
./ollama serve &
Finally, run the model!
./ollama run llama2
REST API
POST /api/generate
Generate text from a model.
curl -X POST http://localhost:11434/api/generate -d '{"model": "llama2", "prompt":"Why is the sky blue?"}'
[/vc_column_text][/vc_column][/vc_row]



0 Comments