Skip to content

Commit

Permalink
Merge pull request #6 from bobqianic/fix-binding
Browse files Browse the repository at this point in the history
Fix binding
  • Loading branch information
bobqianic authored Feb 5, 2024
2 parents b3305eb + 4cc4b89 commit 9fbe59f
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 19 deletions.
4 changes: 0 additions & 4 deletions bindings/go/params.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,6 @@ func (p *Params) SetTranslate(v bool) {
p.translate = toBool(v)
}

func (p *Params) SetSplitOnWord(v bool) {
p.split_on_word = toBool(v)
}

func (p *Params) SetNoContext(v bool) {
p.no_context = toBool(v)
}
Expand Down
8 changes: 0 additions & 8 deletions bindings/ruby/ext/ruby_whisper.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -305,12 +305,6 @@ static VALUE ruby_whisper_params_get_token_timestamps(VALUE self) {
static VALUE ruby_whisper_params_set_token_timestamps(VALUE self, VALUE value) {
BOOL_PARAMS_SETTER(self, token_timestamps, value)
}
static VALUE ruby_whisper_params_get_split_on_word(VALUE self) {
BOOL_PARAMS_GETTER(self, split_on_word)
}
static VALUE ruby_whisper_params_set_split_on_word(VALUE self, VALUE value) {
BOOL_PARAMS_SETTER(self, split_on_word, value)
}
static VALUE ruby_whisper_params_get_speed_up(VALUE self) {
BOOL_PARAMS_GETTER(self, speed_up)
}
Expand Down Expand Up @@ -406,8 +400,6 @@ void Init_whisper() {
rb_define_method(cParams, "suppress_non_speech_tokens=", ruby_whisper_params_set_suppress_non_speech_tokens, 1);
rb_define_method(cParams, "token_timestamps", ruby_whisper_params_get_token_timestamps, 0);
rb_define_method(cParams, "token_timestamps=", ruby_whisper_params_set_token_timestamps, 1);
rb_define_method(cParams, "split_on_word", ruby_whisper_params_get_split_on_word, 0);
rb_define_method(cParams, "split_on_word=", ruby_whisper_params_set_split_on_word, 1);
rb_define_method(cParams, "speed_up", ruby_whisper_params_get_speed_up, 0);
rb_define_method(cParams, "speed_up=", ruby_whisper_params_set_speed_up, 1);
rb_define_method(cParams, "diarize", ruby_whisper_params_get_diarize, 0);
Expand Down
7 changes: 0 additions & 7 deletions bindings/ruby/tests/test_whisper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -110,13 +110,6 @@ def test_token_timestamps
assert !@params.token_timestamps
end

def test_split_on_word
@params.split_on_word = true
assert @params.split_on_word
@params.split_on_word = false
assert !@params.split_on_word
end

def test_speed_up
@params.speed_up = true
assert @params.speed_up
Expand Down

0 comments on commit 9fbe59f

Please sign in to comment.