request

package
v1.1.15 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetTestUser

func GetTestUser() string

GetTestUser is used for testing when there is no full request object.

Types

type AudioData

type AudioData struct {
	BibleBrain BibleBrainAudio `yaml:"bible_brain,omitempty"`
	File       string          `yaml:"file,omitempty"`
	AWSS3      string          `yaml:"aws_s3,omitempty"`
	POST       string          `yaml:"post,omitempty"`
	NoAudio    bool            `yaml:"no_audio,omitempty"`
}

func (AudioData) AnyBibleBrain

func (a AudioData) AnyBibleBrain() bool

type AudioEncoding

type AudioEncoding struct {
	MFCC       bool `yaml:"mfcc,omitempty"`
	NoEncoding bool `yaml:"no_encoding,omitempty"`
}

type AudioProof

type AudioProof struct {
	HTMLReport  bool   `yaml:"html_report,omitempty"`
	BaseDataset string `yaml:"base_dataset,omitempty"`
}

type BibleBrainAudio

type BibleBrainAudio struct {
	MP3_64      bool   `yaml:"mp3_64,omitempty"`
	MP3_16      bool   `yaml:"mp3_16,omitempty"`
	OPUS        bool   `yaml:"opus,omitempty"`
	SetTypeCode string `yaml:"set_type_code,omitempty"`
}

func (BibleBrainAudio) AudioType

func (b BibleBrainAudio) AudioType() (string, string)

type BibleBrainText

type BibleBrainText struct {
	TextUSXEdit   bool `yaml:"text_usx_edit,omitempty"`
	TextPlainEdit bool `yaml:"text_plain_edit,omitempty"`
	TextPlain     bool `yaml:"text_plain,omitempty"`
}

func (BibleBrainText) TextType

func (b BibleBrainText) TextType() MediaType

type Compare

type Compare struct {
	HTMLReport      bool            `yaml:"html_report,omitempty"`
	BaseDataset     string          `yaml:"base_dataset,omitempty"`
	GordonFilter    int             `yaml:"gordon_filter,omitempty"`
	CompareSettings CompareSettings `yaml:"compare_settings,omitempty"`
}

type CompareChoice

type CompareChoice struct {
	Remove    bool `yaml:"remove,omitempty"`
	Normalize bool `yaml:"normalize,omitempty"`
}

type CompareSettings

type CompareSettings struct {
	LowerCase         bool              `yaml:"lower_case,omitempty"`
	RemovePromptChars bool              `yaml:"remove_prompt_chars,omitempty"`
	RemovePunctuation bool              `yaml:"remove_punctuation,omitempty"`
	DoubleQuotes      CompareChoice     `yaml:"double_quotes,omitempty"`
	Apostrophe        CompareChoice     `yaml:"apostrophe,omitempty"`
	Hyphen            CompareChoice     `yaml:"hyphen,omitempty"`
	DiacriticalMarks  DiacriticalChoice `yaml:"diacritical_marks,omitempty"`
}

type Database

type Database struct {
	AWSS3 string `yaml:"aws_s3,omitempty"`
	File  string `yaml:"file,omitempty"`
}

type Detail

type Detail struct {
	Lines  bool `yaml:"lines,omitempty"`
	Verses bool `yaml:"verses,omitempty"`
	Words  bool `yaml:"words,omitempty"`
}

type DiacriticalChoice

type DiacriticalChoice struct {
	Remove        bool `yaml:"remove,omitempty"`
	NormalizeNFC  bool `yaml:"normalize_nfc,omitempty"`
	NormalizeNFD  bool `yaml:"normalize_nfd,omitempty"`
	NormalizeNFKC bool `yaml:"normalize_nfkc,omitempty"`
	NormalizeNFKD bool `yaml:"normalize_nfkd,omitempty"`
}

type MMSAdapter

