Neidio i'r cynnwys

Maya · Batch

Integreiddio

ID y model maya/batch
# Run the model; wait up to 20 s for the finished result in the same call
curl -X POST "https://api.doitong.com/v1/run/maya/batch?wait=20" \
  -H "Authorization: Bearer $DOITONG_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "texts": [
      "Hello from Doitong. This is a short test sentence."
    ],
    "prompts": [
      "Hello from Doitong. This is a short test sentence."
    ]
  }'

# Still "queued" or "running"? Poll with the id from the response:
curl "https://api.doitong.com/v1/requests/REQUEST_ID?wait=20" \
  -H "Authorization: Bearer $DOITONG_API_KEY"

Y cais hwn: ≈$0.049 49 o gredydau API Ei redeg ar y dudalen hon

Cael allwedd API
Maya Research Testun i Leferydd #text-to-speech#tts

Fersiwn swp o leferydd Maya sy'n rendro hyd at 100 testun gyda disgrifiadau llais cyfatebol

Maya Research · Sain

Mae eich canlyniad cyntaf yn mynd yma

Adeiladwch gais isod a'i redeg gyda'ch allwedd API. Mae allbynnau'n cael eu copïo i'n storio, wedi'u cadw am byth neu am 7 diwrnod am ddim.

Adeiladu cais

Cynhyrchir rheolyddion o sgema'r model. Mae'r cod a'r pris yn diweddaru wrth i chi eu newid.

•gofynnol

Rhestr testun synthesis lleferydd gyda chefnogaeth i dagiau <emotion_name> wedi'u mewnblannu ym mhob cofnod.

•gofynnol

Priodoleddau llais neu gymeriad ar gyfer pob testun, wedi'u darparu fel rhestr o ddisgrifiadau. Rhaid i nifer y disgrifiadau fod yn hafal i nifer y testunau.

Uwch sample_rate · output_format · temperature · top_p · max_tokens · repetition_penalty · enable_safety_checker
sample_rate rhagosodedig 48 kHz

Gosodiad cyfradd samplu sain a rennir ar gyfer pob cynhyrchiad, gyda dewis rhwng prosesu cyflymach ar 24 kHz ac ansawdd gwell ar 48 kHz.

output_format rhagosodedig wav

Fformat y ffeil a ddefnyddir ar gyfer pob recordiad lleferydd a gynhyrchir.

rhagosodedig 0.4

Tymheredd samplu a gymhwysir i bob cynhyrchiad.

rhagosodedig 0.9

Gosodiad samplu niwclews a gymhwysir i bob cynhyrchiad.

rhagosodedig 2000

Terfyn uchaf tocynnau SNAC ar gyfer pob cynhyrchiad.

rhagosodedig 1.1

Cosb ailadrodd a gymhwysir i bob cynhyrchiad.

POST /run/maya/batch?wait=20 dyfynbris → $0.049
# Run the model; wait up to 20 s for the finished result in the same call
curl -X POST "https://api.doitong.com/v1/run/maya/batch?wait=20" \
  -H "Authorization: Bearer $DOITONG_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "texts": [
      "Hello from Doitong. This is a short test sentence."
    ],
    "prompts": [
      "Hello from Doitong. This is a short test sentence."
    ]
  }'

# Still "queued" or "running"? Poll with the id from the response:
curl "https://api.doitong.com/v1/requests/REQUEST_ID?wait=20" \
  -H "Authorization: Bearer $DOITONG_API_KEY"

Rhedeg y cais hwn

Mae'ch allwedd yn aros yn y porwr hwn: caiff ei hanfon at Doitong API yn unig a'i chadw (localStorage) dim ond os ticiwch Cofio. Cael allwedd API

Ynglŷn â Maya · Batch

Yn syntheseiddio llawer o glipiau mewn un cais. Mae `texts` a `prompts` ill dau yn derbyn 1 i 100 cofnod a rhaid iddynt fod yr un hyd, gan baru pob testun â disgrifiad llais. Mae tagiau emosiwn yn gweithio ym mhob testun. Mae gosodiadau fel cyfradd samplu, fformat allbwn a thymheredd yn berthnasol i bawb, ac mae'r canlyniadau'n cynnwys rhestr o ffeiliau sain a hydau.

Paramedrau

