Browse Source

Add download catalog for speech to text

pull/1395/head
Hironsan 3 years ago
parent
commit
17350dba8a
2 changed files with 13 additions and 1 deletions
  1. 5
      backend/api/views/download/catalog.py
  2. 9
      backend/api/views/download/examples.py

5
backend/api/views/download/catalog.py

@ -5,7 +5,7 @@ from pydantic import BaseModel
from typing_extensions import Literal
from ...models import (DOCUMENT_CLASSIFICATION, IMAGE_CLASSIFICATION, SEQ2SEQ,
SEQUENCE_LABELING)
SEQUENCE_LABELING, SPEECH2TEXT)
from . import examples
@ -86,3 +86,6 @@ Options.register(SEQ2SEQ, JSONL, OptionNone, examples.Text_JSONL)
# Image Classification
Options.register(IMAGE_CLASSIFICATION, JSONL, OptionNone, examples.CategoryImageClassification)
# Speech to Text
Options.register(SPEECH2TEXT, JSONL, OptionNone, examples.Speech2Text)

9
backend/api/views/download/examples.py

@ -62,3 +62,12 @@ CategoryImageClassification = """
}
]
"""
Speech2Text = """
[
{
"filename": "20210514.mp3",
"label": ["Lorem ipsum dolor sit amet"]
}
]
"""
Loading…
Cancel
Save