Leum chun t-susbaint

Flux Kontext Trainer

Amalaich

ID a’ mhodail flux-kontext-trainer
# Run the model; wait up to 20 s for the finished result in the same call
curl -X POST "https://vit.doitong.com/api/v1/run/flux-kontext-trainer?wait=20" \
  -H "Authorization: Bearer $DOITONG_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "image_data_url": "https://content.doitong.com/images/showcase/v3/gen_fox_cartoon.jpg"
  }'

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

Faidhlichean mar an eisimpleir: $2.50 2,500 creideasan API thèid na faidhlichean agad a thomhas ron ruith Ruith e air an duilleig seo

Faigh iuchair API
Black Forest Labs Trèanadh

Trèanadh LoRA Kontext [dev] bho zip de dh’ìomhaighean tòiseachaidh is deireannach co-phàirteach

Black Forest Labs · Faidhle

Thèid a’ chiad toradh agad an-seo

Tog iarrtas gu h-ìosal agus ruith e leis an iuchair API agad. Tha na h-às-churan air an lethbhreacadh dhan stòradh againn, air an cumail gu bràth no 7 latha an-asgaidh.

Tog iarrtas

Tha na smachdan air an cruthachadh bho sgeama a’ mhodail. Bidh an còd agus a’ phrìs ag ùrachadh fhad ’s a dh’atharraicheas tu iad.

•riatanach

URL tasglann ZIP in-chuir; feumaidh paidhrichean ìomhaighean a bhith san tasglann air an ainmeachadh ROOT_start.EXT agus ROOT_end.EXT, mar photo_start.jpg agus photo_end.jpg. Faodaidh faidhle ROOT.txt a bhith aig gach paidhir cuideachd, mar photo.txt, anns a bheil stiùiridhean deasachaidh. Mura h-eil am faidhle teacsa ann, bheir default_caption seachad na stiùiridhean; fàilligidh an trèanadh ma tha default_caption a dhìth cuideachd.

bun-roghainn 1000

Àireamh iomlan nan ceumannan trèanaidh.

Adhartach default_caption · learning_rate

Fo-thiotal a thèid a chleachdadh an àite fhaidhlichean fo-thiotal a tha a dhìth; le None bidh an dìth aca na mhearachd.

bun-roghainn 0.0001
POST /run/flux-kontext-trainer?wait=20 tuairmse → $2.50
# Run the model; wait up to 20 s for the finished result in the same call
curl -X POST "https://vit.doitong.com/api/v1/run/flux-kontext-trainer?wait=20" \
  -H "Authorization: Bearer $DOITONG_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "image_data_url": "https://content.doitong.com/images/showcase/v3/gen_fox_cartoon.jpg"
  }'

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

Ruith an t-iarrtas seo

Fuirichidh an iuchair agad sa bhrobhsair seo: thèid a cur chun Doitong API a-mhàin agus a sàbhaladh (localStorage) a-mhàin ma chuireas tu comharra ri Cuimhnich. Faigh iuchair API

Mu Flux Kontext Trainer

Gleusaidh e LoRA airson Kontext air eisimpleirean càraideach roimhe/seachad. Tha `image_data_url` a’ comharrachadh zip le faidhlichean air an ainmeachadh ROOT_start.EXT agus ROOT_end.EXT. Faodaidh tu `steps` a shuidheachadh bho 1 gu 10000 (bun-roghainn 1000), `learning_rate` agus `default_caption` airson càraidean gun fhaidhlichean caipsein. Tillidh e cuideaman LoRA agus faidhle rèiteachaidh.

Paramadairean

AinmSeòrsa Bun-roghainnCeadaichte Tuairisgeul
image_data_urlriatanach
Seòrsastring
URL tasglann ZIP in-chuir; feumaidh paidhrichean ìomhaighean a bhith san tasglann air an ainmeachadh ROOT_start.EXT agus ROOT_end.EXT, mar photo_start.jpg agus photo_end.jpg. Faodaidh faidhle ROOT.txt a bhith aig gach paidhir cuideachd, mar photo.txt, anns a bheil stiùiridhean deasachaidh. Mura h-eil am faidhle teacsa ann, bheir default_caption seachad na stiùiridhean; fàilligidh an trèanadh ma tha default_caption a dhìth cuideachd.
stepsroghainneil
Seòrsainteger
Bun-roghainn1000
1 – 10,000
Àireamh iomlan nan ceumannan trèanaidh.
learning_rateroghainneil
Seòrsanumber
Bun-roghainn0.0001
default_captionroghainneil
Seòrsastring | null
Fo-thiotal a thèid a chleachdadh an àite fhaidhlichean fo-thiotal a tha a dhìth; le None bidh an dìth aca na mhearachd.
riatanach

Toradh

GET /requests/req_8k2m4q7x1z9c3v5b6n0p2r4t
{
  "id": "req_8k2m4q7x1z9c3v5b6n0p2r4t",
  "object": "request",
  "model": "flux-kontext-trainer",
  "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": 2500,
    "usd": "2.50",
    "charged": 2500,
    "refunded": 0
  },
  "input": {
    "image_data_url": "https://content.doitong.com/images/showcase/v3/gen_fox_cartoon.jpg"
  },
  "output": {
    "diffusers_lora_file": {
      "url": "https://content.doitong.com/dev-api/2026/10/20/req_8k2m4q7x1z9c3v5b6n0p2r4t/0-output.jpeg",
      "content_type": "image/jpeg",
      "file_name": "0-output.jpeg",
      "file_size": 1843200
    },
    "config_file": {
      "url": "https://content.doitong.com/dev-api/2026/10/20/req_8k2m4q7x1z9c3v5b6n0p2r4t/0-output.jpeg",
      "content_type": "image/jpeg",
      "file_name": "0-output.jpeg",
      "file_size": 1843200
    }
  },
  "outputs": [
    {
      "type": "file",
      "url": "https://content.doitong.com/dev-api/2026/10/20/req_8k2m4q7x1z9c3v5b6n0p2r4t/0-output.jpeg",
      "content_type": "image/jpeg",
      "file_size": 1843200,
      "stored": true
    }
  ],
  "error": null,
  "metrics": {
    "inference_seconds": 6.8
  },
  "urls": {
    "self": "https://vit.doitong.com/api/v1/requests/req_8k2m4q7x1z9c3v5b6n0p2r4t",
    "cancel": "https://vit.doitong.com/api/v1/requests/req_8k2m4q7x1z9c3v5b6n0p2r4t/cancel"
  }
}
Na faidhlichean agad, do roghainnTha gach outputs[].url na lethbhreac air an stòradh againn: air a chumail gu bràth (air a phàigheadh gach GB-mìos) no 7 latha an-asgaidh, a rèir suidheachadh a’ chunntais agad no ?storage=.
An aon chruth air gach modailtype, url, content_type, width, height agus duration, airson dealbhan, bhidio agus fuaim le chèile. ’S e output nì toraidh a’ mhodail fhèin.
Raointean toraidh
diffusers_lora_file
object {url, content_type, file_name, file_size}URL a’ comharrachadh cuideaman LoRA trèanaichte ann an cruth diffusers.
config_file
object {url, content_type, file_name, file_size}URL a’ comharrachadh faidhle rèiteachaidh a’ mhodail thrèanaichte.

Do riochdairean AI: tha an duilleag seo mar Markdown aig https://doitong.com/gd/developers/models/flux-kontext-trainer.md. Na modailean agus na treòraichean uile: https://doitong.com/developers/llms.txt