google

package
v0.0.29 Latest Latest
Warning

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

Go to latest
Published: Jun 11, 2026 License: MIT Imports: 20 Imported by: 0

Documentation

Index

Constants

View Source
const (
	PluginTitle   = "rtp-agent.plugins.google"
	PluginVersion = "1.5.15"
	PluginPackage = "rtp-agent.plugins.google"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type GoogleLLM

type GoogleLLM struct {
	// contains filtered or unexported fields
}

func NewGoogleLLM

func NewGoogleLLM(apiKey string, model string) (*GoogleLLM, error)

func (*GoogleLLM) Chat

func (l *GoogleLLM) Chat(ctx context.Context, chatCtx *llm.ChatContext, opts ...llm.ChatOption) (llm.LLMStream, error)

func (*GoogleLLM) Model added in v0.0.15

func (l *GoogleLLM) Model() string

func (*GoogleLLM) Provider added in v0.0.15

func (l *GoogleLLM) Provider() string

type GoogleSTT

type GoogleSTT struct {
	// contains filtered or unexported fields
}

func NewGoogleSTT

func NewGoogleSTT(credentialsFile string, providerOpts ...GoogleSTTOption) (*GoogleSTT, error)

NewGoogleSTT creates a new STT client using Application Default Credentials, or by providing a path to a credentials JSON file.

func (*GoogleSTT) Capabilities

func (s *GoogleSTT) Capabilities() stt.STTCapabilities

func (*GoogleSTT) Label

func (s *GoogleSTT) Label() string

func (*GoogleSTT) Recognize

func (s *GoogleSTT) Recognize(ctx context.Context, frames []*model.AudioFrame, language string) (*stt.SpeechEvent, error)

func (*GoogleSTT) Stream

func (s *GoogleSTT) Stream(ctx context.Context, language string) (stt.RecognizeStream, error)

type GoogleSTTOption added in v0.0.15

type GoogleSTTOption func(*GoogleSTT)

func WithGoogleSTTModel added in v0.0.15

func WithGoogleSTTModel(model string) GoogleSTTOption

func WithGoogleSTTProfanityFilter added in v0.0.15

func WithGoogleSTTProfanityFilter(profanityFilter bool) GoogleSTTOption

func WithGoogleSTTPunctuate added in v0.0.15

func WithGoogleSTTPunctuate(punctuate bool) GoogleSTTOption

func WithGoogleSTTSampleRate added in v0.0.15

func WithGoogleSTTSampleRate(sampleRate int32) GoogleSTTOption

func WithGoogleSTTSpokenPunctuation added in v0.0.15

func WithGoogleSTTSpokenPunctuation(spokenPunctuation bool) GoogleSTTOption

type GoogleTTS

type GoogleTTS struct {
	// contains filtered or unexported fields
}

func NewGoogleTTS

func NewGoogleTTS(credentialsFile string, ttsOpts ...GoogleTTSOption) (*GoogleTTS, error)

NewGoogleTTS creates a new TTS client using Application Default Credentials, or by providing a path to a credentials JSON file.

func (*GoogleTTS) Capabilities

func (t *GoogleTTS) Capabilities() tts.TTSCapabilities

func (*GoogleTTS) Label

func (t *GoogleTTS) Label() string

func (*GoogleTTS) NumChannels

func (t *GoogleTTS) NumChannels() int

func (*GoogleTTS) SampleRate

func (t *GoogleTTS) SampleRate() int

func (*GoogleTTS) Stream

func (t *GoogleTTS) Stream(ctx context.Context) (tts.SynthesizeStream, error)

func (*GoogleTTS) Synthesize

func (t *GoogleTTS) Synthesize(ctx context.Context, text string) (tts.ChunkedStream, error)

type GoogleTTSOption added in v0.0.15

type GoogleTTSOption func(*googleTTSConfig)

func WithGoogleTTSLanguage added in v0.0.15

func WithGoogleTTSLanguage(language string) GoogleTTSOption

func WithGoogleTTSModel added in v0.0.15

func WithGoogleTTSModel(model string) GoogleTTSOption

func WithGoogleTTSVoice added in v0.0.15

func WithGoogleTTSVoice(voice string) GoogleTTSOption

Jump to

Keyboard shortcuts

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