type MMSAdapter struct {
	BatchMB      int     `yaml:"batch_mb,omitempty"`
	NumEpochs    int     `yaml:"num_epochs,omitempty"`
	LearningRate float64 `yaml:"learning_rate,omitempty"`
	WarmupPct    float64 `yaml:"warmup_pct,omitempty"`
	GradNormMax  float64 `yaml:"grad_norm_max,omitempty"`
}

type MediaType

type MediaType string
const (
	Audio         MediaType = "audio"
	AudioDrama    MediaType = "audio_drama"
	TextUSXEdit   MediaType = "text_usx_edit"
	TextUSFMEdit  MediaType = "text_usfm_edit"
	TextPlainEdit MediaType = "text_plain_edit"
	TextPlain     MediaType = "text_plain"
	TextScript    MediaType = "text_script"
	TextCSV       MediaType = "text_csv"
	TextSTT       MediaType = "text_stt"
	TextNone      MediaType = ""
)

func (MediaType) IsFrom

func (t MediaType) IsFrom(ttype string) bool

type Output

type Output struct {
	Directory string `yaml:"directory"`
	CSV       bool   `yaml:"csv,omitempty"`
	JSON      bool   `yaml:"json,omitempty"`
	Sqlite    bool   `yaml:"sqlite,omitempty"`
}

type Request

type Request struct {
	IsNew         bool          `yaml:"is_new"`
	DatasetName   string        `yaml:"dataset_name"`
	Username      string        `yaml:"username"`
	BibleId       string        `yaml:"bible_id"`
	LanguageISO   string        `yaml:"language_iso"`
	AltLanguage   string        `yaml:"alt_language,omitempty"`
	Priority      int           `yaml:"priority,omitempty"`
	NotifyOk      []string      `yaml:"notify_ok"`
	NotifyErr     []string      `yaml:"notify_err"`
	Output        Output        `yaml:"output,omitempty"`
	Testament     Testament     `yaml:"testament,omitempty"`
	Database      Database      `yaml:"database,omitempty"`
	AudioData     AudioData     `yaml:"audio_data,omitempty"`
	TextData      TextData      `yaml:"text_data,omitempty"`
	SheetColumns  SheetColumns  `yaml:"sheet_columns,omitempty"`
	Timestamps    Timestamps    `yaml:"timestamps,omitempty"`
	Training      Training      `yaml:"training,omitempty"`
	SpeechToText  SpeechToText  `yaml:"speech_to_text,omitempty"`
	STTDecoder    STTDecoder    `yaml:"stt_decoder,omitempty"`
	Detail        Detail        `yaml:"detail,omitempty"`
	AudioEncoding AudioEncoding `yaml:"audio_encoding,omitempty"`
	TextEncoding  TextEncoding  `yaml:"text_encoding,omitempty"`
	AudioProof    AudioProof    `yaml:"audio_proof,omitempty"`
	Compare       Compare       `yaml:"compare,omitempty"`
	UpdateDBP     UpdateDBP     `yaml:"update_dbp,omitempty"`
}

type STTDecoder

type STTDecoder struct {
	Greedy       bool `yaml:"greedy,omitempty"`
	Simple       bool `yaml:"simple,omitempty"`
	Hotwords     bool `yaml:"hotwords,omitempty"`
	Kenlm        bool `yaml:"kenlm,omitempty"`
	NoSTTDecoder bool `yaml:"no_stt_decoder,omitempty"`
}

func (STTDecoder) String

func (d STTDecoder) String() string

type SheetColumns

type SheetColumns struct {
	BookCol      int `yaml:"book_col,omitempty"`
	ChapterCol   int `yaml:"chapter_col,omitempty"`
	VerseCol     int `yaml:"verse_col,omitempty"`
	CharacterCol int `yaml:"character_col,omitempty"`
	ActorCol     int `yaml:"actor_col,omitempty"`
	LineCol      int `yaml:"line_col,omitempty"`
	TextCol      int `yaml:"text_col,omitempty"`
}

func (SheetColumns) IsSet

func (c SheetColumns) IsSet() bool

type SpeechToText

