bbc/dialogger

Name: dialogger

Owner: BBC

Description: Text-based media editing interface

Created: 2017-07-17 16:49:24.0

Updated: 2017-12-20 04:02:01.0

Pushed: 2017-08-09 11:56:24.0

Homepage: null

Size: 1973

Language: JavaScript

GitHub Committers

UserMost Recent Commit# Commits

Other Committers

UserEmailMost Recent Commit# Commits

README

Dialogger

Dialogger is an audio/video editor that allows you to navigate and edit recordings using a text-based interface.

What's included
What's not included

The following features must be added manually for Dialogger to operate fully. Instructions and examples are provided.


Conceptual flow diagram (excluded features shown in red)

Technology stack
Front-end Back-end
Installation
Using Docker (recommended)
git clone https://github.com/bbc/dialogger.git && cd dialogger
docker-compose build
docker-compose up

Navigate to http://localhost:8080 and log in with username user and password password.

Ubuntu/Debian
git clone https://github.com/bbc/dialogger.git && cd dialogger
curl -sL https://deb.nodesource.com/setup_6.x | sudo -E bash -
sudo -E apt-get install -y nodejs mediainfo mongodb
sudo -E npm install -g gulp bower bunyan
npm install
npm run build
(cd data && ./import.sh)

In config/consts.js, set the following parameters:

Run Dialogger using npm start, then log in with username user and password password.

Configuration

Dialogger does not include the following key functionality, so you must add this in manually. Instructions on how to add this are provided below.

  1. Speech-to-text
  2. Preview file generator
  3. File export
1. Speech-to-text

Dialogger does not come with a speech-to-text system, so you will need to add some code to helpers/stt.js that accepts a path to an audio/video file and returns the transcript and segmentation data. Examples of the data formats are shown below, and an example can be found in helpers/stt-example.js.

Transcript format

rds: [
{
  word: "hello",
  punct: "Hello",
  start: 0.05,
  end: 0.78,
  confidence: 0.45
},
{
  word: "world",
  punct: "world.",
  start: 1.13,
  end: 1.45,
  confidence: 0.9
}


Segments format

gments: [
{
  start: 0.05,
  duration: 2.34,
  speaker: {
    @id: "Bob",
    gender: "M"
  }
},
{
  start: 2.34,
  duration: 4.2,
  speaker: {
  @id: "Alice",
    gender: "F"
  }
}


2. Preview file generator

Preview files are low-bitrate versions of media files which are used for playback in the browser interface. To configure preview file generation, you will need to add some code to helpers/previewfile.js. The function should receive options in the following format, create a preview file and run the callback function.

Options format

putPath: "/path/to/input/file",
tputPath: "/path/to/preview/version",
rmat: "audio",  // can be audio or video
dio: {
acodec: "aac",
ab: "128k"
   

3. File export

File export allows users to download an edited version of their media. To configure file export, you will need to add some code to helpers/fileexport.js. The function should receive options in the following format and return the path of the edited file. In essence, what you want to do is to take the file path (asset.path) and the list of edits (edl), produce an edited version of the file, then return the path.

Options format

 Information about the original file/asset
set: {
description: "Asset description",
filename: "AssetFilename.wav",
path: "/path/to/original/file",
audio: {
  channels: 2,
  sampleRate: "48000"
}


 An array of in- and out-points, in seconds
l: [
["78.38","102.89"],
["128.3","135.17"]


 User-provided options from the exportForm
   in public/js/editor.html
ttings: {
audio: {
  ab: "",
  acodec: "pcm_s16le"
},
edlformat: "dira",
exportUnderlined:"true",
format: "audio",
id: "",
include: "true",
name: "test.wav",
video: {
  height: "",
  vb: "",
  f: "mp4",
  acodec: "aac",
  ab: "",
  vcodec: "libx264",
  width: ""
}


Issues/development

Please report any problems or make feature requests by raising an issue. Pull requests are also welcome.

Authors

This work is supported by the National Institutes of Health's National Center for Advancing Translational Sciences, Grant Number U24TR002306. This work is solely the responsibility of the creators and does not necessarily represent the official views of the National Institutes of Health.