14 lines
293 B
Python
14 lines
293 B
Python
from ollama import Client
|
|
|
|
client = Client(host='http://192.168.178.45:11434')
|
|
|
|
user_prompt = input("Ask mistral-nemo a question: ")
|
|
|
|
response = client.chat(model='mistral-nemo', messages=[
|
|
{
|
|
'role': 'user',
|
|
'content': f'{user_prompt}',
|
|
},
|
|
])
|
|
print(response['message']['content'])
|