Zack Saadioui
8/27/2024
1
2
bash
curl -fsSL https://ollama.com/install.sh | sh1
2
bash
ollama --version1
2
bash
ollama run llama3.11
2
3
4
5
6
7
8
9
10
11
python
import requests
base_url = 'http://localhost:11434/api/chat'
data = {
'model': 'llama3.1',
'messages': [
{'role': 'user', 'content': 'Annotate this text: <your_text_here>'}
]
}
response = requests.post(base_url, json=data)
print(response.json())1
2
3
python
categories = ['Positive', 'Negative', 'Neutral']
selected_category = input(f'Select category {categories}: ')Copyright © Arsturn 2025