chat method

Future<String> chat(
  1. String model,
  2. String prompt, {
  3. String? system,
})

Single-turn chat (native Ollama API). Returns response text with any <think>…</think> reasoning block stripped (user-visible content only).

For full access to the reasoning trace, use chatWithThinking.

Implementation

Future<String> chat(String model, String prompt, {String? system}) async {
  final result = await chatWithThinking(model, prompt, system: system);
  return result.content;
}