Class: Whisper::Token

Inherits:
Object
  • Object
show all
Defined in:
sig/whisper.rbs

Instance Method Summary collapse

Instance Method Details

#deconstruct_keys ⇒ deconstructed_keys

Parameters:

  • (Array[:id | :tid | :probability | :log_probability | :pt | :ptsum | :t_dtw | :voice_length | :start_time | :end_time | :text], nil)

Returns:

  • (deconstructed_keys)


611
# File 'sig/whisper.rbs', line 611

def deconstruct_keys: (Array[:id | :tid | :probability | :log_probability | :pt | :ptsum | :t_dtw | :voice_length | :start_time | :end_time | :text] | nil) -> deconstructed_keys

#end_time ⇒ Integer

End time of the token.

Token-level timestamp data. Do not use if you haven't computed token-level timestamps.

Returns:

  • (Integer)


606
# File 'sig/whisper.rbs', line 606

def end_time: () -> Integer

#id ⇒ Integer

Token ID.

Returns:

  • (Integer)


561
# File 'sig/whisper.rbs', line 561

def id: () -> Integer

#log_probability ⇒ Float

Log probability of the token.

Returns:

  • (Float)


573
# File 'sig/whisper.rbs', line 573

def log_probability: () -> Float

#probability ⇒ Float

Probability of the token.

Returns:

  • (Float)


569
# File 'sig/whisper.rbs', line 569

def probability: () -> Float

#pt ⇒ Float

Probability of the timestamp token.

Returns:

  • (Float)


577
# File 'sig/whisper.rbs', line 577

def pt: () -> Float

#ptsum ⇒ Float

Sum of probability of all timestamp tokens.

Returns:

  • (Float)


581
# File 'sig/whisper.rbs', line 581

def ptsum: () -> Float

#start_time ⇒ Integer

Start time of the token.

Token-level timestamp data. Do not use if you haven't computed token-level timestamps.

Returns:

  • (Integer)


599
# File 'sig/whisper.rbs', line 599

def start_time: () -> Integer

#t_dtw ⇒ Integer

[EXPERIMENTAL] Token-level timestamps with DTW

Do not use if you haven't computed token-level timestamps with dtw. Roughly corresponds to the moment in audio in which the token was output.

Returns:

  • (Integer)


588
# File 'sig/whisper.rbs', line 588

def t_dtw: () -> Integer

#text ⇒ String

Get the token text of the token.

Returns:

  • (String)


610
# File 'sig/whisper.rbs', line 610

def text: () -> String

#tid ⇒ Integer

Forced timestamp token ID.

Returns:

  • (Integer)


565
# File 'sig/whisper.rbs', line 565

def tid: () -> Integer

#voice_length ⇒ Float

Voice length of the token.

Returns:

  • (Float)


592
# File 'sig/whisper.rbs', line 592

def voice_length: () -> Float