akabe / obs-transcript Goto Github PK
View Code? Open in Web Editor NEWReal-time subtitle generation by speech recognition for OBS Studio
Home Page: https://akabe.github.io/obs-transcript
License: MIT License
Real-time subtitle generation by speech recognition for OBS Studio
Home Page: https://akabe.github.io/obs-transcript
License: MIT License
(suggestion)
Is this possible?
Firstly disclaimer, as I am not very familiar with js I have used chatGPT to try to make sure I have all the information you may need. Hope it worked ok haha!
Description:
I encountered an Uncaught TypeError in the FormatModel.js file while using the library in a specific context. The error occurs within the onresult callback of the SpeechRecognitionModel.js file. Here are the details:
Error Message:
Uncaught TypeError: Cannot read properties of undefined (reading 'length')
at _default.splitlines (FormatModel.js:37:18)
at FormatModel.js:7:38
at Array.map (<anonymous>)
at _default.format (FormatModel.js:7:24)
at HomeModel.js:59:45
at _this.engine.onresult (SpeechRecognitionModel.js:38:11)
Reproduction Steps:
Use the following code to reproduce the issue in the console:
// Example usage to reproduce the issue
const formatter = new FormatModel();
const formattedText = formatter.format([" nothing nothing's working here"], 5, 80);
console.log(formattedText);
Additional Information:
The strs parameter in the format method is expected to be an array.
The error seems to be related to the input data or the context in which the FormatModel is being used.
The issue is not reproduced with the provided example code, but it occurs within the onresult callback of the SpeechRecognitionModel.js file.
Possible Suggestions:
Add additional logging in the splitlines method to identify the values causing the issue.
Check the input array strs in the format method to ensure it contains valid strings.
Environment Information:
Chrome Version 120.0.6099.71 (Official Build) (64-bit)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.