EnwMath RhagosodedigCaniateir Disgrifiad
textsgofynnol
Mathstring[]
≤ 100 eitem
Rhestr testun synthesis lleferydd gyda chefnogaeth i dagiau <emotion_name> wedi'u mewnblannu ym mhob cofnod.
promptsgofynnol
Mathstring[]
≤ 100 eitem
Priodoleddau llais neu gymeriad ar gyfer pob testun, wedi'u darparu fel rhestr o ddisgrifiadau. Rhaid i nifer y disgrifiadau fod yn hafal i nifer y testunau.
temperaturedewisol
Mathnumber
Rhagosodedig0.4
0 – 2
Tymheredd samplu a gymhwysir i bob cynhyrchiad.
top_pdewisol
Mathnumber
Rhagosodedig0.9
0 – 1
Gosodiad samplu niwclews a gymhwysir i bob cynhyrchiad.
max_tokensdewisol
Mathinteger
Rhagosodedig2000
28 – 4,000
Terfyn uchaf tocynnau SNAC ar gyfer pob cynhyrchiad.
repetition_penaltydewisol
Mathnumber
Rhagosodedig1.1
1 – 2
Cosb ailadrodd a gymhwysir i bob cynhyrchiad.
sample_ratedewisol
Mathenum
Rhagosodedig48 kHz
48 kHz24 kHz
Gosodiad cyfradd samplu sain a rennir ar gyfer pob cynhyrchiad, gyda dewis rhwng prosesu cyflymach ar 24 kHz ac ansawdd gwell ar 48 kHz.
output_formatdewisol
Mathenum
Rhagosodedigwav
wavmp3
Fformat y ffeil a ddefnyddir ar gyfer pob recordiad lleferydd a gynhyrchir.
enable_safety_checkerdewisol
Mathboolean
Rhagosodedigtrue
Gellir llacio'r sgrinio drwy osod false, ar yr amod bod y galwr wedi'i awdurdodi.
gofynnol

Allbwn

GET /requests/req_8k2m4q7x1z9c3v5b6n0p2r4t
{
  "id": "req_8k2m4q7x1z9c3v5b6n0p2r4t",
  "object": "request",
  "model": "maya/batch",
  "status": "succeeded",
  "created_at": "2026-10-20T12:00:00Z",
  "started_at": "2026-10-20T12:00:02Z",
  "completed_at": "2026-10-20T12:00:09Z",
  "queue_position": null,
  "cost": {
    "credits": 49,
    "usd": "0.049",
    "charged": 49,
    "refunded": 0
  },
  "input": {
    "texts": [
      "Hello from Doitong. This is a short test sentence."
    ],
    "prompts": [
      "Hello from Doitong. This is a short test sentence."
    ]
  },
  "output": {
    "audios": [
      {
        "url": "https://content.doitong.com/dev-api/2026/10/20/req_8k2m4q7x1z9c3v5b6n0p2r4t/0-output.mp3",
        "content_type": "audio/mpeg",
        "file_name": "0-output.mp3",
        "file_size": 1843200
      }
    ],
    "durations": [
      5
    ],
    "sample_rate": "48 kHz",
    "total_generation_time": 5.7,
    "average_rtf": 0.15
  },
  "outputs": [
    {
      "type": "audio",
      "url": "https://content.doitong.com/dev-api/2026/10/20/req_8k2m4q7x1z9c3v5b6n0p2r4t/0-output.mp3",
      "content_type": "audio/mpeg",
      "file_size": 1843200,
      "duration": 12,
      "stored": true
    }
  ],
  "error": null,
  "metrics": {
    "inference_seconds": 6.8
  },
  "urls": {
    "self": "https://api.doitong.com/v1/requests/req_8k2m4q7x1z9c3v5b6n0p2r4t",
    "cancel": "https://api.doitong.com/v1/requests/req_8k2m4q7x1z9c3v5b6n0p2r4t/cancel"
  }
}
Eich ffeiliau, eich dewisMae pob outputs[].url yn gopi ar ein storio: wedi'i gadw am byth (telir fesul GB-mis) neu am 7 diwrnod am ddim, yn ôl gosodiad eich cyfrif neu ?storage=.
Yr un siâp ar bob modeltype, url, content_type, width, height a duration, ar gyfer delweddau, fideo a sain fel ei gilydd. Gwrthrych canlyniad y model ei hun yw output.
Meysydd yr allbwn
audios
array of object {url, content_type, file_name, file_size}Ffeiliau sain a gynhyrchir, wedi'u dychwelyd fel rhestr.
durations
array of numberHyd mewn eiliadau pob recordiad sain a gynhyrchir.
sample_rate
stringCyfradd samplu a rennir gan bob ffeil sain a gynhyrchir.
total_generation_time
numberCyfanswm yr amser cynhyrchu mewn eiliadau ar gyfer pob ffeil sain.
average_rtf
numberFfactor amser real cymedrig ar draws pob cynhyrchiad.

Mwy o fodelau: Testun i Leferydd

Ar gyfer asiantau AI: mae'r dudalen hon fel Markdown ar gael yn https://doitong.com/cy/developers/models/maya/batch.md. Pob model a chanllaw: https://doitong.com/developers/llms.txt