ask

package
v0.1.6 Latest Latest
Warning

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

Go to latest
Published: Oct 5, 2025 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ChatEvent

type ChatEvent struct {
	Event string `json:"event"          yaml:"event"`
	Data  any    `json:"data,omitempty" yaml:"data,omitempty"`
}

ChatEvent represents a single server-sent event emitted by the Doctor Who agent API.

type Result

type Result struct {
	Prompt   string      `json:"prompt"   yaml:"prompt"`
	Response string      `json:"response" yaml:"response"`
	Events   []ChatEvent `json:"events"   yaml:"events"`
}

Result captures the aggregated chat response and all underlying events.

func Chat

func Chat(ctx context.Context, client *http.Client, baseURL, token, prompt string) (*Result, error)

Chat executes a stateless prompt against the Doctor Who agent.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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