Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AmazonTranslate ¶ added in v0.0.100
type AmazonTranslate struct {
// contains filtered or unexported fields
}
AmazonTranslate is a transformer that uses Amazon Translate to translate text in documents to a target language.
func NewAmazonTranslate ¶ added in v0.0.100
func NewAmazonTranslate(client AmazonTranslateClient, targetLanguageCode string, optFns ...func(o *AmazonTranslateOptions)) *AmazonTranslate
NewAmazonTranslate creates a new instance of the AmazonTranslate transformer.
type AmazonTranslateClient ¶ added in v0.0.100
type AmazonTranslateClient interface {
TranslateText(ctx context.Context, params *translate.TranslateTextInput, optFns ...func(*translate.Options)) (*translate.TranslateTextOutput, error)
}
AmazonTranslateClient is an interface for the Amazon Translate client.
type AmazonTranslateOptions ¶ added in v0.0.100
type AmazonTranslateOptions struct { // MaxConcurrency sets the maximum number of concurrent translation requests. MaxConcurrency int // SourceLanguageCode sets the source language code for translation. Default is "auto". SourceLanguageCode string // IncludeSourceText indicates whether to include the source text in document metadata. IncludeSourceText bool }
AmazonTranslateOptions contains options for configuring the AmazonTranslate transformer.
type MetaDataTagger ¶
type MetaDataTagger struct {
// contains filtered or unexported fields
}
MetaDataTagger is a document transformer that adds metadata to documents using a tagging chain.
func NewMetaDataTagger ¶
func NewMetaDataTagger(chatModel schema.ChatModel, tags any, optFns ...func(o *MetaDataTaggerOptions)) (*MetaDataTagger, error)
NewMetaDataTagger creates a new MetaDataTagger instance.
type MetaDataTaggerOptions ¶
type MetaDataTaggerOptions struct {
MaxConcurrency int
}
MetaDataTaggerOptions represents the options for the MetaDataTagger.
Click to show internal directories.
Click to hide internal directories.