Skip to content
Snippets Groups Projects

Store Transcriptions in local cache

Merged Eva Bardou requested to merge cache-transcriptions into master
2 files
+ 103
12
Compare changes
  • Side-by-side
  • Inline
Files
2
+ 1
2
@@ -700,7 +700,6 @@ class ElementsWorker(BaseWorker):
transcription = transcriptions[index]
element_id_hex = convert_str_uuid_to_hex(annotation["id"])
if annotation["created"] and annotation["id"] not in created_ids:
# TODO: Retrieve real element_name through API
elements_to_insert.append(
CachedElement(
id=element_id_hex,
@@ -715,7 +714,7 @@ class ElementsWorker(BaseWorker):
transcriptions_to_insert.append(
CachedTranscription(
# TODO: Retrieve real transcription_id through API
id=convert_str_uuid_to_hex(uuid.uuid4()),
id=convert_str_uuid_to_hex(str(uuid.uuid4())),
element_id=element_id_hex,
text=transcription["text"],
confidence=transcription["score"],
Loading