import ollama # response = ollama.chat( # model="qwen3_4b_32k", # messages=[ # {"role": "system", "content": "You are a helpful assistant."}, # {"role": "user", "content": "What is the capital of France?"}], # think=True # ) # print(response) import requests response = requests.post( "http://localhost:11434/api/chat", json={ "model": "qwen3_4b_32k", "messages": [ {"role": "system", "content": "You are a helpful assistant."}, {"role": "user", "content": "What is the capital of France?"} ], "think": True, "stream": False } ) print(response.content.decode('utf-8'))