ollama-python/examples/README.md
Parth Sareen c87604c66f
Some checks failed
test / test (push) Has been cancelled
test / lint (push) Has been cancelled
examples: add gpt-oss browser example (#558)
2025-08-11 16:59:26 -07:00

2.4 KiB

Running Examples

Run the examples in this directory with:

# Run example
python3 examples/<example>.py

See ollama/docs/api.md for full API documentation

Chat - Chat with a model

Generate - Generate text with a model

Tools/Function Calling - Call a function with a model

gpt-oss

Multimodal with Images - Chat with a multimodal (image chat) model

Structured Outputs - Generate structured outputs with a model

Ollama List - List all downloaded models and their properties

Ollama Show - Display model properties and capabilities

Ollama ps - Show model status with CPU/GPU usage

Ollama Pull - Pull a model from Ollama

Requirement: pip install tqdm

Ollama Create - Create a model from a Modelfile

Ollama Embed - Generate embeddings with a model

Thinking - Enable thinking mode for a model

Thinking (generate) - Enable thinking mode for a model

Thinking (levels) - Choose the thinking level