diff --git a/bricks/input.js b/bricks/input.js index 9d66bcf..05e6804 100644 --- a/bricks/input.js +++ b/bricks/input.js @@ -1098,7 +1098,7 @@ bricks.UiVideo =class extends bricks.UiStr { url: bricks_resource('imgs/right_arrow.svg')}); this.add_widget(this.icon); this.icon.bind('click', this.play_audio.bind(this)); - this.player = new bricks.VideoPlayer({ + this.player = new bricks.Video({ url:this.value }); if (this.autoplay){ diff --git a/bricks/llm.js b/bricks/llm.js index 39f8144..42323f4 100644 --- a/bricks/llm.js +++ b/bricks/llm.js @@ -120,15 +120,6 @@ bricks.ModelOutput = class extends bricks.VBox { this.received_reasoning_content = ''; this.run.stop_timepass(); this.content.remove_widget(this.run); - if(this.textvoice){ - this.upstreaming = new bricks.UpStreaming({ - url:this.tts_url - }); - this.upstreaming.go(); - } - } - if (this.upstreaming){ - this.upstreaming.send(data.content); } this.run = null; this.filler.clear_widgets(); @@ -169,9 +160,7 @@ bricks.ModelOutput = class extends bricks.VBox { } } finish(){ - if (this.upstreaming){ - this.upstreaming.finish(); - } + console.log('finished') } } @@ -272,9 +261,12 @@ bricks.LlmModel = class extends bricks.JsWidget { console.log(l, 'is not a json data'); return } - if (this.opts.response_mode == 'async' && d.status != 'SUCCESSED'){ - return; + if (this.opts.response_mode == 'async'){ + if(d.status != 'SUCCESSED'){ + return; + } } + console.log('l=', l, 'd=', d); mout.update_data(d); } chunk_ended(){ diff --git a/bricks/qaframe.js b/bricks/qaframe.js index f7e1907..4966408 100644 --- a/bricks/qaframe.js +++ b/bricks/qaframe.js @@ -105,7 +105,7 @@ bricks.QAFrame = class extends bricks.VBox { console.log('show_courseware(), d=', d); switch(d.type){ case 'video': - w = new bricks.VideoPlayer({ + w = new bricks.Video({ width:'100%', height:'100%', url:d.url,