A-yum1 commited on
Commit
917a40d
·
1 Parent(s): 0dbd483

Update talk_detail.js

Browse files
__pycache__/transcription.cpython-310.pyc CHANGED
Binary files a/__pycache__/transcription.cpython-310.pyc and b/__pycache__/transcription.cpython-310.pyc differ
 
app.py CHANGED
@@ -149,8 +149,7 @@ def analyze():
149
  try:
150
  if not total_audio:
151
  return jsonify({"error": "No audio segments provided"}), 400
152
- audio_directory = transcripter.merge_segments(total_audio, '/tmp/data/transcription_audio')
153
- transcription_text = transcripter.create_transcription(audio_directory)
154
  except Exception as e:
155
  return jsonify({"error": str(e)}), 500
156
 
 
149
  try:
150
  if not total_audio:
151
  return jsonify({"error": "No audio segments provided"}), 400
152
+ transcription_text = transcripter.create_transcription(total_audio)
 
153
  except Exception as e:
154
  return jsonify({"error": str(e)}), 500
155
 
static/talk_detail.js CHANGED
@@ -14,7 +14,7 @@ async function displayTranscription() {
14
  throw new Error("会話データが見つかりませんでした。");
15
  }
16
 
17
- transcriptionElement.textContent = conversations;
18
  loader.style.display = "none";
19
  console.log(conversations);
20
  } catch (error) {
 
14
  throw new Error("会話データが見つかりませんでした。");
15
  }
16
 
17
+ transcriptionElement.innerHTML = conversations;
18
  loader.style.display = "none";
19
  console.log(conversations);
20
  } catch (error) {
transcription.py CHANGED
@@ -54,7 +54,7 @@ class TranscriptionMaker():
54
  # 無音ならスキップ
55
  if not combined_text:
56
  continue
57
- conversation.append(f"{speaker}: {combined_text}")
58
 
59
  #ファイルの書き込み。ファイル名は"transcription.txt"
60
  output_file=os.path.join(self.output_dir,"transcription.txt")
 
54
  # 無音ならスキップ
55
  if not combined_text:
56
  continue
57
+ conversation.append(f"{speaker}: {combined_text}<br>")
58
 
59
  #ファイルの書き込み。ファイル名は"transcription.txt"
60
  output_file=os.path.join(self.output_dir,"transcription.txt")