conversation

command
v0.5.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 3, 2026 License: MIT Imports: 5 Imported by: 0

Documentation

Overview

Command conversation carries history across multiple turns.

It shows the step beyond a one-shot Complete: keep the messages in a slice, append each reply and follow-up, and send the growing history back every turn. The library is stateless, so retaining and resending the history is how the model "remembers" earlier turns.

The API key is read from the provider's environment variable when StreamOptions.APIKey is empty:

DEEPSEEK_API_KEY=sk-... go run ./example/llm/conversation

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL