mirror of
https://github.com/bellingcat/whisperbox-transcribe.git
synced 2026-06-07 19:18:35 +03:00
26 lines
759 B
Python
26 lines
759 B
Python
from pydantic import AnyHttpUrl, BaseModel, Field
|
|
|
|
import app.shared.db.models as models
|
|
|
|
|
|
class PostJobPayload(BaseModel):
|
|
url: AnyHttpUrl = Field(
|
|
description=(
|
|
"URL where the media file is available. This needs to be a direct link."
|
|
)
|
|
)
|
|
|
|
type: models.JobType = Field(
|
|
description="""Type of this job.
|
|
`transcript` uses the original language of the audio.
|
|
`translation` creates an automatic translation to english.
|
|
`language_detection` detects language from the first 30 seconds of audio."""
|
|
)
|
|
|
|
language: str | None = Field(
|
|
description=(
|
|
"Spoken language in the media file. "
|
|
"While optional, this can improve output when set."
|
|
)
|
|
)
|