type SpeechToText struct {
	MMS            bool    `yaml:"mms_asr,omitempty"`
	MMSAdapter     bool    `yaml:"adapter_asr,omitempty"`
	Wav2Vec2ASR    bool    `yaml:"wav2vec2_asr,omitempty"`
	Whisper        Whisper `yaml:"whisper,omitempty"`
	MMSASRAlign    bool    `yaml:"mms_asr_align,omitempty"`
	NoSpeechToText bool    `yaml:"no_speech_to_text,omitempty"`
}

type Testament

type Testament struct {
	NT      bool     `yaml:"nt,omitempty"`
	NTBooks []string `yaml:"nt_books,omitempty"`
	OT      bool     `yaml:"ot,omitempty"`
	OTBooks []string `yaml:"ot_books,omitempty"`
	// contains filtered or unexported fields
}

func (*Testament) BuildBookMaps

func (t *Testament) BuildBookMaps()

func (*Testament) Has

func (t *Testament) Has(ttype string, bookId string) bool

func (*Testament) HasNT

func (t *Testament) HasNT(bookId string) bool

func (*Testament) HasOT

func (t *Testament) HasOT(bookId string) bool

type TextData

type TextData struct {
	BibleBrain BibleBrainText `yaml:"bible_brain,omitempty"`
	File       string         `yaml:"file,omitempty"`
	AWSS3      string         `yaml:"aws_s3,omitempty"`
	POST       string         `yaml:"post,omitempty"`
	NoText     bool           `yaml:"no_text,omitempty"`
}

func (TextData) AnyBibleBrain

func (t TextData) AnyBibleBrain() bool

type TextEncoding

type TextEncoding struct {
	FastText   bool `yaml:"fast_text,omitempty"`
	NoEncoding bool `yaml:"no_encoding,omitempty"`
}

type Timestamps

type Timestamps struct {
	BibleBrain   bool `yaml:"bible_brain,omitempty"`
	Aeneas       bool `yaml:"aeneas,omitempty"`
	TSBucket     bool `yaml:"ts_bucket,omitempty"`
	MMSFAVerse   bool `yaml:"mms_fa_verse,omitempty"`
	MMSAlign     bool `yaml:"mms_align,omitempty"`
	NoTimestamps bool `yaml:"no_timestamps,omitempty"`
}

type Training

type Training struct {
	RedoTraining bool       `yaml:"redo_training,omitempty"`
	MMSAdapter   MMSAdapter `yaml:"mms_adapter,omitempty"`
	Wav2Vec2Word Wav2Vec2   `yaml:"wav2vec2_word,omitempty"`
	NoTraining   bool       `yaml:"no_training,omitempty"`
}

type UpdateDBP

type UpdateDBP struct {
	Timestamps         string `yaml:"timestamps,omitempty"`
	HLS                string `yaml:"hls,omitempty"`
	CopyTimestampsFrom string `yaml:"copy_timestamps_from,omitempty"`
}

type Wav2Vec2

type Wav2Vec2 struct {
	BatchMB      int     `yaml:"batch_mb,omitempty"`
	NumEpochs    int     `yaml:"num_epochs,omitempty"`
	LearningRate float64 `yaml:"learning_rate,omitempty"`
	WarmupPct    float64 `yaml:"warmup_pct,omitempty"`
	GradNormMax  float64 `yaml:"grad_norm_max,omitempty"`
	MinAudioSec  float64 `yaml:"min_audio_sec,omitempty"`
}

type Whisper

type Whisper struct {
	Model WhisperModel `yaml:"model,omitempty"`
}

type WhisperModel

type WhisperModel struct {
	Large  bool `yaml:"large,omitempty"`
	Medium bool `yaml:"medium,omitempty"`
	Small  bool `yaml:"small,omitempty"`
	Base   bool `yaml:"base,omitempty"`
	Tiny   bool `yaml:"tiny,omitempty"`
}

func (WhisperModel) String

func (w WhisperModel) String() string

Jump to

Keyboard shortcuts

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